[ 
https://issues.apache.org/jira/browse/QPID-7237?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15279833#comment-15279833
 ] 

Keith Wall commented on QPID-7237:
----------------------------------

Flavio,

For the number of threads created to be excessive, I think you must be creating 
the NO_ACK session using JMS's default 
{{javax.jms.Connection#createSession(boolean, int)}}.  When created in this 
way, the high and low watermarks of the underlying queue get set to the same 
value (default 500).  Having the two values set the same makes the 
{{FlowControlBlockingQueue}} rapid oscillate the flow control state - causing 
the stream of threads.  If you use 
{{org.apache.qpid.jms.Connection#createSession(boolean, int, int, int)}} 
instead, and set the low value sensibly e.g. 
{{org.apache.qpid.jms.Connection#createSession(false, 
org.apache.qpid.jms.Session#NO_ACKNOWLEDGE, 500, 250)}}  , you should be able 
to achieve more efficient elastic behaviour with far fewer transitions.  This 
approach will work with the releases as they stands today.



> Excessive threads creation when suspending/resuming flow
> --------------------------------------------------------
>
>                 Key: QPID-7237
>                 URL: https://issues.apache.org/jira/browse/QPID-7237
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Client
>    Affects Versions: 0.24, qpid-java-6.0.2
>            Reporter: Flavio Baronti
>            Assignee: Keith Wall
>             Fix For: qpid-java-6.0.3, qpid-java-6.1
>
>         Attachments: QPID-7237.patch
>
>
> In high load situations, with a NO_ACKNOWLEDGE session, it is possible for 
> the client to create an excessive amount of threads to suspend/resume the 
> channel.
> I'm providing a patch to avoid creating a new thread if the previous thread 
> has not completed its operation. This patch appears to avoid the problem in 
> our environment. Notice we are using version 0.24, but the code is the same 
> in the latest version.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to