Behavior Change in Exception Handling with Ordered Message Processing #33937
Labels
in: messaging
Issues in messaging modules (jms, messaging)
status: feedback-provided
Feedback has been provided
status: waiting-for-triage
An issue we've not yet triaged or decided on
I have configured
registry.setPreserveReceiveOrder(true);
to process received messages in orderand am using Spring Security to perform authorization checks during subscriptions.
Before enabling this option, we were using
ExecutorSubscribableChannel
, where exceptions were wrapped in aMessageDeliveryException
and thrown to the higher layers.After enabling this option, however, exceptions are caught by
OrderedMessageChannelDecorator
during processing, preventing error messages from being delivered to the client when subscription authorization fails.Previously, exceptions were propagated to
StompSubProtocolErrorHandler
viaStompSubProtocolHandler.handleError()
Is this behavior—preventing exceptions from being propagated to the client—an intended design?
Is there a way to propagate exceptions to the client through
StompSubProtocolErrorHandler
?The versions in use are Spring Boot 3.3.0 and Spring WebSocket/Message 6.1.8.
The text was updated successfully, but these errors were encountered: