On 07/08/2016 06:16 AM, LeBro wrote:
I started to work with Activemq-cpp and used the asychronous client that is
available as example. But now I want to implement a request-response, i.e.
the producer starts SENDINGa message to the consumer and WAITS for the
response. The consumer GETS the message, CHANGES it and SENDS back to the
producer. The consumer has a receive option, but I have no idea how to
configure both for request-response, especially the producer.

I appriciate any help. Thx in advance.



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/Activemq-cpp-request-response-tp4713776.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


The CMS client is a porting of JMS to C++ and as such the examples <http://activemq.apache.org/how-should-i-implement-request-response-with-jms.html> that explain how to do JMS Request / Response are easy to port to the C++ client.

The basic structure is that on the request side the client must create a producer to send the request and a consumer to process the response. The consumer should be created and be listening on the target response destination prior to sending the request. On the responder side a consumer is created that reads from the request Queue and does its work and when done it creates a producer that sends a response to the destination specified in the ReplyTo property of the incoming request.


--
Tim Bish
twitter: @tabish121
blog: http://timbish.blogspot.com/

Reply via email to