Commit Graph

2293 Commits

Author SHA1 Message Date
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
Gary Russell
e73a5dc69f INT-3112 Fix OOM in SimplePool
The SimplePool maintains an 'allocated' set, for the sole reason
of preventing a "foreign" (non-managed) object being returned.

When a pool item is detected as stale, it is removed from the pool
but remains in the 'allocated' set.

Add a test to verify the allocated size is reduced when a stale
item is popped from the pool.

Add a FileTransferringMessageHandler test (where the problem was
discovered).

Fix a test in TCP to expect a close().

Polishing

Do not allow returning null items to just release a permit - it
cannot remove the item from allocated. Clients must return the
stale item to the pool so it can be refreshed on the next get.

Only used by the TCP caching CF when returning a connection when
the factory is not running; but should not be allowed.

Also, protect against double release - not currently an issue with
existing users of SimplePool, but should be protected against. Could
cause the permit count to exceed the pool size.

Add inUse Set to the pool so we can detect attempts to release an
item that has already been released.
2013-08-22 10:53:36 -04:00
Artem Bilan
afe56ca6d5 INT-2243: Delayer: Add 'expression' Support
Previously, the `<delayer>` provided a `delay-header-name` attribute.
In complex cases there was need to precede it with `<header-enricher>`.

* Add support for an 'expression' attribute and sub-element
* Deprecate `delay-header-name`
* Make `DelayHandler.DelayedMessageWrapper` *public* to allow access for Messages in the Store
* Add tests
* Add 'What's new' section
* Polishing Delayer's doc regarding new abilities

JIRA: https://jira.springsource.org/browse/INT-2243, https://jira.springsource.org/browse/INT-3049

INT-2243: ban delay-header-name with expression

INT-2243 Polishing

INT-2243: fall-back to default on Eval Exception

INT-2243: DelayedMessageWrapper refactoring

* Make `DelayedMessageWrapper` Spring Data Mongo mapping compatible.
In terms of Spring Data - add Persistence Constructor

INT-2243 add 'ignore-expression-failures' support

* Add `ignore-expression-failures` to the `<delayer>`
* Add tests for `ignore-expression-failures`
* Add a note to the RM
* Describe SpEL side-effects for `DelayHandler`

Doc Polishing
2013-08-20 16:54:42 -04:00
Gary Russell
573c692957 INT-2994 Advice Chain Config via Annotations
Allow configuration of request handler advice chain using

- ServiceActivator
- Filter
- Splitter
- Transformer

annotations.

Also, with splitter, allow setting discardWithinAdvice (See
INT-2938).

INT-2994 Polishing: PR Comments

- Change adviceChain attribute to an array
- Use a boolean for the discardWithinAdvice attribute

INT-2994 Handler Advice Doc Polishing

Add a paragraph about Advice Order.
2013-08-20 12:10:25 -04:00
Gary Russell
7ea5998016 Fix while Block Formatting in SimplePool 2013-08-20 11:27:10 -04:00
Artem Bilan
70886b2543 INT-2822: 'requires-reply' for Outbound Gateways
* Add `requires-reply` attribute for all adapters outbound gateways as `true` by default
* WS-outbound-gateway is still without it, because it has its own specific attribute `ignore-empty-responses`
* Make `requires-reply` as `false` by default for `jdbc:stored-proc-outbound-gateway` inasmuch as `jdbc:stored-proc-outbound-adapter`
doesn't have ability to configure `returning-resultset`
* add parser tests for `requires-reply`

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

INT-2822 'requires-reply' for ws:outbound-gateway

Default false.

INT-2822: Polishing after rebase

INT-2822: deprecate 'ignore-empty-responses'

* Add 'requires-reply' section into What's New

INT-2822: remove 'ignore-empty-responses' from RM

INT-2822: Polishing after rebase

INT-2822: Rebased and polished

INT-2822: Rebased and polished

Add WARN within deprecated `AbstractWebServiceOutboundGateway#setIgnoreEmptyResponses`

Revert 'ignore-empty-responses'; Doc Polishing
2013-08-19 13:48:31 -04:00
Gary Russell
0699fdc6cf INT-1807 Add Mechanism For Headers with TCP
TCP streams have no standard message structure. Therefore, the
TCP implementation previously only transferred the message
payload.

