You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Cliff Jansen (JIRA)" <ji...@apache.org> on 2016/08/02 07:21:20 UTC

[jira] [Created] (QPID-7373) memory leak in broker with idle worker threads

Cliff Jansen created QPID-7373:
----------------------------------

             Summary: memory leak in broker with idle worker threads
                 Key: QPID-7373
                 URL: https://issues.apache.org/jira/browse/QPID-7373
             Project: Qpid
          Issue Type: Bug
          Components: C++ Broker
    Affects Versions: qpid-cpp-0.34
         Environment: linux epoll and perhaps PosixPoller and Solaris ECFPoller
            Reporter: Cliff Jansen
            Assignee: Cliff Jansen


If a C++ broker is lightly loaded with many short lived connections such that at least one worker thread remains unwoken from the epoll_wait, its DeletionManager::ThreadStatus::handles grows without bound and the associated handles retain a shared_ptr ref and never go away.

To reproduce check RSS from ps (or malloc_stats) when running a simple program that creates a connection and nothing else:


hex5:  cat foo.cpp
{code}
#include <qpid/messaging/Connection.h>
#include <iostream>
using namespace qpid::messaging;
int main(int argc, char** argv) {
    std::string broker = argc > 1 ? argv[1] : "127.0.0.1:5672";
    Connection connection(broker);
    try {
        connection.open();
        connection.close();
        return 0;
    } catch(const std::exception& error) {
        std::cerr << error.what() << std::endl;
        connection.close();
        return 1;   
    }
}
{code}
hex5:  while true; do LD_LIBRARY_PATH=../rt/b/amqp/b/q35x/rt/lib64 ./foo ; done




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

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