Changes between 5.5 and 6.0

New Components

A Groovy DSL implementation for integration flow definitions has been added. See Groovy DSL for more information.spring-doc.cn

MQTT ClientManager

A new MQTT ClientManager has been added to support a reusable MQTT connection across different channel adapters. See Shared MQTT Client Support for more information.spring-doc.cn

GraphQL Support

The GraphQL support has been added. See GraphQL Support for more information.spring-doc.cn

Apache Camel Support

Support for Apache Camel routes has been introduced. See Apache Camel Support for more information.spring-doc.cn

Hazelcast Support

The Hazelcast Spring Integration Extensions project has been migrated as the spring-integration-hazelcast module. See Hazelcast Support for more information.spring-doc.cn

SMB Support

SMB support has been added from the Spring Integration Extensions project. The Java DSL (see org.springframework.integration.smb.dsl.Smb factory) also has been added to this module. An SmbStreamingMessageSource and SmbOutboundGateway implementation are introduced. See SMB Support for more information.spring-doc.cn

PostgreSQL Push Notification

A PostgresSubscribableChannel allows to receive push notifications via PostgresChannelMessageTableSubscriber upon new messages add to the JdbcChannelMessageStore.spring-doc.cn

RabbitMQ Stream Queue Support

The AMQP module has been enhanced to provide support for inbound and outbound channel adapters using RabbitMQ Stream Queues. See RabbitMQ Stream Queue Support for more information.spring-doc.cn

Apache MINA SFTP

The SFTP modules has been fully reworked from outdated JCraft JSch library to more robust and modern org.apache.sshd:sshd-sftp module of the Apache MINA project.spring-doc.cn

See SFTP Adapters for more information.spring-doc.cn

Micrometer Observation

Enabling observation for timers and tracing using Micrometer is now supported. See Micrometer Observation for more information.spring-doc.cn

GraalVM Polyglot Support

The Scripting module now provides a PolyglotScriptExecutor implementation based on the GraalVM Polyglot support. JavaScript support is now based on this executor since its JSR223 implementation has been removed from Java by itself. See Scripting Support for more information.spring-doc.cn

Apache Cassandra Support

The Apache Cassandra Spring Integration Extensions project has been migrated as the spring-integration-cassandra module. See Apache Cassandra Support for more information.spring-doc.cn

Kotlin Coroutines

Kotlin Coroutines support has been introduced to the framework.spring-doc.cn

See Kotlin Coroutines for more information.spring-doc.cn

Native Images

Support for creating GraalVM native images is provided. See Native Images Support for more information.spring-doc.cn

General Changes

The messaging annotations are now @Repeatable and the same type can be declared several times on the same service method. The messaging annotations don’t require a poller attribute as an array of @Poller anymore.spring-doc.cn

See Annotation Support for more information.spring-doc.cn

For convenience, the XML and Java DSL for Scatter-Gather, based on the RecipientListRouter, now sets an applySequence = true, so the gatherer part can rely on the default correlation strategies.spring-doc.cn

See Scatter-Gather for more information.spring-doc.cn

Another convenient behavior change has been made to the AbstractMappingMessageRouter. Now, setting a defaultOutputChannel also resets the channelKeyFallback property to false, so no attempts will be made to resolve a channel from its key, but the logic immediately falls back to sending the message to the defaultOutputChannel.spring-doc.cn

See Router Options for more information.spring-doc.cn

The AggregatingMessageHandler now does not split a Collection<Message<?>> result of the MessageGroupProcessor (unless it is a SimpleMessageGroupProcessor) on the output, but emits a single message containing this whole collection as a payload.spring-doc.cn

See Aggregator for more information.spring-doc.cn

The IntegrationFlows factory is now marked as deprecated in favor of the fluent API available in the IntegrationFlow interface itself. The factory class will be removed in the future releases.spring-doc.cn

See Java DSL for more information.spring-doc.cn

The org.springframework.util.concurrent.ListenableFuture has been deprecated starting with Spring Framework 6.0. All Spring Integration async API has been migrated to the CompletableFuture.spring-doc.cn

The Messaging Gateway interface method can now return Future<Void> and Mono<Void> with a proper asynchronous execution of the downstream flow.spring-doc.cn

Alongside with a @MessagingGateway annotation the interface can also be marked with a @Primary.spring-doc.cn

@MessagingGateway interfaces can now be use as an @Import resources for configuration.spring-doc.cn

The default naming strategy for gateway proxy beans can be customized via @IntegrationComponentScan.nameGenerator() attribute. If AnnotationConfigUtils.CONFIGURATION_BEAN_NAME_GENERATOR bean is present, it is consulted otherwise before falling back to the AnnotationBeanNameGenerator.spring-doc.cn

See Messaging Gateway for more information.spring-doc.cn

The integrationGlobalProperties bean is now declared by the framework as an instance of org.springframework.integration.context.IntegrationProperties instead of the previously deprecated java.util.Properties.spring-doc.cn

Message handlers which produce a collection as a reply (e.g. JpaOutboundGateway, JdbcOutboundGateway and other DB-based gateways) now return an empty result list if no records are returned by the query. Previously, null was returned ending the flow, or throwing an exception, depending on requiresReply.spring-doc.cn

RMI Removal

The spring-integration-rmi module has been removed altogether after being deprecated in previous versions. There is no replacement: it is recommended to migrate to more secure network and application protocols, such as WebSockets, RSockets, gRPC or REST.spring-doc.cn

GemFire Removal

The spring-integration-gemfire module has been removed altogether since there is no Spring Data 2022.0.0 support for VMware GemFire or Apache Geode.spring-doc.cn

HTTP Changes

The #cookies variable for expression evaluation context, exposed in the HttpRequestHandlingEndpointSupport, is now a MultiValueMap to carry all the values for cookies set by the client. See HTTP Support for more information.spring-doc.cn

Apache Kafka Changes

When providing a RetryTemplate on the inbound gateway or message-driven channel adapter, if an errorChannel is also provided, an ErrorMessageSendingRecoverer is automatically configured.spring-doc.cn

In addition, the new KafkaErrorMessageSendingRecoverer is provided; this can be used with a DefaultErrorHandler to avoid issues with long aggregated retry delays causing partitions rebalances.spring-doc.cn

JDBC Changes

The DefaultLockRepository can now be supplied with a PlatformTransactionManager instead of relying on the primary bean from the application context.spring-doc.cn

See JDBC Lock Registry for more information.spring-doc.cn

TCP/IP Changes

The lookupHost property of the AbstractConnectionFactory and DatagramPacketMessageMapper is now set to false by default to avoid delays in the environments where DNS is not configured.spring-doc.cn

See TCP and UDP Support for more information.spring-doc.cn

JMS Changes

The JmsOutboundGateway now creates a TemporaryTopic instead of TemporaryQueue if replyPubSubDomain option is set to true.spring-doc.cn

See JMS Support for more information.spring-doc.cn

Security Changes

The ChannelSecurityInterceptor and its annotation @SecuredChannel and XML <secured-channels> configurations have been deprecated in favor of AuthorizationChannelInterceptor.spring-doc.cn

See Security Support for more information.spring-doc.cn

Webflux Request Attributes Support

Webclient Request attributes support has been added for WebFluxRequestExecutingMessageHandler.spring-doc.cn

See WebFlux Request Attributes for more information.spring-doc.cn