camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Flavio Magacho - M4U <flavio.maga...@m4u.com.br>
Subject RE: Load test on camel-netty
Date Tue, 20 Aug 2013 18:05:05 GMT
Claus, 
Thanks for your answer, we have done that and nothing changes.


Flavio Magacho
Gerente de Desenvolvimento
Diretoria de Tecnologia da Informação
  M4U
+55 (21) 2546-4050 ▪ Ramal: 4082
+55 (21) 8889-1572
 Antes de imprimir, pense em sua responsabilidade e compromisso com o Meio Ambiente.
O conteúdo desta mensagem é confidencial e pode ser privilegiado. É vedada a sua cópia
ou divulgação.
The contents of this message are confidential and may be privileged. Copying or disclosing
is prohibited.


-----Original Message-----
From: Claus Ibsen [mailto:claus.ibsen@gmail.com] 
Sent: terça-feira, 20 de agosto de 2013 12:00
To: users@camel.apache.org
Subject: Re: Load test on camel-netty

I would suggest to remove the 100 thread pool sizes as the out of the box settings from Netty
is better. Netty is asynchronous and it creates thread pools based on the number of CPU cores
etc.

Netty creates the threads up-front so having 100+ threads take up some unnecessary memory.


On Tue, Aug 13, 2013 at 5:02 PM, Flavio Magacho - M4U < flavio.magacho@m4u.com.br> wrote:

> Hi, ****
>
> I'm expecting some problems while running a load test on camel-netty
> component.****
>
> ** **
>
> This is the route configuration:****
>
> <route id="rtRead">****
>
>                 <from
> uri="netty:tcp://pos-tcp-server.host:9000?decoder=#myDecoder&amp;encod
> er=#myEncoder&amp;sync=true&amp;reuseAddress=true&amp;synchronous=fals
> e&amp;workerCount=100&amp;maximumPoolSize=100”/>
> ****
>
>                 <log message="Lendo ${body}" />****
>
>                 <to uri="ejb:local/GatewayBean?method=process" />****
>
> </route>****
>
> ** **
>
> After some test cycles, we receive some exceptions like this:****
>
> 2013-08-13 11:25:33,398 WARNING
> [org.jboss.netty.channel.DefaultChannelPipeline] [New I/O  worker #32] 
> An exception was thrown by a user handler while handling an exception 
> event
> ([id: 0x8c7d41bd, /10.10.0.28:53469 => /10.11.234.38:9000] EXCEPTION:
> java.lang.OutOfMemoryError: unable to create new native thread)****
>
> java.lang.OutOfMemoryError: unable to create new native thread****
>
>         at java.lang.Thread.start0(Native Method)****
>
>         at java.lang.Thread.start(Thread.java:640)****
>
>         at
> java.util.concurrent.ThreadPoolExecutor.addIfUnderCorePoolSize(ThreadP
> oolExecutor.java:703)
> ****
>
>         at
> java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.jav
> a:652)
> ****
>
>         at
> org.jboss.netty.handler.execution.MemoryAwareThreadPoolExecutor.doUnor
> deredExecute(MemoryAwareThreadPoolExecutor.java:452)
> ****
>
>         at
> org.jboss.netty.handler.execution.OrderedMemoryAwareThreadPoolExecutor
> $ChildExecutor.execute(OrderedMemoryAwareThreadPoolExecutor.java:292)
> ****
>
>         at
> org.jboss.netty.handler.execution.OrderedMemoryAwareThreadPoolExecutor
> .doExecute(OrderedMemoryAwareThreadPoolExecutor.java:242)
> ****
>
>         at
> org.jboss.netty.handler.execution.MemoryAwareThreadPoolExecutor.execut
> e(MemoryAwareThreadPoolExecutor.java:437)
> ****
>
>         at
> org.jboss.netty.handler.execution.ExecutionHandler.handleUpstream(Exec
> utionHandler.java:172)
> ****
>
>         at
> org.jboss.netty.channel.Channels.fireExceptionCaught(Channels.java:533
> )***
> *
>
>         at 
> org.jboss.netty.channel.Channels$7.run(Channels.java:507)****
>
>         at
> org.jboss.netty.channel.socket.ChannelRunnableWrapper.run(ChannelRunna
> bleWrapper.java:41)
> ****
>
>         at
> org.jboss.netty.channel.socket.nio.AbstractNioWorker.processEventQueue
> (AbstractNioWorker.java:453)
> ****
>
>         at
> org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWo
> rker.java:330)
> ****
>
>         at
> org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:35)***
> *
>
>         at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecu
> tor.java:886)
> ****
>
>         at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.
> java:908)
> ****
>
>         at java.lang.Thread.run(Thread.java:662)****
>
> ** **
>
> ** **
>
> It sounds strange, our test case has only 5 simultaneous opened
> connections.****
>
> For me we are heaving some leak of threads or we are having some 
> problems to close the SocketChannel correctly.****
>
> ** **
>
> Thanks,****
>
> *Flavio Magacho*
>
> *Gerente de Desenvolvimento*
>
> Diretoria de Tecnologia da Informação****
>
> [image: cid:image001.gif@01CB90D9.07FBDA40]  *M4U*
> +55 (21) 2546-4050 ▪ Ramal: 4082****
>
> +55 (21) 8889-1572****
>
> *þ** *Antes de imprimir, pense em sua responsabilidade e compromisso 
> com o Meio Ambiente.****
>
> *O conteúdo desta mensagem é confidencial e pode ser privilegiado. **É 
> vedada a sua cópia ou divulgação.*
>
> *The contents of this message are confidential and may be privileged.
> Copying or disclosing is prohibited.*****
>
> ** **
>



--
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
Mime
View raw message