Commit Graph

38 Commits

Author SHA1 Message Date
Artem Bilan
f248394682 INT-3589: Upgrade Dependencies
JIRA: https://jira.spring.io/browse/INT-3589, https://jira.spring.io/browse/INT-3624

* SF - 4.2. Fix Breaking changes for the `ApplicationEventPublisher`
* AMQP 1.5. Without issues
* Reactor - 2.0. Fix for the new `Stream` foundation
* jsonPath - 1.2.0. Fix for new `Predicate` abstraction. Add 'fail-fast error' to the `IntegrationRegistrar`
* Sshd - 0.13.0. Fix for new `VirtualFileSystemFactory` usage
* Spring Data - Fowler
* And others without issues
* Get rid of `reactor.util.StringUtils` usage

INT-3589: Address PR comments

Polishing
2015-02-17 15:09:09 -05:00
Artem Bilan
cb50b1565c INT-3554: Add Expression Setters
JIRA: https://jira.spring.io/browse/INT-3554

**Cherry-pick to 4.0.x**

Polishing
2014-11-07 15:58:22 -05:00
Artem Bilan
acf2ad2229 INT-3246: MessageHandlingException Refactoring
JIRA: https://jira.springsource.org/browse/INT-3246

INT-3246: Add description to usage of MHException

Deprecate `MessageRejectedException` constructor

INT-3246: Remove `MessageHandlingException` class
2014-01-03 16:19:01 -05:00
Gary Russell
a24b9ffa22 Merge remote-tracking branch 'upstream/master' into 4.0.0-WIP
Conflicts:
	spring-integration-core/src/main/java/org/springframework/integration/gateway/MessagingGatewaySupport.java
	spring-integration-core/src/main/java/org/springframework/integration/support/channel/BeanFactoryChannelResolver.java
	spring-integration-core/src/main/java/org/springframework/integration/util/MessagingMethodInvokerHelper.java
	spring-integration-core/src/test/java/org/springframework/integration/config/AggregatorParserTests.java
	spring-integration-core/src/test/java/org/springframework/integration/config/annotation/AggregatorAnnotationTests.java
	spring-integration-core/src/test/java/org/springframework/integration/config/xml/ControlBusTests.java
	spring-integration-file/src/main/java/org/springframework/integration/file/DefaultFileNameGenerator.java
	spring-integration-file/src/main/java/org/springframework/integration/file/remote/handler/FileTransferringMessageHandler.java
	spring-integration-file/src/test/java/org/springframework/integration/file/remote/gateway/RemoteFileOutboundGatewayTests.java
	spring-integration-ftp/src/test/java/org/springframework/integration/ftp/config/FtpOutboundGatewayParserTests.java
	spring-integration-ftp/src/test/java/org/springframework/integration/ftp/inbound/FtpInboundRemoteFileSystemSynchronizerTests.java
	spring-integration-ftp/src/test/java/org/springframework/integration/ftp/outbound/FtpServerOutboundTests.java
	spring-integration-groovy/src/main/java/org/springframework/integration/groovy/GroovyScriptExecutingMessageProcessor.java
	spring-integration-http/src/test/java/org/springframework/integration/http/outbound/UriVariableExpressionTests.java
	spring-integration-ip/src/test/java/org/springframework/integration/ip/tcp/connection/HelloWorldInterceptor.java
	spring-integration-jpa/src/test/java/org/springframework/integration/jpa/outbound/JpaOutboundGatewayIntegrationTests.java
	spring-integration-mongodb/src/test/java/org/springframework/integration/mongodb/store/MongoDbMessageGroupStoreTests.java
	spring-integration-mongodb/src/test/java/org/springframework/integration/mongodb/store/MongoDbMessageStoreTests.java
	spring-integration-redis/src/test/java/org/springframework/integration/redis/config/RedisOutboundChannelAdapterParserTests.java
	spring-integration-sftp/src/test/java/org/springframework/integration/sftp/config/SftpOutboundGatewayParserTests.java
	spring-integration-sftp/src/test/java/org/springframework/integration/sftp/inbound/SftpInboundRemoteFileSystemSynchronizerTests.java
	spring-integration-sftp/src/test/java/org/springframework/integration/sftp/outbound/SftpServerOutboundTests.java

