You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Debraj Manna <su...@gmail.com> on 2016/07/03 10:06:10 UTC
Default ThreadPool Role in camel 2.16.1
Can some please explain me how does threadPool works in camel?
Let's say I have a default threadPool defined in camelContext:-
<threadPoolProfile id="defaultThreadPoolProfile"
defaultProfile="true" poolSize="50" maxPoolSize="500" maxQueueSize="5000"
rejectedPolicy="CallerRuns" />
Also let's say I have some routes defined as below:-
from("jetty:http://localhost:8888/orchestratorservice").process(processor);
from("direct:setStatusToReadyToShip").to("bean:orderHelper?method=setStatusToReadyToShip")
Will the threads in jetty be limited by the size of
defaultThreadPoolProfile?
Also let's say I create one more threadPool of size greater than the pool
size of defaultThreadPoolProfile in the orderBeans, how will this
threadPool behave?
If I don't define any defaultThreadPool in camelContext what default values
it take?
Re: Default ThreadPool Role in camel 2.16.1
Posted by Claus Ibsen <cl...@gmail.com>.
On Sun, Jul 3, 2016 at 12:35 PM, Debraj Manna <su...@gmail.com> wrote:
> Thanks for the pointers.
>
> If I have a route of the form
>
> from("direct:setStatusToReadyToShip").to("bean:orderHelper?method=setStatusToReadyToShip")
>
> Then the route from from(...).to(...) will be effected by
> defaultThreadProfile?
>
No the direct component uses the thread that sends the message to the
endpoint. Likewise does bean. There is no thread pool involved here.
> On Jul 3, 2016 3:39 PM, "Claus Ibsen" <cl...@gmail.com> wrote:
>
>> Hi
>>
>>
>> No Jetty has its own thread pooling, and you need to configure it
>> using options on the jetty component
>> http://camel.apache.org/jetty
>>
>> The thread pools in Camel is when you configure an explicit thread
>> pool on a component that is of ExecutorService type. And also for all
>> the EIPs that has thread pools.
>>
>>
>> You can find some details at
>> http://camel.apache.org/threading-model.html
>>
>> And I suggest if you want deeper knowledge then pickup a copy of the
>> Camel in Action book.
>>
>> On Sun, Jul 3, 2016 at 12:06 PM, Debraj Manna <su...@gmail.com>
>> wrote:
>> > Can some please explain me how does threadPool works in camel?
>> >
>> > Let's say I have a default threadPool defined in camelContext:-
>> >
>> > <threadPoolProfile id="defaultThreadPoolProfile"
>> >
>> > defaultProfile="true" poolSize="50" maxPoolSize="500" maxQueueSize="5000"
>> >
>> > rejectedPolicy="CallerRuns" />
>> >
>> > Also let's say I have some routes defined as below:-
>> >
>> > from("jetty:http://localhost:8888/orchestratorservice
>> ").process(processor);
>> >
>> >
>> from("direct:setStatusToReadyToShip").to("bean:orderHelper?method=setStatusToReadyToShip")
>> >
>> > Will the threads in jetty be limited by the size of
>> > defaultThreadPoolProfile?
>> >
>> > Also let's say I create one more threadPool of size greater than the pool
>> > size of defaultThreadPoolProfile in the orderBeans, how will this
>> > threadPool behave?
>> >
>> > If I don't define any defaultThreadPool in camelContext what default
>> values
>> > it take?
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> http://davsclaus.com @davsclaus
>> Camel in Action 2: https://www.manning.com/ibsen2
>>
--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Re: Default ThreadPool Role in camel 2.16.1
Posted by Debraj Manna <su...@gmail.com>.
Thanks for the pointers.
If I have a route of the form
from("direct:setStatusToReadyToShip").to("bean:orderHelper?method=setStatusToReadyToShip")
Then the route from from(...).to(...) will be effected by
defaultThreadProfile?
On Jul 3, 2016 3:39 PM, "Claus Ibsen" <cl...@gmail.com> wrote:
> Hi
>
>
> No Jetty has its own thread pooling, and you need to configure it
> using options on the jetty component
> http://camel.apache.org/jetty
>
> The thread pools in Camel is when you configure an explicit thread
> pool on a component that is of ExecutorService type. And also for all
> the EIPs that has thread pools.
>
>
> You can find some details at
> http://camel.apache.org/threading-model.html
>
> And I suggest if you want deeper knowledge then pickup a copy of the
> Camel in Action book.
>
> On Sun, Jul 3, 2016 at 12:06 PM, Debraj Manna <su...@gmail.com>
> wrote:
> > Can some please explain me how does threadPool works in camel?
> >
> > Let's say I have a default threadPool defined in camelContext:-
> >
> > <threadPoolProfile id="defaultThreadPoolProfile"
> >
> > defaultProfile="true" poolSize="50" maxPoolSize="500" maxQueueSize="5000"
> >
> > rejectedPolicy="CallerRuns" />
> >
> > Also let's say I have some routes defined as below:-
> >
> > from("jetty:http://localhost:8888/orchestratorservice
> ").process(processor);
> >
> >
> from("direct:setStatusToReadyToShip").to("bean:orderHelper?method=setStatusToReadyToShip")
> >
> > Will the threads in jetty be limited by the size of
> > defaultThreadPoolProfile?
> >
> > Also let's say I create one more threadPool of size greater than the pool
> > size of defaultThreadPoolProfile in the orderBeans, how will this
> > threadPool behave?
> >
> > If I don't define any defaultThreadPool in camelContext what default
> values
> > it take?
>
>
>
> --
> Claus Ibsen
> -----------------
> http://davsclaus.com @davsclaus
> Camel in Action 2: https://www.manning.com/ibsen2
>
Re: Default ThreadPool Role in camel 2.16.1
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
No Jetty has its own thread pooling, and you need to configure it
using options on the jetty component
http://camel.apache.org/jetty
The thread pools in Camel is when you configure an explicit thread
pool on a component that is of ExecutorService type. And also for all
the EIPs that has thread pools.
You can find some details at
http://camel.apache.org/threading-model.html
And I suggest if you want deeper knowledge then pickup a copy of the
Camel in Action book.
On Sun, Jul 3, 2016 at 12:06 PM, Debraj Manna <su...@gmail.com> wrote:
> Can some please explain me how does threadPool works in camel?
>
> Let's say I have a default threadPool defined in camelContext:-
>
> <threadPoolProfile id="defaultThreadPoolProfile"
>
> defaultProfile="true" poolSize="50" maxPoolSize="500" maxQueueSize="5000"
>
> rejectedPolicy="CallerRuns" />
>
> Also let's say I have some routes defined as below:-
>
> from("jetty:http://localhost:8888/orchestratorservice").process(processor);
>
> from("direct:setStatusToReadyToShip").to("bean:orderHelper?method=setStatusToReadyToShip")
>
> Will the threads in jetty be limited by the size of
> defaultThreadPoolProfile?
>
> Also let's say I create one more threadPool of size greater than the pool
> size of defaultThreadPoolProfile in the orderBeans, how will this
> threadPool behave?
>
> If I don't define any defaultThreadPool in camelContext what default values
> it take?
--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2