If someone wanted to convey header information, they would have
to write their own wrapper and/or use Java serialization for
the entire message.

This change provides a strategy to allow users to determine
which headers are transferred, and how.

A MessageConvertingMessageMapper is now provided that invokes
any MessageConverter. A MapMessageConverter is provided that
converts the payload, and selected heades to a Map with two
entries ("payload") and ("headers").

A MapJsonSerializer is provided that converts a Map to/from
JSON. Jackson can't delimit multiple objects in a stream
so another serializer is required to encode/decode structure.
A ByteArrayLfSerializer is used by default, inserting a
linefeed between JSON objects.

The combination of these elements now allows header
information to be transferred over TCP. Of course, users
can implment their own (de)serializer to format the
bits on the wire exactly as needed by their application.

INT-1807 Polishing

Add a test that uses a Map MessageConverter with a
Java (de)serializer.

INT-1807: Polishing

INT-1807: Rebased and polished

Change `MapJsonSerializer` to use `JsonObjectMapper` abstraction

Doc Polishing
2013-08-16 16:54:00 -04:00
Mark Fisher
4018c30f7d INT-3064 removed 2 obsolete tests 2013-08-15 16:58:23 -04:00
Gary Russell
77bdbed9a7 INT-3064 Change MessageHeaders.Id Strategy
Use `com.eaio.uuid` by default and document how to replace
the default strategy.

Provide JDK and a simple incrementing incrementing implementation.

Add code to detect multiple contexts in the same classloaded using
the same strategy.

Add code to detect multiple IdGenerator beans and emit a WARN
instead of DEBUG, which is the case for no beans.
2013-08-15 16:11:18 -04:00
Gary Russell
f53942ef4c INT-3106 Fix Bogus Warning Logs
INT-3007 introduced a warning log when advising a non-message handler
class. However, the log was also emitted when other methods on a
real MessageHandler were invoked.

Suppress the message in these cases and improve the log by
including the concrete class for the method rather than the
interface on which the method is declared.
2013-08-14 18:55:12 -04:00
Gary Russell
5cbdfe9e43 INT-3099 Add IMAP Idle Application Events
Allow an application to be informed of problems on the IMAP idle
thread by emitting an event containing the exception.

Introduce IntegrationApplicationEvent hierarchy for all
events emitted by SI components.

INT-3099 Polishing (PR Comments)

Separate TCP events into discrete subclasses.
2013-08-14 17:42:57 -04:00
Gary Russell
54e24ce97d INT-3030 Add Error Channel to RMI Inbound Gateway
INT-3030 Polishing; Docs, Tests

Add test cases for error channel support.

Dynamically discover available RMI port.

Add What's New and `<important/>` to reference.
2013-08-13 17:56:57 -04:00
Gary Russell
e8ef5ab878 INT-3095 Remove DOS Newlines 2013-08-11 17:44:24 -04:00
Gary Russell
d0e17b3995 INT-3094 Fix JSON and Core Package Tangles
INT-3094 Fix JSON Package Tangle

Move JSON 'discovery' classes to .support.json (used by
.json and .transformer - ObjectToMapTransformer)

INT-3094 Fix JSON Class Tangle

Separate factory methods to avoid class tangle.

Remove tight tangle between parser and mapper.

INT-3094 Fix Core Package Tangle

Move NamedComponent from .context to .support.context

(Used by .history, and .context references .store which references
.history through .util.)

INT-3094: fix 'support.json' package class-cycle

INT-3094 Polishing - PR Comments

Remove parser provider and make parsers public.
2013-08-11 15:02:26 -04:00
Artem Bilan
ff56a31cd3 INT-3108: add requires-reply for s-a within chain
`<service-activator>` has had an attribute `requires-reply`,
but it wasn't available within `chain`.
Introduce new XSD type `serviceActivatorType`
and use it for root `<service-activator>` element and within `<chain>` as well.