Resolved.
2013-11-25 17:59:51 -05:00
Gary Russell
c04cfc668a INT-3143 Doc Polishing
JIRA: JIRA: https://jira.springsource.org/browse/INT-3143

Also increase the timeout on an event test.
2013-11-20 17:47:35 -05:00
Gary Russell
7dcd2b5fe9 Remove SI GenericMessage
- Deprecate for now to ease XD migration.
2013-10-24 09:46:30 -04:00
Andy Wilkinson
28ab8394de Build on top of Spring 4's new messaging types
This commit updates Spring Integration to depend upon Spring 4, making
use of the message types that have moved from Spring Integration into
Spring's new spring-messaging module.

The default message converter no longer supports conversion of a
message that is null, throwing an IllegalArgumentException if an
attempt is made to convert null. Furthermore, GenericMessagingTemplate
does not support sending null, again throwing an
IllegalArgumentException. Previously, MessagingTemplate had no-oped an
attempt to send null.

ConcurrentAggregatorTests and AggregatorTests both had a single test
that was specifically testing the behaviour of an aggregator that
returns null for its message. These tests have been removed.

CorrelatingMessageHandlerTests have been updated to specify some
additional behaviour for its mocks so that null messages are not
returned.

These are the only functional changes that have been made. All other
changes are simply for moving to the repackaged and/or renamed types.

In the move to being part of core Spring, a number of constants and
header accessor methods have moved from MessageHeaders to
MessageHeaderAccessor. This commit continues this pattern for
the enterprise integration headers that are specific to Spring
Integration. A new class, EiMessageHeaderAccessor, has been created.
This class provides constants and methods for working with SI-specific
headers. The main code and tests have been updated to use this new
class.
2013-10-08 16:42:22 -04:00
Gary Russell
7f008b58c2 INT-1639 Externalize SpEL Evaluation Context
Allow modification of context property accessors and
functions.

Polishing

- Fix tests to ensure the EvaluationContextFactoryBean is
available when necessary.

Polishing - Use Utility for ALL EvaluationContexts

Add Test Showing Custom Function

See SpelTransformerIntegrationTests-context.xml

Polishing

Polishing -fix Remote Sync

Polishing - Emit WARN if No BeanFactory

Polishing - Do Not Override ConversionService

Kludge to Prevent Warning When No BeanFactory

Expressions for method invoking in the MessagingMethodInvokerHelper
don't need a BeanFactory - suppress the warning.

Polishing - PR Comments - Invert Boolean
2013-08-25 20:01:14 -04:00
Artem Bilan
116f4934c1 INT-2935: Improve Event Inbound Adapter
Previously, the `ApplicationEventListeningMessageProducer` accepted
all `ApplicationEvent`'s and than filtered them.
This caused some `ApplicationEventMulticaster.retrieverCache` overhead.

* Improve `ApplicationEventListeningMessageProducer` to `implements SmartApplicationListener`.

    This allows filtering earlier on first the appropriate `ApplicationEvent`
    using `ApplicationEventListeningMessageProducer#supportsEventType`
    and caching the `ApplicationListener` only for that `ApplicationEvent`.

* Re-register `ApplicationEventListeningMessageProducer` in the `ApplicationEventMulticaster`
    when  `ApplicationEventListeningMessageProducer#setEventTypes` is invoked
    to clear the `ApplicationEventMulticaster.retrieverCache`.

* Move `org.springframework.integration.gemfire.inbound.SpelMessageProducerSupport` to core `ExpressionMessageProducerSupport`.

* Add test for the new logic int `ApplicationEventListeningMessageProducer` and its behavior with respect to the `ApplicationEventMulticaster.retrieverCache`.

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

INT-2935: EMPS JavaDoc & AELMP ReadWriteLock

INT-2935: AELMP#eventTypes changing 'barrier'

INT-2935: avoid 'eventTypes' mutation afterwards

INT-2935: Polishing according PR comments

INT-2935: Fix NPE in the `setEventTypes`

Minor Polishing

   Polish java docs/comments
   Remove compiler warnings
2013-05-08 12:25:04 -04:00
Gunnar Hillert
0271acaf4c INT-2916 - Upgrade to JUnit 4.11 in support of JDK7
For reference see: https://jira.springsource.org/browse/INT-2916

