You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by kal2 <ki...@gmail.com> on 2015/10/14 14:48:32 UTC

FutureResponse bottleneck when using more than 10 threads

The FutureResponse becomes the bottleneck when we use more than 10 threads to
send msgs out through connections.. We need to support large number of
threads on producer side and they also send jms msgs, is there anything to
set that can help with this limitation.

pool-69-thread-4" - Thread t@734
   java.lang.Thread.State: WAITING
            at sun.misc.Unsafe.park(Native Method)
            - parking to wait for <4bfa2856> (a
java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
            at
java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
            at
java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2043)
            at
java.util.concurrent.ArrayBlockingQueue.take(ArrayBlockingQueue.java:374)
            at
org.apache.activemq.transport.FutureResponse.getResult(FutureResponse.java:40)






--
View this message in context: http://activemq.2283324.n4.nabble.com/FutureResponse-bottleneck-when-using-more-than-10-threads-tp4702945.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: FutureResponse bottleneck when using more than 10 threads

Posted by Tim Bain <tb...@alumni.duke.edu>.
I haven't used it, but isn't this exactly what NIO is supposed to fix?  Try
having your clients connect via the nio transport and see if things improve.

Tim
On Oct 19, 2015 10:34 AM, "kal2" <ki...@gmail.com> wrote:

> I tested with 1 connection with 10 threads and that was running fine.
> 1 connection with 15 or more threads seems to be an issue with reading from
> TCP and servicing all the threads??
>
> In our test we tried with 6 connections and we were able to just use 25
> threads.  For our app we needs to service 100's of threads.  For now we are
> use semaphore to limit number of threads calling send api but the latency
> is
> an issue as many threads are trying to wait for few connections (10-25
> depending on # of connections).
>
>
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/FutureResponse-bottleneck-when-using-more-than-10-threads-tp4702945p4703119.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>

Re: FutureResponse bottleneck when using more than 10 threads

Posted by kal2 <ki...@gmail.com>.
I tested with 1 connection with 10 threads and that was running fine.
1 connection with 15 or more threads seems to be an issue with reading from
TCP and servicing all the threads??

In our test we tried with 6 connections and we were able to just use 25
threads.  For our app we needs to service 100's of threads.  For now we are
use semaphore to limit number of threads calling send api but the latency is
an issue as many threads are trying to wait for few connections (10-25
depending on # of connections).



--
View this message in context: http://activemq.2283324.n4.nabble.com/FutureResponse-bottleneck-when-using-more-than-10-threads-tp4702945p4703119.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: FutureResponse bottleneck when using more than 10 threads

Posted by Tim Bain <tb...@alumni.duke.edu>.
How many connections are in your connection pool?
On Oct 14, 2015 11:47 AM, "kal2" <ki...@gmail.com> wrote:

> The FutureResponse becomes the bottleneck when we use more than 10 threads
> to
> send msgs out through connections.. We need to support large number of
> threads on producer side and they also send jms msgs, is there anything to
> set that can help with this limitation.
>
> pool-69-thread-4" - Thread t@734
>    java.lang.Thread.State: WAITING
>             at sun.misc.Unsafe.park(Native Method)
>             - parking to wait for <4bfa2856> (a
> java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
>             at
> java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
>             at
>
> java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2043)
>             at
> java.util.concurrent.ArrayBlockingQueue.take(ArrayBlockingQueue.java:374)
>             at
>
> org.apache.activemq.transport.FutureResponse.getResult(FutureResponse.java:40)
>
>
>
>
>
>
> --
> View this message in context:
> http://activemq.2283324.n4.nabble.com/FutureResponse-bottleneck-when-using-more-than-10-threads-tp4702945.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>