summaryrefslogtreecommitdiff
path: root/cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp
diff options
context:
space:
mode:
authorKim van der Riet <kpvdr@apache.org>2012-06-26 18:23:27 +0000
committerKim van der Riet <kpvdr@apache.org>2012-06-26 18:23:27 +0000
commit1ab07197127e990da2c765ea0ffa5fd8ca47b7b6 (patch)
tree18895db4a1059d984b92ab608d84c13d40df7401 /cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp
parentcbd4f9c22974db5f53b42a4326486ec8325b79cc (diff)
downloadqpid-python-1ab07197127e990da2c765ea0ffa5fd8ca47b7b6.tar.gz
QPID-3858: WIP - fixed a few logic errors and race conditions in the consume and transactional code
git-svn-id: https://svn.apache.org/repos/asf/qpid/branches/asyncstore@1354149 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp')
-rw-r--r--cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp15
1 files changed, 11 insertions, 4 deletions
diff --git a/cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp b/cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp
index e3fdd1c44d..4d145d321d 100644
--- a/cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp
+++ b/cpp/src/tests/storePerftools/asyncPerf/PerfTest.cpp
@@ -80,16 +80,23 @@ PerfTest::run()
tests::storePerftools::common::ScopedTimer st(m_testResult);
for (uint16_t q = 0; q < m_testOpts.m_numQueues; q++) {
- boost::shared_ptr<MessageProducer> mp(new MessageProducer(m_testOpts, m_msgData, m_store, m_resultQueue, m_queueList[q]));
- m_producers.push_back(mp);
for (uint16_t t = 0; t < m_testOpts.m_numEnqThreadsPerQueue; t++) { // TODO - replace with qpid threads
+ boost::shared_ptr<MessageProducer> mp(new MessageProducer(m_testOpts,
+ m_msgData,
+ m_store,
+ m_resultQueue,
+ m_queueList[q]));
+ m_producers.push_back(mp);
boost::shared_ptr<tests::storePerftools::common::Thread> tp(new tests::storePerftools::common::Thread(mp->startProducers,
reinterpret_cast<void*>(mp.get())));
threads.push_back(tp);
}
- boost::shared_ptr<MessageConsumer> mc(new MessageConsumer(m_testOpts, m_store, m_resultQueue, m_queueList[q]));
- m_consumers.push_back(mc);
for (uint16_t dt = 0; dt < m_testOpts.m_numDeqThreadsPerQueue; ++dt) { // TODO - replace with qpid threads
+ boost::shared_ptr<MessageConsumer> mc(new MessageConsumer(m_testOpts,
+ m_store,
+ m_resultQueue,
+ m_queueList[q]));
+ m_consumers.push_back(mc);
boost::shared_ptr<tests::storePerftools::common::Thread> tp(new tests::storePerftools::common::Thread(mc->startConsumers,
reinterpret_cast<void*>(mc.get())));
threads.push_back(tp);