JIRA: https://jira.springsource.org/browse/INT-3108
2013-08-08 12:15:44 +03:00
Gary Russell
d1d367a97f INT-2938 Filter - Provide Option for Discard
Provide an option to determine whether or not the discard
(and exception throwing if configured) occurs within the
advice chain (default), or after it completes.

INT-2938 Filter Discard Advice Option - Schema

Schema, parser, tests for option on filter element.

INT-2938 Polishing - PR Comments + Doc

INT-2938 Add to "What's New"

INT-2938 Polishing - Javadoc Typo

while merging: simplified to use boolean var only
2013-05-23 12:07:26 -04:00
Gary Russell
b904fde5c0 INT-2951 Add Context Id to Dispatcher has no Subs.
https://jira.springsource.org/browse/INT-2951

Provide the context id in the 'Dispatcher has no Subscribers'
message.

Ease debugging when more than one context in an application.

INT-2951 Polishing

PR Comments - add quotes to context Id in log message.

Polishing

INT-2951 Polishing

Change IOS to have a simple getApplicationContextId() and
add a method getFullChannelName() to AbstractMessageChannel.
2013-05-22 12:57:20 -04:00
Artem Bilan
ecf15a9834 INT-2755: Support 'id' For <chain> Child Elements
* Introduce XSD 'id' attribute for all `<chain>` sub-components
* Register `<chain>` sub-components as Beans with names based on `<chain>` 'id'
* Generate aliases for sub-components based on element 'id'
* Add `<chain>` parser test to check sub-components as Beans within `BeanFactory`
* Ignore `NestedChainParserTests` as abnormal and confused for SI-configs
* Now `<chain>` sub-components are trackable by `MessageHistory`
* Now `<chain>` sub-components are eligible for JMX export
* Polishing some failed tests

https://jira.springsource.org/browse/INT-2755
https://jira.springsource.org/browse/INT-2321

INT-2755: Register as Beans only if 'id' provided

INT-2755: Set 'componentName' for handlers with 'id'

When components within `<chain>` are configured with an 'id' attribute
the 'componentName' of the handler is  constructed as:
chainHandler.componentName + '.' + handler.componentName.
Otherwise it is as was before.

INT-2755: Polishing

INT-2755: changes according PR's comments

* Add INFO about preference of `id` attribute for `<chain>` in the `ChainParser`
* Change `<chain>`'s sub-components `id` generation algorithm
* Configure `<chain>`'s sub-component `componentName` in the `ChainParser` instead of in the `MessageHandlerChain`
* Add `componentName` property to the `JpaOutboundGatewayFactoryBean`
* Add a note to the Reference Manual

INT-2755: Localize duplicate 'id' within chain

INT-2755: remove child beans aliasing

* Polishing tests
* Polishing docs

INT-2755 Polishing: Handle Nested Chain Bean Names

Previously named beans within a nested chain did not get unique
bean names.

INT-2755: Polishing nested chains

Doc Polishing
2013-05-21 12:26:27 -04:00
Gary Russell
ccf7492097 INT-2855 Fix Tail Test on Build Server
- Fix tail test
 - Fix 2 javadoc issues
2013-05-20 21:58:57 -04:00
David Turanski
9721eac28b INT-2984 changed some LocalChannelRegistry methods to protected 2013-05-19 10:19:36 -04:00
Gary Russell
91f040f1c7 INT-3004 Detect Timeout in MessagingTemplate
https://jira.springsource.org/browse/INT-3004

Previously, reply messages were silently ignored if the request thread
times out or caught an exception, or had already handled a reply.

Add a WARN log if the client times out or catches an exception,
or has already received a reply.

Optionally make these fatal; at this time, we are not exposing
this boolean on the namespaces see INT-3005.

Polishing - PR Comments

INT-3004 Polishing

Change MessagingTemplate property to throwExceptionOnLateReply.
2013-05-09 10:54:26 -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
Gary Russell
18e9754a66 INT-3007 Add WARN Log When Advice Skipped
Previously, when a MessageHandlerAdvice is applied to something
other than a MessageHandler, the advice was silently skipped.

Add a WARN log message that warns that the advice is not applied.

