You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Mick Knutson <mk...@baselogic.com> on 2009/08/12 02:07:41 UTC
Trying to understand route subscriptions
Can I create a Processor that is a subscriber to a topic?
Or is there another way besides creating multiple MDP consumers to form a
VirtualTopic?
I have an MDP and it consumes the message fine. But I also tried to add this
into my unit test:
// Create Consumer
Endpoint endpoint =
context.getEndpoint("activemq:Consumer.B.VirtualTopic.TEST");
PollingConsumer consumer = endpoint.createPollingConsumer();
// Send the test message to make Server Service create our Status
Message
template.sendBody("xxyyzz");
// Receive our message
Exchange exchange = consumer.receive();
log.info("### activemq:Consumer.B.VirtualTopic.TEST ###");
But in my server logs, I do not get a message sent and audited, and it
appears I still receive a message but in a LOOP.
Then I tried this:
// Create Consumer
Endpoint endpoint =
context.getEndpoint("activemq:Consumer.B.VirtualTopic.TEST");
Consumer consumer = endpoint.createConsumer(new ClientChecker());
// Send the test message to make Server Service create our Status
Message
template.sendBody("xxyyzz");
This did not seem to receive anything. So either:
1. Sending a message to "activemq:topic:VirtualTopic.TEST" did not forward
to "activemq:Consumer.B.VirtualTopic.TEST" at all.
2. I just do not have a correct Consumer for this topic.
Help would be appreciated.
---
Thank You…
Mick Knutson, President
BASE Logic, Inc.
Enterprise Architecture, Design, Mentoring & Agile Consulting
p. (866) BLiNC-411: (254-6241-1)
f. (415) 685-4233
Website: http://baselogic.com
Linked IN: http://linkedin.com/in/mickknutson
Vacation Rental: http://tahoe.baselogic.com
---