Changes:

* INT-2919 - Upgrade Spring Data Gemfire to 1.2.2.RELEASE
* Exclude Hamcrest transitive dependency from JUnit (as already explicitly declared)
* Set sourceCompatibility in build.gradle to 1.6
* Set targetCompatibility in build.gradle to 1.6
* Upgrade Hamcrest to 1.3 and fix deprications
  - Corematcher is(*class) change to is(instanceOf(*class))
  - Change org.junit.internal.matchers.TypeSafeMatcher to org.hamcrest.TypeSafeMatcher
  - Change import org.junit.matchers.JUnitMatchers.containsString to org.hamcrest.CoreMatchers.containsString
  - Change import org.junit.matchers.JUnitMatchers.both to org.hamcrest.CoreMatchers.both
  - Change import org.junit.matchers.JUnitMatchers.containsString to org.hamcrest.CoreMatchers.containsString
* Fix JUnit deprecations
  - changed junit.framework.Assert to org.junit.Assert
* Add few missing licenses headers to tests
* Marked several test classes with: @DirtiesContext(classMode=ClassMode.AFTER_EACH_TEST_METHOD)
  - SplitterIntegrationTests
  - GatewayInvokingMessageHandlerTests
  - FileToChannelIntegrationTests
  - FileInboundChannelAdapterWithRecursiveDirectoryTests
  - JdbcMessageStoreChannelTests
  - ChatMessageInboundChannelAdapterParserTests
* 3 Tests ignored (Still needs to be addressed):
  - testOperationOnPrototypeBean
  - testFailOperationWithCustomScope
  - testOperationOfControlBus
* Update SQL script (test-failure):
  - spring-integration-jdbc/src/test/java/org/springframework/integration/jdbc/config/outboundSchema.sql
  - add drop table statements
  - add ignore-failures="DROPS" to "jdbcOutboundChannelAdapterCommonConfig.xml"

INT-2916 - Code Review Changes

INT-2916 - Fix ignored Tests

Fix 3 previously ignored tests in *GroovyControlBusTests*:

* testOperationOnPrototypeBean
* testFailOperationWithCustomScope
* testOperationOfControlBus

INT-2916 - CI Build Testing

INT-2963 - Remove JDK7 Compilation Warnings

* Upgrade Mockito to 1.9.5
* Fix failing SubscribableJmsChannelTests

INT-2916 - Standardize Hamcrest assertions
Ensure Hamcrest assertions are standardized to: is(instanceOf(...))
2013-04-04 13:40:46 -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
Gary Russell
fcd3771c17 INT-2588 Remove Deprecation
@ExpectedException is deprecated.

Also fixes a sporadic timing issue in the client mode test;
the default retry interval is 60 seconds and we only wait
10 seconds for the connection. If the initial connection
fails, we don't retry before the timeout.

INT-2527 Remove Event Deprecation