Add a test case that ensure the log is emitted when the
advice is applied to a Poller.
2013-05-07 14:20:37 -04:00
Gary Russell
3c31c38053 INT-2972 FixedMethodFilter - Return Mutable List
Compatibility with SF 3.2.2

Previously the filter returned a Collections.singletonList() when
a match is found.

Spring 3.2.2 attempts to sort the results of MethodFilter.filter()
which fails because the list is immutable.

Continue to return Collections.emptyList() with no match; this
does not cause the sort to fail.

Several tests in MethodInvokingMessageProcessorTests reproduce this
problem with Spring 3.2.2.

Add a test to confirm the Collections.emptyList() does not cause
any problems.
2013-05-07 10:35:48 -04:00
David Turanski
e5919799ce XD-33 - Implemented Local Channel Registry
modified per Artem's comments and added pub-sub to support inbound taps

Modified tap to use provided wiretap on inbound channels. Tap on outbound not supported

Changes to support conditional shared channel creation and the ability to share a registered channel for inbound() and outbound()
2013-05-01 17:29:10 -04:00
Kris De Volder
bcb626f0ed Fix compile error in STS/Eclipse.
TestUtils exists in both s-i-test and in src/test... in
s-i-core.

Gradle import caused the file module to use the one in
core that was missing a method.

We should look at a better solution but for now, this
commit syncs the two versions.

Also polished to fix white space violations.
2013-05-01 17:16:01 -04:00
Gary Russell
e27cd56451 INT-3001 Field Order in SyslogToMapTransformer
Use a LinkedHashMap instead of HashMap so iterators
retain the original field order.
2013-05-01 16:05:01 -04:00
Artem Bilan
a103e43c6a INT-2831: Add Jackson 2 support
Add Jackson 2 support while retaining backward compatibility as much as possible.

Introduce a new abstraction for JSON conversion.

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

INT-2831: Polishing

* remove `JsonObjectMapperFactoryBean`
* add @Deprecated constructors to `ObjectToJsonTransformer` and `JsonToObjectTransformer`

Polishing

Docs, compiler warnings.
2013-04-30 09:33:19 -04:00
Gary Russell
7908655883 INT-2982 Add Syslog Inbound Channel Adapter
* Supports UDP/TCP syslog messages.
* See docbook patch for more information.

For reference see: https://jira.springsource.org/browse/INT-2982
2013-04-23 23:36:36 -04:00
Gary Russell
00cb16ec21 INT-2996 Fix Class and Package Cycles
INT-2996 Fix Package Cycle

Move interface ...store.MetadataStore to ...store.metadata.

INT-2996 Fix Class Tangle

TcpConnectionEvent incorrectly referenced the
concrete TcpConnectionSupport instead of TcpConnection.
2013-04-16 19:10:48 -04:00
Gunnar Hillert
05062aa0b2 INT-2964 Various JavaDoc Fixes
INT-2964 - JavaDoc: <emphasis> should be <em>

INT-2964 - JavaDoc: <p/> should be <p>

INT-2964 - JavaDoc polishing

* <li></li> should be wrapped in <ul></ul>
* wrap code snippets in {@code myCode()}
* change <code>false</false> to <code>false</code>

INT-2964 - Polish - Fix more JavaDoc errors

* Mockito-all dependency causes JavaDoc error. Change dependency to Mockito-Core.
2013-04-15 17:11:38 -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
4818d9a722 INT-2939 Polishing
Add assert for non-null Level.
2013-04-03 00:11:17 -04:00
Gary Russell
d54a88f528 INT-2939 LoggingHandler Improvements
- Don't evaluate expression if the log level is not enabled
- Add mutually exclusive assertions (already protected by the parser
  but not for programmatic configuration).

INT-2944 Document <logging-channel-adapter/>

Add reference sub-chapter.

INT-2939 Polishing - PR Comments

- remove unnecessary cast.
- add setter for level changes.

Polishing

* Change setter to use enum.
* Add getter for current level.
* Rename method to 'createLogMessage'.
2013-04-03 00:11:17 -04:00
Gary Russell
7ab1361231 INT-2955 Fix Collection/Map Conversion
The fix for INT-2650 (to avoid unnecessary array copying) was
too general in that it also prevented types in collections and
maps from being converted.

