You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by snowbug <la...@gmail.com> on 2009/08/13 22:03:22 UTC

Accessing CamelContext from different applications

I have been reading the documents and search the forum and web but didn't
find the answer yet so I decide to post a message of my own to seek for
helps :)

What I see so far is all running Camel in a single application where the
CamelContext can be retrieved easily with many different ways. My questions
are:

1. How do I access an existing CamelContext at server from a client
application that is running in a different JVM / machine? Or is it doable?

2. How to interact with Camel from applications that is developed using
other languages, such as .NET?

Basically, what I want to figure out is, after creating a server that uses
Camel, what's the best way to participant in this message bus from
applications that are distributed in different machines?

Thanks,

Alan
-- 
View this message in context: http://www.nabble.com/Accessing-CamelContext-from-different-applications-tp24957829p24957829.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Re: Accessing CamelContext from different applications

Posted by Willem Jiang <wi...@gmail.com>.
snowbug wrote:
> 
> 
> willem.jiang wrote:
>> Hi,
>>
>> Yes , you assumption is correct.
>> If you want to directly talk to camel context in the same JVM, you could 
>> choice direct,  seda component. But if you want to do that across the 
>> JVMs, you have to other components :)
>>
>> Willem
>>
> 
> Thank you for the confirmation. I am quite new to Camel so please allow me
> to get more clarification on your "other components" comments. My
> understanding to that is people would need to create JMS (or HTTP, or other)
> component in the Camel app to allow other apps to send messages to it, and
> the same time create application specific components in the Camel app to
> send messages from the Camel app to other apps?
> 
> Thanks for you help,
> 
> Alan
> 

Yes, you absolutely right :)

Willem

Re: Accessing CamelContext from different applications

Posted by snowbug <la...@gmail.com>.


willem.jiang wrote:
> 
> Hi,
> 
> Yes , you assumption is correct.
> If you want to directly talk to camel context in the same JVM, you could 
> choice direct,  seda component. But if you want to do that across the 
> JVMs, you have to other components :)
> 
> Willem
> 

Thank you for the confirmation. I am quite new to Camel so please allow me
to get more clarification on your "other components" comments. My
understanding to that is people would need to create JMS (or HTTP, or other)
component in the Camel app to allow other apps to send messages to it, and
the same time create application specific components in the Camel app to
send messages from the Camel app to other apps?

Thanks for you help,

Alan

-- 
View this message in context: http://www.nabble.com/Accessing-CamelContext-from-different-applications-tp24957829p25018259.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Re: Accessing CamelContext from different applications

Posted by Willem Jiang <wi...@gmail.com>.
Hi,

Yes , you assumption is correct.
If you want to directly talk to camel context in the same JVM, you could 
choice direct,  seda component. But if you want to do that across the 
JVMs, you have to other components :)

Willem
snowbug wrote:
> Thank you for the reply.
> 
> Your assumptions are all correct. Basically, I have several applications
> that need to interact with the Camel application, and I was thinking to have
> camel route messages directly to them and have these applications drop
> messages into the camel context directly. But with you response, and my own
> research so far, looks like these applications won't be able to talk to
> camel directly. I'll have to define service endpoints within the camel
> application in order to interact with the other applications. - Is this
> correct assumption?
> 
> 
> 
> willem.jiang wrote:
>> Hi,
>> Can I know why you need to access the CamelContext from different JVM ?
>>
>> Camel has lots of components can help your application talk across the 
>> JVM, such as camel-jms , camel-mina, camel-cxf, camel-http etc.
>>
>> If you just want to access the endpoint of upper components from 
>> different JVM, that is doable.
>>
>> But, if you just want to access the CamelContext, read the routes rule, 
>> or do some manage things , you may need to consider the JMX or the camel 
>> web console.
>>
>> After rereading your questions , I think you just want to access the 
>> service which is exported by camel. If you want to use ,net client to 
>> talk with the service, I suggest you use the camel-cxf component[1] 
>> which leverage the CXF[2] to implements a WebServices stack, and we did 
>> some inter-operation tests between the CXF and .net years ago, they look 
>> great.
>>
>> [1]http://camel.apache.org/cxf.html
>> [2]http://cwiki.apache.org/CXF
>>
>> Willem
>>
>> snowbug wrote:
>>> I have been reading the documents and search the forum and web but didn't
>>> find the answer yet so I decide to post a message of my own to seek for
>>> helps :)
>>>
>>> What I see so far is all running Camel in a single application where the
>>> CamelContext can be retrieved easily with many different ways. My
>>> questions
>>> are:
>>>
>>> 1. How do I access an existing CamelContext at server from a client
>>> application that is running in a different JVM / machine? Or is it
>>> doable?
>>>
>>> 2. How to interact with Camel from applications that is developed using
>>> other languages, such as .NET?
>>>
>>> Basically, what I want to figure out is, after creating a server that
>>> uses
>>> Camel, what's the best way to participant in this message bus from
>>> applications that are distributed in different machines?
>>>
>>> Thanks,
>>>
>>> Alan
>>
>>
> 


