-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Spring Integration 2.2 to 3.0 Migration Guide
##MessageGroupCallback
This interface is now an inner interface of MessageGroupStore; everything remains the same, just change the import.
##integrationConversionService
Spring Integration no longer does fall back to the BeanFactory
's ConversionService
, however there is still falling back to the creation of DefaultConversionService
where it is appropriate, if there is no registered integrationConversionService bean. If there is really a reason to use conversionService
as integrationConversionService
, it's just enough to add one more line to the Application Context:
<alias name="conversionService" alias="integrationConversionService"/>
##Aggregator & Resequencer
<aggregator>
no longer iterates over message groups in the AggregatingMessageHandler#setExpireGroupsUponCompletion
to remove complete groups. It could lead to an overload on application start up with a big persistent MessageStore
. The similar logic is present on the AbstractCorrelatingMessageHandler#forceComplete
, when expiring of message groups removes empty groups as well. An empty group is comlete too, as for <aggregator>
, and for <resequencer>
: on each 'release' the group is marked as 'comlete' and relased messages is removed from the group.
For removing empty groups purpose there is need to configure a MessageGroupStoreReaper
for the MessageStore
of the <aggregator>
or the <resequencer>
.
In additional to achieve better robustness and flexibility was introduced an empty-group-min-timeout
attribute for the <aggregator>
and the <resequencer>
. If you wish to run empty group deletion on a longer
schedule than expiring partial groups, set this property. Empty groups will then not be removed from the MessageStore
until they have not been modified for at least this number of milliseconds.
In prior versions of Spring Integration the functionality of the XPath Filter was configured using the xpath-selector element. However, in order to provide a more consistent behavior within the Spring Integration Framework, the xpath-selector element has been removed.
Please use the xpath-filter instead. It provides the same set of functionality. In fact it still uses the same MessageSelectors internally.
##JSON Transformers
A new abstraction for JSON conversion has been introduced: JsonObjectMapper
. Implementations for Jackson 1.x and Jackson 2 are currently provided (JacksonJsonObjectMapper
and Jackson2JsonObjectMapper
resp.), with the version being determined by presence on the classpath. Usage of Jackson 1.x ObjectMapper
for <object-to-json-transformer>
and <json-to-object-transformer>
is still supported, but it is deprecated and will be removed in future releases. JsonInboundMessageMapper
and JsonOutboundMessageMapper
have been changed to use new JSON strategy too.
JsonInboundMessageMapper
now requires an implementation of JsonInboundMessageMapper.JsonMessageParser
as one of constructor arguments. JacksonJsonMessageParser
and Jackson2JsonMessageParser
implementations are provided out of the box.
##Core module packages refactoring
To avoid packages tangle and classes cycling there were introduced new packages: org.springframework.integration.support.context
and org.springframework.integration.support.json
. The NamedComponent
class and JSON infrustruscture classes (e.g. JsonObjectMapper
abstraction) were moved to new packages respectively.