I worked thru the URI and the namespace issues and got it to work. Now the
static recipient list pattern under servicemix-camel component works.
basically I learnt is the "from uri" is mapped internally to a different
Endpoint address (jconsole shows this) than the usual consumer/provider
endpoints that are not camel endpoints. I am not sure if this is a typo on
the webpage or my hack to make it work :-) or a bug in servicemix-camel but
it worked.
========================= CAMEL STATIC RECIPIENT LIST ============
<from
uri="jbi:endpoint:http://consumers.pictor.com//CamelStaticRecipientListService/CamelStaticRecipientListEndpoint"/>
<to
uri="jbi:service:http://services.pictor.com//RequestProcessProvider"/>
<to uri="jbi:service:http://services.pictor.com//TraceBeanService"/>
==============================================================
the slashes at the end of pictor.com made the diffirence. If I had a single
slash, the endpoint URI mapped to
"http:__consumers.pictor.com}CamelStaticRecipientListService...". I could
see the endpoint URI in jconsole. when the jms:endpoint was forwarding the
message to this service it was trying (i am guessing at this point on how
the NMR maps the targetService internally) to send locate the
"http://consumers.pictor.com/" which is
http:__consumers.pictor.com_}CamelStaticRecipientListService. So, I simply
hacked my way through by adding a double slash at the end of the pictor.com
to generate
"http:__consumers.pictor.com_}CamelStaticRecipientListService....
etc.(verified in jconsole) and that worked. jms:endpoint was able to send to
the correct Camel endpoint.
well, is this my hack or a bug in NMR or works as designed?
thanx
-ram
rmunjuluri wrote:
It is the IONA version of FUSE - servicemix-eip-3.3.1.0-fuse
thanx
-ram
James.Strachan wrote:
Which version of ServiceMix are you using?
2008/5/19 rmunjuluri <rmunjuluri@yahoo.com>:
Thank you very much Roman. That worked great. I have two new issues:
1. The simple message forward works for about 4 messages and then SMX
seems
to block the forwarding the 5 message onwards to the target service.
Have
you seen this behaviour? Is there any configuration issue with this?
2. Also I tried was to make the camel context a static recipientList
router
to send the message to more than one target service (queues, oneway
senders). Every time, the message is sent to the first target only and
is
not forwarded to the next target on the list. Is this a bug in the
statis
recipient list pattern implementation in camel?
=======================================================
<camelContext id="staticRecipientList"
xmlns="http://activemq.apache.org/camel/schema/spring">
<route>
<from
uri="jbi:service:http://www.pictorsolutions.com/ServiceConsumers/CamelRoutingService"/>
<to
uri="jbi:service:http://www.pictorsolutions.com/ServiceProviders/RequestProcessProvider"/>
<to
uri="jbi:service:http://www.pictorsolutions.com/ServiceProviders/TraceService"/>
</route>
</camelContext>
=======================================================
thanx in advance again
-ram
RomKal wrote:
2008/5/16 rmunjuluri <rmunjuluri@yahoo.com>:
I have a simple jms:endpoint node configurted to receive messages on a
"my.queue" in Servicemix. It currently receives messages and sends to
a
TraceBean configured as a targetservice. Now I would like to replace
the
TraceBean and apply the Camel routing to the incoming message to send
the
message to an other jms:endpoint (provider) to a queue defined in
JBoss.
This seems like a simple message forwarding scenario, but, I cant seem
to
find docs on how to tie the jms:consumer/endpoint to camel. Is there a
way
to specify the targetService of the Jms:consumer/endpoint as the
camel-context id? or will Camel-context pick up the message and
forward
as
per routing defined in the context?
Here you have some documentation:
http://activemq.apache.org/camel/jbi.htmlMaybe it is not very clearly stated at the wiki page, but when you
write
from("jbi:endpoint:http://foo.bar.org/MyService/MyEndpoint")
you automatically expose the endpoint to the bus where service qname
is {http://foo.bar.org}MyService and endpoint name is MyEndpoint.
All you have to do is to send messages from jms:endpoint to this JBI
endpoint (the same way as you send messages to EIP endpoints) and it
will pick it up the same way as it picks any other message messages.
Sending works in the same way: you use
to("jbi:endpoint:http://foo.bar.org/MyService/MyEndpoint") to send
messages to JBI endpoint deployed to the bus. It could be jms:endpoint
or anything else.
I noticed that people are used to somehow 'declaring' endpoints in
SMX. In camel it is enough to simply start a flow from a jbi endpoint
and camel will create it automatically.
Roman
--
View this message in context:
http://www.nabble.com/camel-context-node-as-a-targetservice-for-jms%3Aendpoint---tp17275939s22882p17315169.htmlSent from the Camel - Users mailing list archive at Nabble.com.
--
James
-------
http://macstrac.blogspot.com/Open Source Integration
http://open.iona.com--
View this message in context:
http://www.nabble.com/camel-context-node-as-a-targetservice-for-jms%3Aendpoint---tp17275939s22882p17337794.htmlSent from the Camel - Users mailing list archive at Nabble.com.