qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From acon...@apache.org
Subject svn commit: r1165880 - /qpid/branches/qpid-2920-1/qpid/cpp/src/qpid/cluster/exp/Multicaster.cpp
Date Tue, 06 Sep 2011 21:46:26 GMT
Author: aconway
Date: Tue Sep  6 21:46:25 2011
New Revision: 1165880

URL: http://svn.apache.org/viewvc?rev=1165880&view=rev
Log:
QPID-2920: Sleep on cpg flow control to avoid thrashing.

Added a 1ms sleep when CPG is flow controlled. Huge thruput
improvement for qpid-cluster-benchmarks multi-host case.

Modified:
    qpid/branches/qpid-2920-1/qpid/cpp/src/qpid/cluster/exp/Multicaster.cpp

Modified: qpid/branches/qpid-2920-1/qpid/cpp/src/qpid/cluster/exp/Multicaster.cpp
URL: http://svn.apache.org/viewvc/qpid/branches/qpid-2920-1/qpid/cpp/src/qpid/cluster/exp/Multicaster.cpp?rev=1165880&r1=1165879&r2=1165880&view=diff
==============================================================================
--- qpid/branches/qpid-2920-1/qpid/cpp/src/qpid/cluster/exp/Multicaster.cpp (original)
+++ qpid/branches/qpid-2920-1/qpid/cpp/src/qpid/cluster/exp/Multicaster.cpp Tue Sep  6 21:46:25
2011
@@ -65,6 +65,7 @@ Multicaster::sendMcast(const PollableEve
             std::transform(i, j, ioVector.begin(), &bufToIov);
             if (!cpg.mcast(&ioVector[0], len)) {
                 // CPG didn't send because of CPG flow control.
+                ::usleep(1000);    // Don't spin too tightly.
                 return i;
             }
             i = j;



---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org


Mime
View raw message