Closed spring-projects-issues closed 1 year ago
This is similar to #18562 but for the clientInboundChannel
. Most of the logic is in OrderedMessageChannelDecorator
which is used to decorate the brokerChannerl
. We could do the same but for the clientInboundChannel
enabled through an additional property similar to preservePublishOrder
.
Marcus Held opened SPR-17265 and commented
In my project I have the case that a client can potentially send a lot of messages simultaneously (which we prefer to avoid, but still can happen. Esp. with hacked clients). This leads to many different threads to modify the state of the same entity which then cause optimistic locking exceptions.
To avoid this I'd like to process all messages of the same client in the same thread. This behavior could be achieved by configuring a
ThreadPoolTaskExecutor
that distributes the messages accordingly. This strategy was suggested in this stackoverflow question.1 votes, 2 watchers