Add tests to illustrate that such payloads are not converted.

Change code to only short circuit the conversion process if
the payload is a primitive array.

An existing test ensures that arrays are not copied.

Add more tests to complete coverage - discovered another
bug - the early exit after using a property editor to convert
to a String was never taken - it was testing against the
Class of the TypeConverter instead of the Type. If the
target type is a String, we don't need to perform
conversion after the property editor has done its
conversion.

Fix MessageHistory test (was testing MessageHeaders).
2013-03-27 17:03:33 -04:00
Gary Russell
b500ef397b INT-2959 Correct Schema GW reply-timeout Doc.
Incorrectly indicated that an exception is thrown when
the gateway times out.
2013-03-26 23:47:52 -04:00
Artem Bilan
6ae61a3345 INT-2958: XSD: move 'charset' from common attrs
`charset` for `<object-to-string-transformer>` was placed in the common `inputOutputChannelGroup` attributeGroup.
`charset` wasn't available  within `<chain>`.

* Move 'charset' from `inputOutputChannelGroup` to the new `specialized-transformer-charset-aware-type` complexType
* Add test for 'charset' within `<chain>`

JIRA: https://jira.springsource.org/browse/INT-2958
2013-03-13 12:02:09 -04:00
Gary Russell
eb07178381 INT-2937 Fix Race Condition in MGS Reaper
Groups changed within the same millisecond that they
were selected for reaping can cause aggregators to
emit duplicate messages.

Use the re-fetched group (used to see if the timetamp
changed) instead of the group passed in to forceClose
(the group might have changed since it was selected as
eligible for reaping).

We still retain the last modified check because it
might have been expired using timeoutOnIdle.
2013-02-25 14:36:47 -05:00
Stefan Ferstl
4585699e62 INT-2931 Fix Router Race Condition
AbstractMessageRouter.getRequiredConversionService() and
IntegrationObjectSupport.getConversionService() try to initialize the
conversion service and may be called from multiple threads. There is
a race condition where this could end up in an uninitialized conversion service
causing NPEs in subsequent method calls.

To solve this issue, the conversion service is initialized with
double-checked locking.

For further details see https://jira.springsource.org/browse/INT-2931

INT-2931 Polishing - Add Test Case

Add a test case that reliably reproduces the issue and verifies
the fix.
2013-02-14 14:32:04 -05:00
Gary Russell
83fc5e449a INT-2853 ObjectToStringTransformer Improvements
* Convert byte[] and char[] to String rather than simply using toString().
* Allow the charset to be configured for byte[] payloads.
* Add tests.
* Add reference documentation updates.
2013-02-14 11:02:48 -05:00
Gary Russell
5edebb303e INT-2900 Remove Extraneous Debug Log
When referencing a <gateway/> from a <service-activator/>, a debug
log is written with a full stack trace.

This is because all methods on the proxy are considered candidates,
but one method (addAdvice) has multiple parameters and can't be
used to process a message.

Add code to detect a proxy that has no target object; if the Proxy
only has one interface, then use that as the targetClass.
2013-02-13 14:23:20 -05:00
Gary Russell
fc8985aee7 INT-2922 Fix TypeConverter Concurrency Issue
During initialization, it is possible for type conversion to fail because a second thread accesses a partially built list of PropertyEditors. This is because getDefaultEditor(Class) is not thread-safe.

* Add a test with mocks and spies to verify concurrent access to the method occurs before the fix, and not after the fix.
* Synchronize the call to getDefaultEditor(), when called from canConvert() and convertValue().
* Only synchronize the call until we have invoked the method at least once.
2013-02-12 16:53:16 -05:00
Gary Russell
e822bfd908 INT-2823 Add QueueChannelOperations
Operations on QueueChannel (clear, getQueueSize etc) are not available
when the IntegrationMBeanExporter is configured because they
are not declared on the PollableChannel interface.

Add an additional interface QueueChannelOperations.

