Commit Graph

9623 Commits

Author SHA1 Message Date
Oleg Zhurakousky
f127dc2d34 INT-2683, INT-2684 JmsOutboundGateway improvements
Added support for caching reply consumers when reply queue is Temporary Queue
Added support for reuse of temporary Reply queues in the JmsOutboundGateway

Added check in ChannelPublishingJmsMessageListener to catch IllegalAccessExceptions
when Session is closed

INT-2683 first round of PR coomments

INT-2683 polish

INT-2683 polishing
code restructuring, other optimizations

INT-2683 modified 'messageCorrelationId' generation logic to be the object identity of the jmsReques as its 3-4 times fatster then String.valueOf(System.currentTimeMillis() +
-                String.valueOf(System.nanoTime())

INT-2683
polished JOG to ensure that it properly manages the correlation id when used in the pipeline
added various combinations of pipeline tests

INT-2683 added copyrights to tests

INT-2683 polishing

INT-2683 polishing

INT-2683 added more pipeline tests

INT-2683 added more tests

INT-2683 polishing test

INT-2683 Polishing

INT-2683 More Pipeline Tests

INT-2683 Don't Propagate CorrelationID

Message correlation is internal to the JOG. Cannot
propagate an existing correlation id because some
downstream JOG may end up correlating (selecting) on
the same key.

INT-2683 Polishing

Fix whitespace - replace spaces with tabs.

INT-2683 polishing
reverted 2.1 schema back to its master state, fixed the typo in the test
2012-08-17 17:09:21 -04:00
Oleg Zhurakousky
1f59577281 Merge pull request #589 from garyrussell/INT-2702
* INT-2702:
  INT-2702 Mail ThreadLocal Polishing
2012-08-16 08:18:08 -04:00
Gary Russell
0da9baf26d INT-2702 Mail ThreadLocal Polishing
Change set(null) to remove()

Eliminate folder close from destroy() method. It no longer makes
sense to do that there.
2012-08-16 08:17:02 -04:00
Gary Russell
1edac11fba Merge pull request #588 from olegz/INT-2713 2012-08-15 19:29:26 -04:00
Oleg Zhurakousky
6528574c7e INT-2713 AMQP Content-Type Mapping
Adjusted DefaultAmqpHeaderMapper to recognize and convert Content-Type
to String if the incoming Content-Type headers is of type
org.springframework.http.MediaType.

INT-2713 polishing
2012-08-15 18:51:31 -04:00
Gary Russell
de5506daf3 Merge pull request #577 from olegz/INT-2637c 2012-08-15 15:08:09 -04:00
Oleg Zhurakousky
e2039789c0 INT-2637 Add Redis Store Outbound Adapters
INT-2637 added initial support for Redis store outbound adapters

INT-2637 polishing, squashing and rebasing with master

INT-2637
Rename parsePayload to storePayloadAsSingleValue and modify its schema counterpart,
Address other PR comments

INT-2637
Modify the parse-payload attribute to extract-payload-elements with default value 'true', update schema and tests

INT-2637 polish

INT-2637 Polishing

Tidy up Javadocs, Schema.

Add map-key-expression for MAP and PROPERTIES CollectionType

INT-2637 Polishing
2012-08-15 14:48:13 -04:00
Gary Russell
a2b0c3b508 Merge pull request #586 from olegz/INT-2626b 2012-08-14 15:40:34 -04:00
Oleg Zhurakousky
246a202661 INT-2626 Fix RLR parser
Fix RecipientListRouterParser to extend
from AbstractRouterParser, thus eliminating
the problem described in INT-2626.

Previously, the router was a top level bean and, since
it is an @ManagedResource, the mbean exporter eagerly
instantiated it (and its Recipients) before the
ChannelInitializer ran.

Now, it is an anonymous inner bean inside a FB,
so the exporter no longer "finds" it,
thus deferring the Recipient instantiation
until the router itself is instantiated via its FB,
which will be after the C.I. runs.

This is all fine, with one caveat - previously the RLR
is made available as an MBean - now it is not,
unless you ALSO add the int-jmx:mbean-exporter.

However, the MBean is very basic, with no attributes and
a single operation 'setShouldTrack()', so the risk is
extremely low and the workaround is to add the
IntegrationMBeanExporter.

INT-2626 polished based on PR comments
2012-08-14 15:21:20 -04:00
Gary Russell
2a04ee0806 Merge pull request #587 from olegz/INT-2712 2012-08-14 15:03:13 -04:00
Oleg Zhurakousky
569f2f3d56 INT-2712 Fix HttpREMHandler ConversionService
Fix initialization of the ConversionService logic
in HttpRequestExecutingMessageHandler to NOT throw an exception if
ConversionService is not an instance of ConfigurableConversionService

Fix previous commit to be compatible with Spring 3.0,
by dependiing on ConverterRegistry instead of
ConfigurableConversionService, which was introduced in Spring 3.1
2012-08-14 14:55:09 -04:00
Oleg Zhurakousky
a544ef08b3 Merge pull request #585 from garyrussell/INT-2711
* INT-2711:
  INT-2711 syslog Transformer
2012-08-14 14:16:13 -04:00
Gary Russell
f8782f3dc9 INT-2711 syslog Transformer
Initial Implementation; UDP test.

syslog - Add TCP Test

Add single byte terminating deserializer and a
subclass that terminates on LF (syslog uses
LF terminator).

Move to Core

Allow for transport of undecoded packet over, say, AMQP.

INT-2711 Syslog Transformer

PR Comments; Polishing.

Remove List option; support to-map version only.
2012-08-14 14:15:21 -04:00
Gary Russell
ca7e78a2d2 Merge pull request #583 from olegz/INT-2712 2012-08-13 10:08:31 -04:00
Oleg Zhurakousky
ad3af54ed6 INT-2712 Fix ConversionService Initialization
Fix initialization of the ConversionService logic
in HttpRequestExecutingMessageHandler to NOT throw an exception if
ConversionService is not an instance of GenericConversionService.

Check for ConfigurableConversionService instead.

INT-2712 polishing

INT-2712 Polishing Tests
2012-08-13 09:35:11 -04:00
Oleg Zhurakousky
c2d6486f9b Merge pull request #573 from garyrussell/INT-2704
* INT-2704:
  INT-2704 Exception Processing in TCP Adapter
2012-08-12 11:23:40 -04:00
Gary Russell
89d2f3ad83 INT-2704 Exception Processing in TCP Adapter
When using an outbound adapter with a server connection factory
(an inbound adapter 'owns' the connections), the outbound adapter
simply logged exceptions.

There are use cases where flows need to know the exception occurs.

Change the adapter to throw a MessagingException.

Update the 2.1 to 2.2. Migration guide explaining that the
ExpressionEvaluatingRequestHandlerAdvice can be used to restore
2.1 behavior, and trap the exception.
2012-08-12 11:22:31 -04:00
Gary Russell
3feef9414a Merge pull request #570 from olegz/INT-2638 2012-08-10 16:41:58 -04:00
Oleg Zhurakousky
bfb5cbdb2a INT-2638 added support for Redis inbound channel adapters
Currenly there is support for:
- list-inbound-channel-adapter - http://redis.io/commands#list
- zset-inbound-channel-adapter - http://redis.io/commands#sorted_set

INT-2638 polishing

INT-2638 polished schema docs

INT-2638 polishing

INT-2638 polishing

INT-2638 refactored Redis collection inbound adapters to use RedisStore (view)

INT-2638 polishing, exposed redis-template via the namespace

INT-2638 polished based on PR comments

INT-2638 polishing

INT-2638 Polishing
2012-08-10 16:26:24 -04:00
Oleg Zhurakousky
25afb09f48 Merge pull request #580 from artembilan/INT-2706
* INT-2706:
  INT-2706: fix 'expected-response-type' primitives
2012-08-10 08:04:40 -04:00
Artem Bilan
16d5377e8b INT-2706: fix 'expected-response-type' primitives
* HttpRequestExecutingMessageHandler: change Class.forName() to ClassUtils.forName()
* HttpRequestExecutingMessageHandler: some polishing about DRY
* OutboundResponseTypeTests: tests about "byte[]" & "[B" values for 'expectedResponseTypeExpression'
* OutboundResponseTypeTests: polishing to make it more quickly
* OutboundResponseTypeTests contexts: versionless XSD

JIRA: https://jira.springsource.org/browse/INT-2706
2012-08-10 08:03:37 -04:00
Oleg Zhurakousky
1cf52b92a8 Merge pull request #578 from ghillert/INT-2292
* INT-2292:
  INT-2292 - Document usage of default namespaces for XPath Expressions For reference see: https://jira.springsource.org/browse/INT-2292
2012-08-10 07:53:00 -04:00
Gunnar Hillert
f37aa9db81 INT-2292 - Document usage of default namespaces for XPath Expressions
For reference see: https://jira.springsource.org/browse/INT-2292
2012-08-10 07:51:24 -04:00
Oleg Zhurakousky
b5350fdb3c Merge pull request #575 from ghillert/INT-2392
* INT-2392:
  INT-2392 - ChainElementsFailureTests reads wrong 'xmlheader' property For reference: https://jira.springsource.org/browse/INT-2392
2012-08-10 07:48:57 -04:00
Gunnar Hillert
ef1c0fc93d INT-2392 - ChainElementsFailureTests reads wrong 'xmlheader' property
For reference: https://jira.springsource.org/browse/INT-2392

Code Review - Refactored Test Case
2012-08-10 07:46:40 -04:00
Oleg Zhurakousky
9cc6890374 Merge pull request #572 from garyrussell/INT-2703
* INT-2703:
  INT-2703 SpEL-Based Retry State Generator
2012-08-09 17:31:43 -04:00
Gary Russell
1405e3bbf0 INT-2703 SpEL-Based Retry State Generator
Stateful retry requires some state to determine the
retry count for a resubmitted message.

State is provided by a retry state object generated by a
state generator. No standard state generators were
provided by Spring Integration.

Provide a SpEL-Based state generator to create a
RetryState object from a Message (for example, using
the jms message id header).

Add ErrorMessageSendingRecoverer - a RetryCallback
invoked when recovery attempts are exhausted.

Add string-based constructor to Spel Advice for
easier <bean/> configuration.
2012-08-09 17:30:15 -04:00
Gary Russell
39efd0bcd4 Merge pull request #582 from ghillert/INT-2708 2012-08-09 13:36:40 -04:00
Gunnar Hillert
43def795f9 INT-2708 - Fix Failing Tests in FileInboundTransactionTests
* Remove hard-coded XML Schema versions in *FileInboundTransactionTests-context.xml*
* Convert spaces-to-tabs in *FileInboundTransactionTests-context.xml*

For reference see: https://jira.springsource.org/browse/INT-2708
2012-08-09 13:00:57 -04:00
Gary Russell
0dabdbea6d Merge pull request #574 from ghillert/INT-2670 2012-08-09 12:24:10 -04:00
Gunnar Hillert
17dd49beb4 INT-2670 -JMS Samples Chapter uses old Repo URL 2012-08-09 12:24:00 -04:00
Oleg Zhurakousky
9423c21e7a Merge pull request #581 from garyrussell/INT-2707
* INT-2707:
  INT-2707 Fix pseudo-transactional Attribute Typo
2012-08-09 12:17:21 -04:00
Gary Russell
f294086684 INT-2707 Fix pseudo-transactional Attribute Typo
s/psuedo-/pseudo-/
2012-08-09 08:09:50 -04:00
Gary Russell
d4d009135f Merge pull request #546 from artembilan/INT-2649 2012-08-06 12:13:08 -04:00
Artem Bilan
d4e135b13d INT-2649: DelayHandler: tx & adviceChain support
* 'delayer-type' XSD: add `<transactional>` & `<advice-chain>`
* move `PollerParser#configureAdviceChain` into `IntegrationNamespaceUtils`
* DelayerParser: parsing `<transactional>` & `<advice-chain>` via `IntegrationNamespaceUtils#configureAdviceChain`
* DelayHandler: add `adviceChain` property
* DelayHandler: introduce `ReleaseMessageHandler` to apply `adviceChain` capabilities around `DelayHandler#doReleaseMessage`
* DelayerParserTests: tests for introduced sub-elements
* DelayerHandlerRescheduleIntegrationTests: test for transaction boundaries with intentional rollback in the message-flow after message release

JIRA: https://jira.springsource.org/browse/INT-2649

Resolve conflicts; polishing.
2012-08-06 12:09:30 -04:00
Oleg Zhurakousky
fc1417ed39 Merge pull request #562 from garyrussell/INT-2214,INT-343/INT-2250/INT-2656
* INT-2214b:
  INT-2214, INT-343, INT-2250 MessageHandler Advice
2012-08-06 09:17:36 -04:00
Gary Russell
08cbab08c2 INT-2214, INT-343, INT-2250 MessageHandler Advice
Add general capability to advise just the handleRequestMessage
part of an AbstractReplyProducingMessageHandler.

This is to advise just the immediate operation, and not the
entire downstream flow.

Uses include:

* outbound gateway post processing
* adding retry behavior using spring-retry
* adding circuit breaker functionality

Initial commit for review.

Also need to advise simple message handlers (such as file
etc) to allow them to post-process file operations
with payload.delete(), payload.renameTo(...) etc.

INT-2250 Add Circuit Breaker Advice

INT-343 Add Retry Advice

Stateless and Stateful retry using spring-retry. Stateless
means the RetryTemplate performs the retries internally.
Stateful means the exception is thrown (e.g. to JMS container)
and the retry state is maintained by spring-retry.

INT-2215, INT-343, INT-2250 Refactoring

Factor out common abstract Advice class.

INT-2214 Catch Evaluation Expression Exceptions

If an onSuccess expression evaluation fails, add an
option so the user can decide whether such an exception is
caught, or propagated to the caller.

INT-2214 etc PR Review Polishing

INT-2214 etc Namespace Core, File, FTP

Add <request-handler-advice-chain/> to outbound endpoints.

INT-2214 etc. More Namespace Support

amqp, event, gemfire, groovy, http, ip, jdbc, jms, jmx, jpa, mail, rmi, sftp, twitter, ws, xmpp

INT-2214 etc Polishing

PR Review

INT-2214 etc Polishing

Don't catch Throwable.

Move Advice classes to handler.advice package.
2012-08-06 09:15:58 -04:00
Oleg Zhurakousky
56e3c22970 Merge pull request #564 from garyrussell/INT-2685
* INT-2685:
  INT-2685 Transaction Synchronization
2012-08-03 14:05:11 -04:00
Gary Russell
4de02fa75e INT-2685 Transaction Synchronization
Remove M3 disposition-* attributes on File/(S)FTP inbound adapters.

Add <pseudo-transactional/> and <transaction-synchronization/> elements
to <poller/>.

These elements provide the following attributes:

* on-success-expression
* on-success-result-channel
* on-failure-expression
* on-failure-result-channel
* send-timeout

<transaction-synchronization/> synchronizes these expression evaluations
with the transaction, such that they are executed immediately after
the commit/rollback.

<psuedo-transactional/> is used for a non-transactional poller.

When an <advice-chain/> is provided to the poller, <psuedo-transactional/>
and <transaction-synchronization/> are synonyms; and the behavior is
dictated by whether or not the <advice-chain/> contains a transaction
advice. It is recommended that <pseudo-transactional/> is used when the
<advice-chain/> does not have a txAdvice, and <transaction-synchronization/>
when it does, but the framework does not enforce this.

The expressions have the original (polled) message as the #root variable.
In addition, a BeanResolver is provided, allowing expressions such as
'@someBean.handleSuccess(payload)'.

MessageSources may also implement PseudoTransactionalMessageSource. This
has a number of methods allowing more flexibility in transactional and
non-transactional environents. For example, for backwards compatibility.
the mail-inbound-channel-adapter deletes its polled message after the
receive() rather than after the polled message is sent (when running in
a non-transactional poller). However, when running in a transactional
poller, the delete is done after the transaction commits (but not when
it rolls back).

In addition, MessageSources that implement this interface can optionally
provide an arbitrary object to the success/failure expressions in a
variable named '#resource'.

INT-2685 Polishing

PR Review Comments

Add tests for non-tx PseudoTransactionalMessageSource
2012-08-03 14:04:22 -04:00
Oleg Zhurakousky
d6623bda82 Merge pull request #569 from ghillert/INT-2680
* INT-2680:
  INT-2680 - Duplicate Content-Type header For reference please see: https://jira.springsource.org/browse/INT-2680
2012-08-03 13:55:16 -04:00
Gunnar Hillert
78c85c2510 INT-2680 - Duplicate Content-Type header
For reference please see: https://jira.springsource.org/browse/INT-2680
2012-08-03 00:09:56 -04:00
Oleg Zhurakousky
0fc285db6e Merge pull request #559 from ghillert/INT-2668
* INT-2668:
  INT-2668 - Improve the File Overwrite Handling
2012-08-01 13:34:21 -04:00
Gunnar Hillert
6b4f67b153 INT-2668 - Improve the File Overwrite Handling
* Add *mode* attribute to XSD (supports APPEND, FAIL, IGNORE, REPLACE)
* Add test cases
* Add reference documentation

For reference: https://jira.springsource.org/browse/INT-2668

INT-2668 - Code Review Changes

INT-2688 fixed typo
2012-08-01 13:32:54 -04:00
Oleg Zhurakousky
b6a9c1aedc Merge pull request #566 from johndoe/INT-2689
* INT-2689:
  INT-2689 - SI builds without warnings (Except Spring Integration HTTP)
2012-08-01 13:10:37 -04:00
Gunnar Hillert
57bc67b8fb INT-2689 - SI builds without warnings (Except Spring Integration HTTP)
* Ensure that no deprecation warnings occur
* Spring Integration builds with all tests successfully for Spring 3.1.2.RELEASE and 3.0.7.RELEASE (Except Spring Integration HTTP)

For reference see: https://jira.springsource.org/browse/INT-2689

INT-2694 - Fix Http Test Failures with Spring 3.0

As part of INT-2689, fix Http Test Failures in the Spring Integration Http Module when using Spring 3.0.7.RELEASE
For reference see: https://jira.springsource.org/browse/INT-2694
2012-08-01 13:09:51 -04:00
Oleg Zhurakousky
19c53ed9e9 Merge pull request #561 from ghillert/INT02681
* INT-2681:
  INT-2681 - Upgrade to Gradle 1.0 GA For reference: https://jira.springsource.org/browse/INT-2681
2012-08-01 13:02:17 -04:00
Gunnar Hillert
cef6113854 INT-2681 - Upgrade to Gradle 1.0 GA
For reference: https://jira.springsource.org/browse/INT-2681
2012-07-25 15:49:07 -04:00
Oleg Zhurakousky
9be17fa4df Merge pull request #554 from garyrussell/INT-2665
* INT-2665:
  INT-2665 JMX Endpoints And Remote MBeanServer
2012-07-19 13:05:07 -04:00
Gary Russell
c63141f6e0 INT-2665 JMX Endpoints And Remote MBeanServer
JMX endpoints need a reference to an MBeanServer. The MBeanServer
is a sub-interface of MBeanServerConnection.

When connecting to a remote MBeanServer, the server is an
instanceof MBeanServerConnection, not MBeanServer.

Change the Endpoints to get a reference to an MBeanServerConnection.

Add IOException catch clauses where necessary.
2012-07-19 13:04:04 -04:00
Oleg Zhurakousky
b39b0c2681 Merge pull request #556 from artembilan/INT-2678
* INT-2678:
  INT-2678: fix a couple of typo
2012-07-19 12:58:54 -04:00