You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by samslara <sa...@yahoo.com> on 2014/04/10 00:37:06 UTC

inter-bundle camel routing

Hi,
  I have a question about how to route messages between OSGi bundles within
the same container.  If I have two bundles, B1 and B2, which have their own
camel routes and I want them to send messages to each other, say from B1 to
B2, what's the best practice approach on how to do this?

So for example I have B1 having:
<from uri="jetty:http://0.0.0.0:8080/myUri">
<to uri="direct:otherRoute"/>
</from>

and B2 having:
<from uri="direct:otherRoute">
<process ref="someBean"/>
</from>

This will only work if both routes are within the same camel context, but if
I wanted something comparable where the two routes sit on different bundles
within the same container.

I've seen similar postings about something similar over the years but I'm
asking again in case there's something newer that is recommended for
camel/osgi.



--
View this message in context: http://camel.465427.n5.nabble.com/inter-bundle-camel-routing-tp5750021.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: inter-bundle camel routing

Posted by samslara <sa...@yahoo.com>.
Thanks for the information.  One other question, though, what about nmr? 
What are your thoughts on using NMR for interbundle routing?



--
View this message in context: http://camel.465427.n5.nabble.com/inter-bundle-camel-routing-tp5750021p5750061.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: inter-bundle camel routing

Posted by pradeep <pr...@gmail.com>.
Hi,

Yes, you can use camel direct-vm instead of direct component and it is for
synchronous behavior. For async communication you can use camel-vm
component. Refer this documentation for more info:
camel-VM: http://camel.apache.org/vm.html
Camel-Direct-vm: https://camel.apache.org/direct-vm.html



--
View this message in context: http://camel.465427.n5.nabble.com/inter-bundle-camel-routing-tp5750021p5750024.html
Sent from the Camel - Users mailing list archive at Nabble.com.