activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From riskman <tdllo...@yahoo.com.cn>
Subject basic question about camel routing configuration with activemq and stomp client
Date Tue, 08 Dec 2009 04:18:29 GMT

  I am using stomp client(c client) to send message to activeMQ server,I want
to use camel configuration file to route message from one queue to
another,shown as below.
   A(stomp client)------msg--->(MyQueue)activeMQ(camel xml
routing)->(OtherQueue)<-----SUB------B(stomp client)
 
 part of A's code:
 92       stomp_frame frame;
 93       frame.command = "SEND";
 94       frame.headers = apr_hash_make(pool);
 95       apr_hash_set(frame.headers, "destination", APR_HASH_KEY_STRING,
"/queue/MyQueue");
 96 
 97       frame.body_length = -1;
 98       frame.body = "This is the message from tdl";
 99       rc = stomp_write(connection, &frame, pool);
100       rc==APR_SUCCESS || die(-2, "Could not send frame", rc);


   part of B's code:
 93       stomp_frame *frame;
 94       rc = stomp_read(connection, &frame, pool);
 95       rc==APR_SUCCESS || die(-2, "Could not read frame", rc);
 96       fprintf(stdout, "Response: %s, %s\n", frame->command,
frame->body);

  I tried all kinds of configuration in /activeMQ/conf/camel.xml, yet the
message sent by A to MyQueue never
routed to OtherQueue( in other words get by B)

  one case of  camel.xml conf is shown below(does not work)
 43            <route>
 44             <from uri="activemq:queue.MyQueue"/>
 45             <to uri="activemq:queue.OtherQueue"/>
 46         </route>

can anyone please help me to write the right configuration file,
or show me some other way to implement my requirement.
 


 
-- 
View this message in context: http://old.nabble.com/basic-question-about-camel-routing-configuration-with-activemq-and--stomp-client-tp26688484p26688484.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message