Closed
Description
David J. M. Karlsen opened SPR-3332 and commented
Add support for synchronous send and receive in JmsTemplate, something like this:
Object response = doSendAndReceive( String requestDestination, String responseDestination, Object value )
throws JmsException
which uses SimpleMessageConverter to convert value to message, destinationResolver to resolve response and request destinations, set's JmsReplyTo to responseDestination, and uses the generated messageId to select the responsemessage, waiting for getReceiveTimeout() milliseconds to receive.
This is a very common usecase - and I think it should be supported directly by the framework - without having to use Jencks or the likes.
Affects: 2.0.3
Attachments:
- JmsTemplateSynchronous.txt (1.35 kB)
- sessioncallbackcode.txt (1.45 kB)
Issue Links:
- INT-2683 Enable cachability of consumers for reply-side of JmsOutboundGateway
- Update JmsMessagingTemplate to support MessageRequestReplyOperations [SPR-12037] #16653 Update JmsMessagingTemplate to support MessageRequestReplyOperations
- Support "request message id as response correlation id" in MessageListenerAdapter [SPR-4647] #9324 Support "request message id as response correlation id" in MessageListenerAdapter
21 votes, 25 watchers