Author: sebb
Date: Thu Oct 21 00:28:26 2010
New Revision: 1025799

URL: http://svn.apache.org/viewvc?rev=1025799&view=rev
Log:
Bug 45703 - Synchronizing Timer

Modified:
    jakarta/jmeter/trunk/src/components/org/apache/jmeter/timers/SyncTimer.java
    jakarta/jmeter/trunk/xdocs/changes.xml

Modified: 
jakarta/jmeter/trunk/src/components/org/apache/jmeter/timers/SyncTimer.java
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/components/org/apache/jmeter/timers/SyncTimer.java?rev=1025799&r1=1025798&r2=1025799&view=diff
==============================================================================
--- jakarta/jmeter/trunk/src/components/org/apache/jmeter/timers/SyncTimer.java 
(original)
+++ jakarta/jmeter/trunk/src/components/org/apache/jmeter/timers/SyncTimer.java 
Thu Oct 21 00:28:26 2010
@@ -74,11 +74,13 @@ public class SyncTimer extends AbstractT
             final int groupSz = getGroupSize();
             final int count = timerCounter[0];
             if (
-                (groupSz == 0 && count >= 
JMeterContextService.getNumberOfThreads())
+                (groupSz == 0 && count >= // count of threads in the thread 
group
+                    
JMeterContextService.getContext().getThreadGroup().getNumThreads())
                 ||
                 (groupSz > 0 && count >= groupSz)
                 ) {
                 sync.notifyAll();
+                timerCounter[0]=0; // reset counter once we have reached the 
limit
             } else {
                 try {
                     sync.wait();

Modified: jakarta/jmeter/trunk/xdocs/changes.xml
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/xdocs/changes.xml?rev=1025799&r1=1025798&r2=1025799&view=diff
==============================================================================
--- jakarta/jmeter/trunk/xdocs/changes.xml (original)
+++ jakarta/jmeter/trunk/xdocs/changes.xml Thu Oct 21 00:28:26 2010
@@ -99,6 +99,7 @@ To override the default local language f
 <ul>
 <li>Bug 49734 - Null pointer exception on stop Threads command (Run>Stop)</li>
 <li>Bug 49666 - CSV Header read as data after EOF</li>
+<li>Bug 45703 - Synchronizing Timer</li>
 </ul>
 
 <!-- ==================================================== -->



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

Reply via email to