PDA

View Full Version : How to send response to JMSReplyTo.



magnusheino
May 16th, 2008, 03:29 AM
Hi.

I have this:

<bean id="updateChannel" class="org.springframework.integration.dispatcher.Synchro nousChannel" />

<int:jms-source channel="updateChannel" message-converter="messageConverter" connection-factory="connectionFactory"
destination-name="${ems.prefix}.update" />

I have my service annotated with:

@Service("updateService")
@MessageEndpoint(input = "updateChannel")

and the handling method:

@Handler
@Transactional(propagation = Propagation.REQUIRES_NEW)
public String handleRequest(final Message<String> request) {

How can I have the String returned by the @Handler send to the JMSReplyTo set on the request Message?

Thanks,

/Magnus

Mark Fisher
May 16th, 2008, 06:59 AM
If you are using the latest SVN head version, you can try the "jms-gateway" instead of "jms-source". The idea is that a gateway provides request/reply behavior rather than in-only. The JMS gateway is a work-in-progress but will be available (and documented) in M4.

magnusheino
May 16th, 2008, 01:56 PM
Great, that sounds just like what I am looking for.

I'd rather wait for the M4 release. How up2date is the roadmap http://jira.springframework.org/browse/INT?report=com.atlassian.jira.plugin.system.projec t:roadmap-panel and estimated release date there?

/Magnus