GH-10046: Propagate error strategy in the JmsEndpoint

Fixes: #10046
Issue link: https://github.com/spring-projects/spring-integration/issues/10046

The `JmsMessageDrivenEndpoint` does not propagate an `ErrorMessageStrategy` down to the `ChannelPublishingJmsMessageListener.GatewayDelegate`

* Expose `JmsMessageDrivenEndpoint.setErrorMessageStrategy()` and call respective `this.listener.setErrorMessageStrategy()`

(cherry picked from commit da1ec071c5)
This commit is contained in:
Artem Bilan
2025-05-20 11:20:39 -04:00
committed by Spring Builds
parent ad376f27cc
commit b1fe555044
4 changed files with 30 additions and 5 deletions

View File

@@ -164,7 +164,7 @@ public abstract class MessageProducerSupport extends AbstractEndpoint
* @param errorMessageStrategy the {@link ErrorMessageStrategy}.
* @since 4.3.10
*/
public final void setErrorMessageStrategy(ErrorMessageStrategy errorMessageStrategy) {
public void setErrorMessageStrategy(ErrorMessageStrategy errorMessageStrategy) {
Assert.notNull(errorMessageStrategy, "'errorMessageStrategy' cannot be null");
this.errorMessageStrategy = errorMessageStrategy;
}