diff --git a/build.gradle b/build.gradle index 0a6392232e..9750a91a93 100644 --- a/build.gradle +++ b/build.gradle @@ -55,10 +55,10 @@ ext { assertkVersion = '0.25' avroVersion = '1.11.1' awaitilityVersion = '4.2.0' - camelVersion = '3.19.0' + camelVersion = '3.20.1' commonsDbcp2Version = '2.9.0' commonsIoVersion = '2.11.0' - commonsNetVersion = '3.8.0' + commonsNetVersion = '3.9.0' curatorVersion = '5.4.0' derbyVersion = '10.16.1.1' findbugsVersion = '3.0.1' @@ -83,34 +83,35 @@ ext { junitJupiterVersion = '5.9.2' jythonVersion = '2.7.3' kotlinCoroutinesVersion = '1.6.4' - kryoVersion = '5.3.0' + kryoVersion = '5.4.0' lettuceVersion = '6.2.3.RELEASE' log4jVersion = '2.19.0' mailVersion = '1.0.0' - micrometerTracingVersion = '1.0.2' - micrometerVersion = '1.10.4' - mockitoVersion = '4.10.0' + micrometerPropagationVersion = '1.0.1-SNAPSHOT' + micrometerTracingVersion = '1.0.2-SNAPSHOT' + micrometerVersion = '1.11.0-SNAPSHOT' + mockitoVersion = '5.1.1' mongoDriverVersion = '4.8.2' mysqlVersion = '8.0.32' pahoMqttClientVersion = '1.2.5' - postgresVersion = '42.5.4' + postgresVersion = '42.5.2' r2dbch2Version = '1.0.0.RELEASE' - reactorVersion = '2022.0.3' - resilience4jVersion = '1.7.1' + reactorVersion = '2022.0.3-SNAPSHOT' + resilience4jVersion = '2.0.2' romeToolsVersion = '1.18.0' rsocketVersion = '1.1.3' servletApiVersion = '6.0.0' smackVersion = '4.4.6' - springAmqpVersion = '3.0.2' - springDataVersion = '2022.0.2' - springGraphqlVersion = '1.1.2' - springKafkaVersion = '3.0.3' + springAmqpVersion = '3.0.2-SNAPSHOT' + springDataVersion = '2023.0.0-SNAPSHOT' + springGraphqlVersion = '1.2.0-SNAPSHOT' + springKafkaVersion = '3.0.3-SNAPSHOT' springRetryVersion = '2.0.0' - springSecurityVersion = '6.0.2' - springVersion = '6.0.5' + springSecurityVersion = '6.1.0-SNAPSHOT' + springVersion = '6.0.5-SNAPSHOT' springWsVersion = '4.0.1' testcontainersVersion = '1.17.6' - tomcatVersion = '10.1.5' + tomcatVersion = '11.0.0-M1' xmlUnitVersion = '2.9.1' xstreamVersion = '1.4.20' diff --git a/gradle.properties b/gradle.properties index 04a4232c86..0e8313c53d 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ -version=6.0.4-SNAPSHOT +version=6.1.0-SNAPSHOT org.gradle.jvmargs=-Xmx1536M -Dfile.encoding=UTF-8 kotlin.jvm.target.validation.mode=IGNORE org.gradle.caching=true diff --git a/gradle/docs.gradle b/gradle/docs.gradle index 6884e9979f..c637e3b7d2 100644 --- a/gradle/docs.gradle +++ b/gradle/docs.gradle @@ -1,6 +1,6 @@ ext { - backendVersion = '0.0.3' - micrometerDocsVersion='1.0.0' + backendVersion = '0.0.4' + micrometerDocsVersion='1.0.1' } configurations { diff --git a/spring-integration-camel/src/test/java/org/springframework/integration/camel/outbound/CamelMessageHandlerTests.java b/spring-integration-camel/src/test/java/org/springframework/integration/camel/outbound/CamelMessageHandlerTests.java index ac7b94f77f..705a799a9a 100644 --- a/spring-integration-camel/src/test/java/org/springframework/integration/camel/outbound/CamelMessageHandlerTests.java +++ b/spring-integration-camel/src/test/java/org/springframework/integration/camel/outbound/CamelMessageHandlerTests.java @@ -1,5 +1,5 @@ /* - * Copyright 2022 the original author or authors. + * Copyright 2022-2023 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -66,7 +66,7 @@ public class CamelMessageHandlerTests extends CamelTestSupport { camelMessageHandler.handleMessage(messageUnderTest); camelMessageHandler.handleMessage(messageUnderTest2); - assertMockEndpointsSatisfied(); + mockEndpoint.assertIsSatisfied(); } @Test @@ -104,7 +104,7 @@ public class CamelMessageHandlerTests extends CamelTestSupport { Message receive = replyChannel.receive(10_000); - assertMockEndpointsSatisfied(); + mockEndpoint.assertIsSatisfied(); assertThat(receive).isNotNull(); assertThat(receive.getPayload()).isEqualTo("Reply for: test data"); @@ -121,10 +121,10 @@ public class CamelMessageHandlerTests extends CamelTestSupport { .setHeader(MessageHeaders.ERROR_CHANNEL, errorChannel) .build(); - getMockEndpoint("mock:result") - .whenAnyExchangeReceived(exchange -> { - throw new RuntimeException("intentional"); - }); + MockEndpoint mockEndpoint = getMockEndpoint("mock:result"); + mockEndpoint.whenAnyExchangeReceived(exchange -> { + throw new RuntimeException("intentional"); + }); CamelMessageHandler camelMessageHandler = new CamelMessageHandler(template()); camelMessageHandler.setEndpointUri("direct:simple"); @@ -135,7 +135,7 @@ public class CamelMessageHandlerTests extends CamelTestSupport { camelMessageHandler.handleMessage(messageUnderTest); Message receive = errorChannel.receive(10_000); - assertMockEndpointsSatisfied(); + mockEndpoint.assertIsSatisfied(); assertThat(receive).isNotNull(); assertThat(receive.getPayload()) @@ -169,7 +169,7 @@ public class CamelMessageHandlerTests extends CamelTestSupport { Message receive = replyChannel.receive(10_000); - assertMockEndpointsSatisfied(); + mockEndpoint.assertIsSatisfied(); assertThat(receive).isNotNull(); assertThat(receive.getPayload()).isEqualTo("Async reply for: test async data"); diff --git a/spring-integration-core/src/main/java/org/springframework/integration/handler/advice/RateLimiterRequestHandlerAdvice.java b/spring-integration-core/src/main/java/org/springframework/integration/handler/advice/RateLimiterRequestHandlerAdvice.java index 73baead1de..12f11e8f2c 100644 --- a/spring-integration-core/src/main/java/org/springframework/integration/handler/advice/RateLimiterRequestHandlerAdvice.java +++ b/spring-integration-core/src/main/java/org/springframework/integration/handler/advice/RateLimiterRequestHandlerAdvice.java @@ -1,5 +1,5 @@ /* - * Copyright 2019-2022 the original author or authors. + * Copyright 2019-2023 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -16,13 +16,12 @@ package org.springframework.integration.handler.advice; +import java.io.Serial; import java.time.Duration; import io.github.resilience4j.ratelimiter.RateLimiter; import io.github.resilience4j.ratelimiter.RateLimiterConfig; import io.github.resilience4j.ratelimiter.RequestNotPermitted; -import io.vavr.CheckedFunction0; -import io.vavr.control.Try; import org.springframework.messaging.Message; import org.springframework.messaging.MessagingException; @@ -128,10 +127,8 @@ public class RateLimiterRequestHandlerAdvice extends AbstractRequestHandlerAdvic @Override protected Object doInvoke(ExecutionCallback callback, Object target, Message message) { - CheckedFunction0 restrictedCall = - RateLimiter.decorateCheckedSupplier(this.rateLimiter, callback::execute); try { - return Try.of(restrictedCall).get(); + return RateLimiter.decorateSupplier(this.rateLimiter, callback::execute).get(); } catch (RequestNotPermitted ex) { throw new RateLimitExceededException(message, "Rate limit exceeded for: " + target, ex); @@ -145,6 +142,7 @@ public class RateLimiterRequestHandlerAdvice extends AbstractRequestHandlerAdvic */ public static class RateLimitExceededException extends MessagingException { + @Serial private static final long serialVersionUID = 1L; RateLimitExceededException(Message message, String description, RequestNotPermitted cause) { diff --git a/spring-integration-ftp/src/main/java/org/springframework/integration/ftp/session/AbstractFtpSessionFactory.java b/spring-integration-ftp/src/main/java/org/springframework/integration/ftp/session/AbstractFtpSessionFactory.java index c608b969f7..f249efc045 100644 --- a/spring-integration-ftp/src/main/java/org/springframework/integration/ftp/session/AbstractFtpSessionFactory.java +++ b/spring-integration-ftp/src/main/java/org/springframework/integration/ftp/session/AbstractFtpSessionFactory.java @@ -17,6 +17,7 @@ package org.springframework.integration.ftp.session; import java.io.IOException; +import java.time.Duration; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; @@ -186,7 +187,7 @@ public abstract class AbstractFtpSessionFactory implements client.setDefaultTimeout(this.defaultTimeout); } if (this.dataTimeout != null) { - client.setDataTimeout(this.dataTimeout); + client.setDataTimeout(Duration.ofMillis(this.dataTimeout)); } client.setControlEncoding(this.controlEncoding); diff --git a/spring-integration-ftp/src/test/java/org/springframework/integration/ftp/session/SessionFactoryTests.java b/spring-integration-ftp/src/test/java/org/springframework/integration/ftp/session/SessionFactoryTests.java index 56ede75e5c..573a37f790 100644 --- a/spring-integration-ftp/src/test/java/org/springframework/integration/ftp/session/SessionFactoryTests.java +++ b/spring-integration-ftp/src/test/java/org/springframework/integration/ftp/session/SessionFactoryTests.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2022 the original author or authors. + * Copyright 2002-2023 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -17,6 +17,7 @@ package org.springframework.integration.ftp.session; import java.lang.reflect.Field; +import java.time.Duration; import java.util.Random; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; @@ -74,7 +75,7 @@ class SessionFactoryTests { FtpSession session = sessionFactory.getSession(); verify(client).setConnectTimeout(123); verify(client).setDefaultTimeout(456); - verify(client).setDataTimeout(789); + verify(client).setDataTimeout(Duration.ofMillis(789)); session.close(); diff --git a/src/reference/asciidoc/changes-5.5-6.0.adoc b/src/reference/asciidoc/changes-5.5-6.0.adoc new file mode 100644 index 0000000000..632656d711 --- /dev/null +++ b/src/reference/asciidoc/changes-5.5-6.0.adoc @@ -0,0 +1,198 @@ +[[migration-5.5-6.0]] +=== Changes between 5.5 and 6.0 + +[[x6.0-new-components]] +=== New Components + +A Groovy DSL implementation for integration flow definitions has been added. +See <<./groovy-dsl.adoc#groovy-dsl,Groovy DSL>> for more information. + +[[x6.0-mqtt]] +==== MQTT ClientManager + +A new MQTT `ClientManager` has been added to support a reusable MQTT connection across different channel adapters. +See <<./mqtt.adoc#mqtt-shared-client,Shared MQTT Client Support>> for more information. + +[[x6.0-graphql]] +==== GraphQL Support + +The GraphQL support has been added. +See <<./graphql.adoc#graphql,GraphQL Support>> for more information. + +[[x6.0-camel]] +==== Apache Camel Support + +Support for Apache Camel routes has been introduced. +See <<./camel.adoc#camel,Apache Camel Support>> for more information. + +[[x6.0-hazelcast]] +==== Hazelcast Support + +The Hazelcast Spring Integration Extensions project has been migrated as the `spring-integration-hazelcast` module. +See <<./hazelcast.adoc#hazelcast,Hazelcast Support>> for more information. + +[[x6.0-smb]] +==== 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.adoc#smb,SMB Support>> for more information. + +[[x6.0-postgres]] +==== PostgreSQL Push Notification + +A `PostgresSubscribableChannel` allows to receive push notifications via `PostgresChannelMessageTableSubscriber` upon new messages add to the `JdbcChannelMessageStore`. + +See <<./jdbc.adoc#postgresql-push,PostgreSQL: Receiving Push Notifications>> for more information. + +[[x6.0-rmq]] +==== RabbitMQ Stream Queue Support + +The AMQP module has been enhanced to provide support for inbound and outbound channel adapters using RabbitMQ Stream Queues. +See <<./amqp.adoc#rmq-streams,RabbitMQ Stream Queue Support>> for more information. + +[[x6.0-sftp]] +==== 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. + +See <<./sftp.adoc#sftp,SFTP Adapters>> for more information. + +[[x6.0-micrometer-observation]] +==== Micrometer Observation + +Enabling observation for timers and tracing using Micrometer is now supported. +See <<./metrics.adoc#micrometer-observation,Micrometer Observation>> for more information. + +[[x6.0-graalmv-polyglot]] +==== 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.adoc#scripting,Scripting Support>> for more information. + +[[x6.0-cassandra]] +==== Apache Cassandra Support + +The Apache Cassandra Spring Integration Extensions project has been migrated as the `spring-integration-cassandra` module. +See <<./cassandra.adoc#cassandra,Apache Cassandra Support>> for more information. + +[[x6.0-kotlin-coroutines]] +==== Kotlin Coroutines + +Kotlin Coroutines support has been introduced to the framework. + +See <<./kotlin-functions.adoc#kotlin-coroutines,Kotlin Coroutines>> for more information. + +[[x6.0-aot]] +==== Native Images + +Support for creating GraalVM native images is provided. +See <<./native-aot.adoc#native-images-support,Native Images Support>> for more information. + +[[x6.0-general]] +=== 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. + +See <<./configuration.adoc#annotations,Annotation Support>> for more information. + +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. + +See <<./scatter-gather.adoc#scatter-gather,Scatter-Gather>> for more information. + +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`. + +See <<./router.adoc#router-common-parameters-all,Router Options>> for more information. + +The `AggregatingMessageHandler` now does not split a `Collection>` result of the `MessageGroupProcessor` (unless it is a `SimpleMessageGroupProcessor`) on the output, but emits a single message containing this whole collection as a payload. + +See <<./aggregator.adoc#aggregator,Aggregator>> for more information. + +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. + +See <<./dsl.adoc#java-dsl,Java DSL>> for more information. + +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`. + +The Messaging Gateway interface method can now return `Future` and `Mono` with a proper asynchronous execution of the downstream flow. + +Alongside with a `@MessagingGateway` annotation the interface can also be marked with a `@Primary`. + +`@MessagingGateway` interfaces can now be use as an `@Import` resources for configuration. + +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`. + +See <<./gateway.adoc#gateway, Messaging Gateway>> for more information. + +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`. + +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`. + +[[x6.0-rmi]] +=== 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. + +[[x6.0-gemfire]] +=== 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. + +[[x6.0-http]] +=== 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.adoc#http,HTTP Support>> for more information. + +[[x6.0-kafka]] +=== 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. + +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. + +See <<./kafka.adoc#kafka,Spring for Apache Kafka Support>> for more information. + +[[x6.0-jdbc]] +=== JDBC Changes + +The `DefaultLockRepository` can now be supplied with a `PlatformTransactionManager` instead of relying on the primary bean from the application context. + +See <<./jdbc.adoc#jdbc-lock-registry,JDBC Lock Registry>> for more information. + +[[x6.0-tcp]] +=== 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. + +See <<./ip.adoc#ip,TCP and UDP Support>> for more information. + +[[x6.0-jms]] +=== JMS Changes + +The `JmsOutboundGateway` now creates a `TemporaryTopic` instead of `TemporaryQueue` if `replyPubSubDomain` option is set to `true`. + +See <<./jms.adoc#jms,JMS Support>> for more information. + +[[x6.0-security]] +=== Security Changes + +The `ChannelSecurityInterceptor` and its annotation `@SecuredChannel` and XML `` configurations have been deprecated in favor of `AuthorizationChannelInterceptor`. + +See <<./security.adoc#security,Security Support>> for more information. + +[[x6.0-webflux]] +=== Webflux Request Attributes Support + +Webclient Request attributes support has been added for `WebFluxRequestExecutingMessageHandler`. + +See <<./webflux.adoc#webflux-request-attributes,WebFlux Request Attributes>> for more information. diff --git a/src/reference/asciidoc/history.adoc b/src/reference/asciidoc/history.adoc index bbc08046c0..fda99eaf6a 100644 --- a/src/reference/asciidoc/history.adoc +++ b/src/reference/asciidoc/history.adoc @@ -2,6 +2,8 @@ == Change History // BE SURE TO PRECEDE ALL include:: with a blank line - see https://github.com/asciidoctor/asciidoctor/issues/1297 +include::./changes-5.5-6.0.adoc[] + include::./changes-5.4-5.5.adoc[] include::./changes-5.3-5.4.adoc[] diff --git a/src/reference/asciidoc/index-header.adoc b/src/reference/asciidoc/index-header.adoc index e5848487da..031377fa13 100644 --- a/src/reference/asciidoc/index-header.adoc +++ b/src/reference/asciidoc/index-header.adoc @@ -2,7 +2,7 @@ = Spring Integration Reference Guide Mark Fisher; Marius Bogoevici; Iwein Fuld; Jonas Partner; Oleg Zhurakousky; Gary Russell; Dave Syer; Josh Long; David Turanski; Gunnar Hillert; Artem Bilan; Amol Nayak; Jay Bryant -(C) 2009 - 2022 VMware, Inc. +(C) 2009 - 2023 VMware, Inc. All rights reserved. Copies of this document may be made for your own use and for distribution to others, provided that you do not charge any fee for such copies and further provided that each copy contains this Copyright Notice, whether distributed in print or electronically. diff --git a/src/reference/asciidoc/preface.adoc b/src/reference/asciidoc/preface.adoc index 4296ce451b..752b70f850 100644 --- a/src/reference/asciidoc/preface.adoc +++ b/src/reference/asciidoc/preface.adoc @@ -15,13 +15,13 @@ This section details the compatible https://www.oracle.com/technetwork/java/java [[supported-java-versions]] === Compatible Java Versions -For Spring Integration 6.0.x, the minimum compatible Java version is Java SE 17. +For Spring Integration 6.1.x, the minimum compatible Java version is Java SE 17. Older versions of Java are not supported. [[supported-spring-versions]] === Compatible Versions of the Spring Framework -Spring Integration 6.0.x requires Spring Framework 6.0 or later. +Spring Integration 6.1.x requires Spring Framework 6.0 or later. [[code-conventions]] == Code Conventions @@ -90,4 +90,4 @@ Spring Boot provides a quick (and opinionated) way to create a production-ready It is based on the Spring Framework, favors convention over configuration, and is designed to get you up and running as quickly as possible. You can use https://start.spring.io/[start.spring.io] to generate a basic project (add `integration` as dependency) or follow one of the https://spring.io/guides["Getting Started" guides], such as https://spring.io/guides/gs/integration/[Getting Started Building an Integrating Data]. -As well as being easier to digest, these guides are very task focused, and most of them are based on Spring Boot. \ No newline at end of file +As well as being easier to digest, these guides are very task focused, and most of them are based on Spring Boot. diff --git a/src/reference/asciidoc/whats-new.adoc b/src/reference/asciidoc/whats-new.adoc index 9c1765c4cd..19756a9ebc 100644 --- a/src/reference/asciidoc/whats-new.adoc +++ b/src/reference/asciidoc/whats-new.adoc @@ -2,213 +2,22 @@ = What's New? [[spring-integration-intro-new]] -For those who are already familiar with Spring Integration, this chapter provides a brief overview of the new features of version 6.0. +For those who are already familiar with Spring Integration, this chapter provides a brief overview of the new features of version 6.1. If you are interested in the changes and features that were introduced in earlier versions, see the <<./history.adoc#history,Change History>>. [[whats-new]] -== What's New in Spring Integration 6.0? +== What's New in Spring Integration 6.1? -If you are interested in more details, see the Issue Tracker tickets that were resolved as part of the 6.0 development process. +If you are interested in more details, see the Issue Tracker tickets that were resolved as part of the 6.1 development process. -In general the project has been moved to Java 17 baseline and migrated from Java EE to Jakarta EE. +In general the project has been moved to the latest dependency versions. -[[x6.0-new-components]] +[[x6.1-new-components]] === New Components -A Groovy DSL implementation for integration flow definitions has been added. -See <<./groovy-dsl.adoc#groovy-dsl,Groovy DSL>> for more information. -[[x6.0-mqtt]] -==== MQTT ClientManager -A new MQTT `ClientManager` has been added to support a reusable MQTT connection across different channel adapters. -See <<./mqtt.adoc#mqtt-shared-client,Shared MQTT Client Support>> for more information. - -[[x6.0-graphql]] -==== GraphQL Support - -The GraphQL support has been added. -See <<./graphql.adoc#graphql,GraphQL Support>> for more information. - -[[x6.0-camel]] -==== Apache Camel Support - -Support for Apache Camel routes has been introduced. -See <<./camel.adoc#camel,Apache Camel Support>> for more information. - -[[x6.0-hazelcast]] -==== Hazelcast Support - -The Hazelcast Spring Integration Extensions project has been migrated as the `spring-integration-hazelcast` module. -See <<./hazelcast.adoc#hazelcast,Hazelcast Support>> for more information. - -[[x6.0-smb]] -==== 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.adoc#smb,SMB Support>> for more information. - -[[x6.0-postgres]] -==== PostgreSQL Push Notification - -A `PostgresSubscribableChannel` allows to receive push notifications via `PostgresChannelMessageTableSubscriber` upon new messages add to the `JdbcChannelMessageStore`. - -See <<./jdbc.adoc#postgresql-push,PostgreSQL: Receiving Push Notifications>> for more information. - -[[x6.0-rmq]] -==== RabbitMQ Stream Queue Support - -The AMQP module has been enhanced to provide support for inbound and outbound channel adapters using RabbitMQ Stream Queues. -See <<./amqp.adoc#rmq-streams,RabbitMQ Stream Queue Support>> for more information. - -[[x6.0-sftp]] -==== 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. - -See <<./sftp.adoc#sftp,SFTP Adapters>> for more information. - -[[x6.0-micrometer-observation]] -==== Micrometer Observation - -Enabling observation for timers and tracing using Micrometer is now supported. -See <<./metrics.adoc#micrometer-observation,Micrometer Observation>> for more information. - -[[x6.0-graalmv-polyglot]] -==== 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.adoc#scripting,Scripting Support>> for more information. - -[[x6.0-cassandra]] -==== Apache Cassandra Support - -The Apache Cassandra Spring Integration Extensions project has been migrated as the `spring-integration-cassandra` module. -See <<./cassandra.adoc#cassandra,Apache Cassandra Support>> for more information. - -[[x6.0-kotlin-coroutines]] -==== Kotlin Coroutines - -Kotlin Coroutines support has been introduced to the framework. - -See <<./kotlin-functions.adoc#kotlin-coroutines,Kotlin Coroutines>> for more information. - -[[x6.0-aot]] -==== Native Images - -Support for creating GraalVM native images is provided. -See <<./native-aot.adoc#native-images-support,Native Images Support>> for more information. - -[[x6.0-general]] +[[x6.1-general]] === 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. - -See <<./configuration.adoc#annotations,Annotation Support>> for more information. - -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. - -See <<./scatter-gather.adoc#scatter-gather,Scatter-Gather>> for more information. - -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`. - -See <<./router.adoc#router-common-parameters-all,Router Options>> for more information. - -The `AggregatingMessageHandler` now does not split a `Collection>` result of the `MessageGroupProcessor` (unless it is a `SimpleMessageGroupProcessor`) on the output, but emits a single message containing this whole collection as a payload. - -See <<./aggregator.adoc#aggregator,Aggregator>> for more information. - -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. - -See <<./dsl.adoc#java-dsl,Java DSL>> for more information. - -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`. - -The Messaging Gateway interface method can now return `Future` and `Mono` with a proper asynchronous execution of the downstream flow. - -Alongside with a `@MessagingGateway` annotation the interface can also be marked with a `@Primary`. - -`@MessagingGateway` interfaces can now be use as an `@Import` resources for configuration. - -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`. - -See <<./gateway.adoc#gateway, Messaging Gateway>> for more information. - -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`. - -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`. - -[[x6.0-rmi]] -=== 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. - -[[x6.0-gemfire]] -=== 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. - -[[x6.0-http]] -=== 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.adoc#http,HTTP Support>> for more information. - -[[x6.0-kafka]] -=== 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. - -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. - -See <<./kafka.adoc#kafka,Spring for Apache Kafka Support>> for more information. - -[[x6.0-jdbc]] -=== JDBC Changes - -The `DefaultLockRepository` can now be supplied with a `PlatformTransactionManager` instead of relying on the primary bean from the application context. - -See <<./jdbc.adoc#jdbc-lock-registry,JDBC Lock Registry>> for more information. - -[[x6.0-tcp]] -=== 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. - -See <<./ip.adoc#ip,TCP and UDP Support>> for more information. - -[[x6.0-jms]] -=== JMS Changes - -The `JmsOutboundGateway` now creates a `TemporaryTopic` instead of `TemporaryQueue` if `replyPubSubDomain` option is set to `true`. - -See <<./jms.adoc#jms,JMS Support>> for more information. - -[[x6.0-security]] -=== Security Changes - -The `ChannelSecurityInterceptor` and its annotation `@SecuredChannel` and XML `` configurations have been deprecated in favor of `AuthorizationChannelInterceptor`. - -See <<./security.adoc#security,Security Support>> for more information. - -[[x6.0-webflux]] -=== Webflux Request Attributes Support - -Webclient Request attributes support has been added for `WebFluxRequestExecutingMessageHandler`. - -See <<./webflux.adoc#webflux-request-attributes,WebFlux Request Attributes>> for more information. - - -