The proxy proxies all interfaces so users can cast the
proxy to QueueChannelOperations to use its methods.
2013-02-12 15:05:01 -05:00
Artem Bilan
8c07856fa1 INT-2899: Remove Redundant Logic from Aggregator
Previously, `AggregatingMessageHandler#setExpireGroupsUponCompletion` had additional logic
for removing complete MessageGroups. It could produce some overhead on application start-up with big persistent `MessageStore`.
This logic played a role to remove empty groups from a `MessageStore`.
Since `AbstractCorrelatingMessageHandler#forceComplete` has an ability to to remove empty groups too,
this logic became redundant.
So, to clean `MessageStore` from empty complete groups, it's sufficient to use a `MessageGroupStoreReaper`.

* Remove logic iterating over the `MessageStore` from `AggregatingMessageHandler#setExpireGroupsUponCompletion`
* Polishing `AggregatorSupportedUseCasesTests.java` to use `store.expireMessageGroups(0)`
* Introduce `empty-group-min-timeout` xml-attribute, populating `AbstractCorrelatingMessageHandler#minimumTimeoutForEmptyGroups`
* Add parser tests for `empty-group-min-timeout` attribute

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

INT-2899: Documentation about changes of ACMH

* rename new XSD-attribute to `empty-group-min-timeout`
* add to Reference Manual description about `empty-group-min-timeout`
* add 'What's new' for `empty-group-min-timeout`
* add 2.2-3.0 Migration Guide note

INT-2899 Doc Polishing
2013-02-12 14:27:31 -05:00
Artem Bilan
77fae8844a INT-2888 Fix MapToObjectTransformerParser CL Issue
In the parent-child environment configuration that relies on class names may produce
a `ClassNotFoundException`.

* remove usage of `ClassLoader` in the `MapToObjectTransformerParser` and allow to use the `ConversionService` from application context
* remove deprecation from `MapToObjectTransformer`
* refactor `MapToObjectTransformer` to use `IntegrationObjectSupport#getConversionService()`
* remove fallback to the `beanFactory#getConversionService()` in the `ExpressionUtils`

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

INT-2928: Do Not Fallback to BF's ConversionService

* Polishing according PR's comments
* Important note about `conversionService` & `integrationConversionService` beans
* Link a JIRA about elimination of `BeanFactory`'s `ConversionService` usage
* Add a note to the 2.2-3.0 Migration Guide

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

INT-2888 Doc Polishing
2013-02-12 10:51:36 -05:00
Gunnar Hillert
629566c738 INT-2526 - Remove additional deprecations in Core 2013-02-11 23:42:05 -05:00
Soby Chacko
05cd8e68c0 INT-2526: Remove deprecations in Core after upgrade to Spring 3.1.1
* remove deprecated usage of ConversionServiceFactory.createDefaultConversionService()
* remove deprecated usage of AopUtils.isCglibProxyClass

JIRA: https://jira.springsource.org/browse/INT-2526
2013-02-11 23:41:15 -05:00
Gary Russell
91722b7a5f INT-2830 Resolve Class Tangle
* MessageGroupStore <-> MessageGroupCallback
  - Change callback to be an inner interface of the MGS.
* INT-2829 Fix Class Tangle in IP Module
  - 3 way tangle between TcpSender, TcpConnection, TcpMessageMapper
  - Clean up interfaces (remove setters); add top-level support classes for TcpConnection, TcpConnectionInterceptor.
* INT-2829 Remove TCP Package Tangle
  - tcp.connection <-> tcp.connection.support
  - Remove ...connection.support package - move classes to ...connection.
2013-02-08 17:58:17 -05:00
Nick Spacek
6e6d1c60c9 INT-2920 Fix two hits to MessageStore
Reduce ClaimCheckOutTransformer's hits to the MessageStore.

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

Add @author and update copyright

Fixed missing semi-colon
2013-02-08 16:32:36 -05:00
Artem Bilan
dc59207df2 INT-2893: fix chain -> router -> bean or script
* add XSD element for nested router type
* add tests on the matter
* polishing for RouterParserTests

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

INT-2893: Polishing

INT-2893: after rebasing to 3.0

XSD changes reverted from 2.2 and moved to 3.0

INT-2893 Polishing

Factor out common elements; fixing missing documentation for
`expression` within a `router` within a `chain`.
2013-02-05 12:30:19 -05:00