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

ASF GitHub Bot commented on QPID-6213:
--------------------------------------

GitHub user ChugR opened a pull request:

    https://github.com/apache/qpid/pull/4

    QPID-6213: fix queue cleaner connection timeouts

    Here's a patch that solves a windows issue and possibly is a general 
solution the base problem.
    
    1. On windows the queue cleaner runs before there are any queues. This 
causes an empty list of queues to get posted by the task which exits without 
rescheduling itself. Then the pollable queue never fires because nothing ever 
got added. Finally the original task never gets rescheduled and the process is 
deadlocked. The solution is to add a null pointer to pollable queue in the 
event that the pollable queue appears empty. This makes sure that the task on 
the other side of the pollable queue runs. Note that this null may get added 
even though a batch is already in flight. That will not break anything.
    
    2. This patch adds a timeout, currently one second, which when exceeded 
gets the purge function to reschedule it's pending work and exit. This gives 
the other i/o tasks a shot at running before the queue cleaning starts again. 
In my testing I had 2000 queues and in its current form the queue cleaner will 
clean all 2000 before releasing the thread regardless of the batch size 
presented to the fire function. With this patch the 2000 queues are processed 
but in chunks that are called by the pollable queue.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/ChugR/qpid trunk

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/qpid/pull/4.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #4
    
----
commit 25218c048393af2781737adf6457addbe971cb75
Author: Charles E. Rolke <c...@apache.org>
Date:   2014-11-24T21:35:09Z

    QPID-6213: fix queue cleaner connection timeouts

----


> qpidd misses heartbeats
> -----------------------
>
>                 Key: QPID-6213
>                 URL: https://issues.apache.org/jira/browse/QPID-6213
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Broker
>    Affects Versions: 0.30
>            Reporter: Gordon Sim
>            Assignee: Gordon Sim
>             Fix For: 0.31
>
>         Attachments: qpid-6213-svn-01.patch
>
>
> Caused by https://issues.apache.org/jira/browse/QPID-5758. Reproducer from 
> Pavel Moravec: create many heartbeat enabled connections and queues (e.g. 500 
> idle receivers, each with their own queue) and have the purge interval 
> relatively short (to speed up reproducing).
> The broker misses heartbeats and connections get timed out.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org

Reply via email to