Re: Accessing CamelContext from different applications

Posted by snowbug <la...@gmail.com>.
Thank you for the reply.

Your assumptions are all correct. Basically, I have several applications
that need to interact with the Camel application, and I was thinking to have
camel route messages directly to them and have these applications drop
messages into the camel context directly. But with you response, and my own
research so far, looks like these applications won't be able to talk to
camel directly. I'll have to define service endpoints within the camel
application in order to interact with the other applications. - Is this
correct assumption?



willem.jiang wrote:
> 
> Hi,
> Can I know why you need to access the CamelContext from different JVM ?
> 
> Camel has lots of components can help your application talk across the 
> JVM, such as camel-jms , camel-mina, camel-cxf, camel-http etc.
> 
> If you just want to access the endpoint of upper components from 
> different JVM, that is doable.
> 
> But, if you just want to access the CamelContext, read the routes rule, 
> or do some manage things , you may need to consider the JMX or the camel 
> web console.
> 
> After rereading your questions , I think you just want to access the 
> service which is exported by camel. If you want to use ,net client to 
> talk with the service, I suggest you use the camel-cxf component[1] 
> which leverage the CXF[2] to implements a WebServices stack, and we did 
> some inter-operation tests between the CXF and .net years ago, they look 
> great.
> 
> [1]http://camel.apache.org/cxf.html
> [2]http://cwiki.apache.org/CXF
> 
> Willem
> 
> snowbug wrote:
>> I have been reading the documents and search the forum and web but didn't
>> find the answer yet so I decide to post a message of my own to seek for
>> helps :)
>> 
>> What I see so far is all running Camel in a single application where the
>> CamelContext can be retrieved easily with many different ways. My
>> questions
>> are:
>> 
>> 1. How do I access an existing CamelContext at server from a client
>> application that is running in a different JVM / machine? Or is it
>> doable?
>> 
>> 2. How to interact with Camel from applications that is developed using
>> other languages, such as .NET?
>> 
>> Basically, what I want to figure out is, after creating a server that
>> uses
>> Camel, what's the best way to participant in this message bus from
>> applications that are distributed in different machines?
>> 
>> Thanks,
>> 
>> Alan
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Accessing-CamelContext-from-different-applications-tp24957829p25013084.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Re: Accessing CamelContext from different applications

Posted by Willem Jiang <wi...@gmail.com>.
Hi,
Can I know why you need to access the CamelContext from different JVM ?

Camel has lots of components can help your application talk across the 
JVM, such as camel-jms , camel-mina, camel-cxf, camel-http etc.

If you just want to access the endpoint of upper components from 
different JVM, that is doable.

But, if you just want to access the CamelContext, read the routes rule, 
or do some manage things , you may need to consider the JMX or the camel 
web console.

After rereading your questions , I think you just want to access the 
service which is exported by camel. If you want to use ,net client to 
talk with the service, I suggest you use the camel-cxf component[1] 
which leverage the CXF[2] to implements a WebServices stack, and we did 
some inter-operation tests between the CXF and .net years ago, they look 
great.

[1]http://camel.apache.org/cxf.html
[2]http://cwiki.apache.org/CXF

Willem

snowbug wrote:
> I have been reading the documents and search the forum and web but didn't
> find the answer yet so I decide to post a message of my own to seek for
> helps :)
> 
> What I see so far is all running Camel in a single application where the
> CamelContext can be retrieved easily with many different ways. My questions
> are:
> 
> 1. How do I access an existing CamelContext at server from a client
> application that is running in a different JVM / machine? Or is it doable?
> 
> 2. How to interact with Camel from applications that is developed using
> other languages, such as .NET?
> 
> Basically, what I want to figure out is, after creating a server that uses
> Camel, what's the best way to participant in this message bus from
> applications that are distributed in different machines?
> 
> Thanks,
> 
> Alan