@Test @ExpectedException... -> @Test(expected...
2012-05-25 15:30:24 -04:00
Artem Bilan
45c429ee2b INT-2275: any outbound-channel-adapter in <chain>
Add re-init logic for nested chains
Add logic about nested element for AbstractChannelAdapterParser
Refactor of DefaultOutboundChannelAdapterParser
Test for non-last nested chain with some outbound-channel-adapter
Improve XSD for chain-type
Manual outbound-channel-adapter ability for chain
Integration tests for all outbound-channel-adapter within <chain>
Remove redundant 'return-value-required' attribute from <stored-proc-outbound-channel-adapter>
Add support 'expectReply' for FileWritingMessageHandler

INT-2275 polishing & refactor FileOutbound*Parser

HttpRequestExecutingMessageHandlerTests polishing

INT-2275: polishing JavaDoc
2012-05-14 12:41:39 -04:00
Gary Russell
292aa90599 INT-2404 Fix Auto-Created Channel; Event, TCP, UDP
The AbstractChannelAdapterParser creates an implicit DirectChannel
if the adapter has no 'channel' attribute.

The Event, TCP, and UDP channel adapter parsers did not bind
this channel to the adapter and AC initialization failed with
'outputChannel is required'.

Further, the event schema marked the channel as being 'required',
precluding this feature.

INT-2407 Remove Channel use="required"

Parsers automatically generate the channel when none is provided.

- JMX
- JDBC
- SFTP
- Redis
- Feed
- XMPP
- Mail
- FTP
- HTTP
2012-01-23 10:12:34 -05:00
Mark Fisher
6ba83c0f8f removed xsd versions in event module 2011-10-10 10:56:40 -04:00
Gary Russell
3af7a939db INT-1624 @author tags 2010-11-17 16:13:02 -05:00
Gary Russell
984ce33106 INT-1624 Add error-channel to event inbound channel adapter XSD, Parser, Test 2010-11-17 15:52:49 -05:00
Gary Russell
5c1652777e INT-1624 Add error-channel to event inbound channel adapter XSD, Parser, Test 2010-11-17 12:02:55 -05:00
Mark Fisher
d8ca51abc2 INT-1583 if received event has a Message as its source, it will be passed as-is 2010-11-03 12:56:17 -04:00
Mark Fisher
6cc758eefc INT-1582 if the payload is an ApplicationEvent it is passed as-is (no wrapping in MessagingException). Also, general polishing 2010-11-03 12:39:11 -04:00
Mark Fisher
b3c79358e1 INT-1505 added support for a 'payload-expression' attribute on the inbound ApplicationEvent Channel Adapter 2010-10-08 14:43:15 -04:00
Oleg Zhurakousky
32efbae90d INT-1263, more MessageHistory changes FTP, SFTP etc. 2010-09-23 09:45:01 -04:00
Oleg Zhurakousky
b6e058c59b INT-1263, added more changes and tests related valdating MessageHistory in every module 2010-09-22 18:44:51 -04:00
Mark Fisher
3b15a0dd38 INT-1390 moved MessageBuilder into the 'support' package, moved GenericMessage and ErrorMessage into the 'message' package 2010-08-31 02:51:27 +00:00
Mark Fisher
8314eeebf8 INT-1389 removed all dependencies on StringMessage from unit tests in spring-integration-event 2010-08-30 18:37:07 +00:00
Oleg Zhurakousky
2c7b57448b INT-1338, Added support for property placeholder 2010-08-23 18:10:58 +00:00
Oleg Zhurakousky
78dbf2bef5 INT-1338, Added namespace support for 'event-types' attribute 2010-08-23 17:09:32 +00:00
Mark Fisher
b879004b72 fixed event delivery to channel with no subscribers 2010-07-29 21:56:34 +00:00
Mark Fisher
3f00c75740 INT-1129 moved StringMessage from 'message' to 'core' (we might remove it before 2.0...) 2010-07-28 15:22:33 +00:00
Mark Fisher
4de9a23357 INT-1129 moved Message and MessageHeaders from 'core' to the root (org.springframework.integration) 2010-07-28 15:05:50 +00:00
Mark Fisher
94938a2746 INT-1129 moved MessageHandler from 'message' to 'core' 2010-07-28 14:54:09 +00:00
Mark Fisher
0b751cc18a INT-1129 moved SubscribableChannel from 'channel' to 'core' 2010-07-28 14:51:18 +00:00
Mark Fisher
4283315c08 INT-1129 moved PollableChannel from 'channel' to 'core' 2010-07-28 14:47:55 +00:00
David Syer
829d6efc08 Fix compiler warnings and move docbook build to a profile 2010-07-27 12:54:18 +00:00
Oleg Zhurakousky
0000aa2cfe INT-1221, Added test for pollable channel with executor 2010-06-28 18:37:16 +00:00
Oleg Zhurakousky
599bff36cb INT-1221, added namespace support for outbound-channel-adapter 2010-06-28 18:20:03 +00:00
Oleg Zhurakousky
6c402903e6 INT-1221, Added namespace support for ApplicationContextEvent Adapters 2010-06-28 16:18:21 +00:00
Chris Beams
c08a7a657e renamed modules org.springframework.integration.* -> spring-integration-*
@Ignore'd SimpleTcpNetOutboundGatewayTests#testOutboundClose() to avoid failure; this failure is correlated to the module name change, but hard to understand how it would be caused by it
2010-05-25 13:21:25 +00:00