You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Jean-Baptiste Onofré <jb...@nanthrax.net> on 2011/06/15 14:54:47 UTC
Re: SEDA behavior
Hi,
SEDA is asynchronous, and the messages are exchanged on a BlockingQueue.
To avoid overhead, you can use the size attribute to limit the number of
messages to handle:
from("seda:workpipie?concurrentConsumers=25&size=1000")
Regards
JB
On 06/15/2011 02:54 PM, Frederic Tuttle wrote:
> I have been using seda queues to multithread some processing such as:
>
> from("seda:workpipe?concurrentConsumers=25").process(new
> WorkProcessor());
>
> If I leave the queue unbounded, I will run out of heap space if my load is
> too high and my threads are too few.
> If I limit the queue size, the queue fills up and message delivery fails.
>
> Should I expect some sort of flow control because seda is implemented as a
> blocking queue ? or is there total decoupling from the provider ?
> What are ways of dealing with this issue other than tweaking the settings ?
>
>
> Thanks for your help.
>
> -FT
>
Re: SEDA behavior
Posted by Frederic Tuttle <fj...@gmail.com>.
Right. When I try ?size=1000, I get ... IllegalStateException: Queue full
...
Just want to know if there is an approach to dealing with this.
On Wed, Jun 15, 2011 at 8:54 AM, Jean-Baptiste Onofré <jb...@nanthrax.net>wrote:
> Hi,
>
> SEDA is asynchronous, and the messages are exchanged on a BlockingQueue.
>
> To avoid overhead, you can use the size attribute to limit the number of
> messages to handle:
>
> from("seda:workpipie?concurrentConsumers=25&size=1000")
>
> Regards
> JB
>
>
> On 06/15/2011 02:54 PM, Frederic Tuttle wrote:
>
>> I have been using seda queues to multithread some processing such as:
>>
>> from("seda:workpipe?concurrentConsumers=25").process(new
>> WorkProcessor());
>>
>> If I leave the queue unbounded, I will run out of heap space if my load is
>> too high and my threads are too few.
>> If I limit the queue size, the queue fills up and message delivery fails.
>>
>> Should I expect some sort of flow control because seda is implemented as a
>> blocking queue ? or is there total decoupling from the provider ?
>> What are ways of dealing with this issue other than tweaking the settings
>> ?
>>
>>
>> Thanks for your help.
>>
>> -FT
>>
>>
Re: SEDA behavior
Posted by Frederic Tuttle <fj...@gmail.com>.
Thanks. That is what I wanted to know. I will give ActiveMQ another chance.
I was running into some bugs in the latest version, but since then I found
some workarounds to try.
-FT
On Wed, Jun 15, 2011 at 9:12 AM, Claus Ibsen <cl...@gmail.com> wrote:
> There is no flow control and whatnot, SEDA is a simple internal memory
> queue.
>
> If you want all that other stuff then look for ActiveMQ as it got all
> those bells and whistles.
>
>
> On Wed, Jun 15, 2011 at 3:10 PM, Frederic Tuttle <ft...@oratu.net>
> wrote:
> > Right. When I try ?size=1000, I get ... IllegalStateException: Queue full
> > ...
> > Just want to know if there is an approach to dealing with this.
> >
> > -FT
> >
> > On Wed, Jun 15, 2011 at 8:54 AM, Jean-Baptiste Onofré <jb@nanthrax.net
> >wrote:
> >
> >> Hi,
> >>
> >> SEDA is asynchronous, and the messages are exchanged on a BlockingQueue.
> >>
> >> To avoid overhead, you can use the size attribute to limit the number of
> >> messages to handle:
> >>
> >> from("seda:workpipie?concurrentConsumers=25&size=1000")
> >>
> >> Regards
> >> JB
> >>
> >>
> >> On 06/15/2011 02:54 PM, Frederic Tuttle wrote:
> >>
> >>> I have been using seda queues to multithread some processing such as:
> >>>
> >>> from("seda:workpipe?concurrentConsumers=25").process(new
> >>> WorkProcessor());
> >>>
> >>> If I leave the queue unbounded, I will run out of heap space if my load
> is
> >>> too high and my threads are too few.
> >>> If I limit the queue size, the queue fills up and message delivery
> fails.
> >>>
> >>> Should I expect some sort of flow control because seda is implemented
> as a
> >>> blocking queue ? or is there total decoupling from the provider ?
> >>> What are ways of dealing with this issue other than tweaking the
> settings
> >>> ?
> >>>
> >>>
> >>> Thanks for your help.
> >>>
> >>> -FT
> >>>
> >>>
> >
>
>
>
> --
> Claus Ibsen
> -----------------
> FuseSource
> Email: cibsen@fusesource.com
> Web: http://fusesource.com
> Twitter: davsclaus, fusenews
> Blog: http://davsclaus.blogspot.com/
> Author of Camel in Action: http://www.manning.com/ibsen/
>
Re: SEDA behavior
Posted by Claus Ibsen <cl...@gmail.com>.
There is no flow control and whatnot, SEDA is a simple internal memory queue.
If you want all that other stuff then look for ActiveMQ as it got all
those bells and whistles.
On Wed, Jun 15, 2011 at 3:10 PM, Frederic Tuttle <ft...@oratu.net> wrote:
> Right. When I try ?size=1000, I get ... IllegalStateException: Queue full
> ...
> Just want to know if there is an approach to dealing with this.
>
> -FT
>
> On Wed, Jun 15, 2011 at 8:54 AM, Jean-Baptiste Onofré <jb...@nanthrax.net>wrote:
>
>> Hi,
>>
>> SEDA is asynchronous, and the messages are exchanged on a BlockingQueue.
>>
>> To avoid overhead, you can use the size attribute to limit the number of
>> messages to handle:
>>
>> from("seda:workpipie?concurrentConsumers=25&size=1000")
>>
>> Regards
>> JB
>>
>>
>> On 06/15/2011 02:54 PM, Frederic Tuttle wrote:
>>
>>> I have been using seda queues to multithread some processing such as:
>>>
>>> from("seda:workpipe?concurrentConsumers=25").process(new
>>> WorkProcessor());
>>>
>>> If I leave the queue unbounded, I will run out of heap space if my load is
>>> too high and my threads are too few.
>>> If I limit the queue size, the queue fills up and message delivery fails.
>>>
>>> Should I expect some sort of flow control because seda is implemented as a
>>> blocking queue ? or is there total decoupling from the provider ?
>>> What are ways of dealing with this issue other than tweaking the settings
>>> ?
>>>
>>>
>>> Thanks for your help.
>>>
>>> -FT
>>>
>>>
>
--
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/
Re: SEDA behavior
Posted by Frederic Tuttle <ft...@oratu.net>.
Right. When I try ?size=1000, I get ... IllegalStateException: Queue full
...
Just want to know if there is an approach to dealing with this.
-FT
On Wed, Jun 15, 2011 at 8:54 AM, Jean-Baptiste Onofré <jb...@nanthrax.net>wrote:
> Hi,
>
> SEDA is asynchronous, and the messages are exchanged on a BlockingQueue.
>
> To avoid overhead, you can use the size attribute to limit the number of
> messages to handle:
>
> from("seda:workpipie?concurrentConsumers=25&size=1000")
>
> Regards
> JB
>
>
> On 06/15/2011 02:54 PM, Frederic Tuttle wrote:
>
>> I have been using seda queues to multithread some processing such as:
>>
>> from("seda:workpipe?concurrentConsumers=25").process(new
>> WorkProcessor());
>>
>> If I leave the queue unbounded, I will run out of heap space if my load is
>> too high and my threads are too few.
>> If I limit the queue size, the queue fills up and message delivery fails.
>>
>> Should I expect some sort of flow control because seda is implemented as a
>> blocking queue ? or is there total decoupling from the provider ?
>> What are ways of dealing with this issue other than tweaking the settings
>> ?
>>
>>
>> Thanks for your help.
>>
>> -FT
>>
>>