The direct-vm components is based on the direct component and it's a synchronous invocation. The vm component is based on the seda component and it's an asynchronous invocation.
We may should update or WIKI page about using this components in OSGI world. I do not have any experience using WAR deployments and OSGI bundles together... Another option is to register a service in the OSGI registry which can be looked up and used by the other one. Best, Christian On Tue, Mar 26, 2013 at 10:50 AM, ddewaele <[email protected]> wrote: > Hi Christian, > > I was a bit confused by the documentation (does the direct-vm contain a > copy/paste error ? It basically says the same as on the vm page). Both > "support communication across CamelContext instances" but yet they differ ? > It's also not clear that both can be used for inter OSGI bundle > communication. > > *VM* > VM supports communication across CamelContext instances - so you can use > this mechanism to communicate across web applications (provided that > camel-core.jar is on the system/boot classpath). > > *Direct-VM* > This component differs from the Direct component in that Direct-VM supports > communication across CamelContext instances - so you can use this mechanism > to communicate across web applications (provided that camel-core.jar is on > the system/boot classpath). > > I used the direct-vm and it does work accross bundles. However, in our case > we have 1 Camel route defined in a OSGI bundle (bootstrapped using spring > using an OSGI blueprint extender), while another Camel route is defined in > a > WAR file (the osgi frameworks wraps the war file in an OSGI bundle). > > I noticed that the route from the WAR file can not send messages using > direct-vm to a route in a bundle. > A route from a bundle can send a message to a route in another bundle. > > So I guess I have 2 options : > > 1. Move the camel route from the WAR into an actual OSGI bundle, put > everything in the same EBA and use vm or direct-vm > 2. Keep the 2 EBAs seperate (isolated) and integrate them using JMS. > > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/Integrating-2-deployable-units-containing-camel-routes-tp5729827p5729841.html > Sent from the Camel - Users mailing list archive at Nabble.com. >
