[jboss-cvs] JBossAS SVN: r69010 - projects/cluster/varia/sessionstress.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Tue Jan 15 23:49:08 EST 2008
Author: bstansberry at jboss.com
Date: 2008-01-15 23:49:08 -0500 (Tue, 15 Jan 2008)
New Revision: 69010
Modified:
projects/cluster/varia/sessionstress/PerfTest.java
Log:
Force all inits to complete before beginning main loop
Modified: projects/cluster/varia/sessionstress/PerfTest.java
===================================================================
--- projects/cluster/varia/sessionstress/PerfTest.java 2008-01-16 04:48:21 UTC (rev 69009)
+++ projects/cluster/varia/sessionstress/PerfTest.java 2008-01-16 04:49:08 UTC (rev 69010)
@@ -52,6 +52,9 @@
client.start();
}
+ System.out.println("Waiting for clients to initialize");
+ barrier.await();
+
System.out.println("Waiting for clients to complete");
barrier.await();
@@ -246,18 +249,23 @@
this.read_url=tmp + read_url + "?id=";
this.write_url=tmp + write_url + "?size=" + size + "&id=";
this.setup_method=new GetMethod(tmp + setup_url + "?num_attrs=" + num_attrs + "&size=" + size);
- this.destroy_method=new GetMethod(tmp + destroy_url + "web/destroy.jsp");
+ this.destroy_method=new GetMethod(tmp + destroy_url);
}
public void run() {
+ boolean inited = false;
try {
init(num_attrs, size);
+ log("inited: " + barrier.getNumberWaiting() + " threads waiting");
+ try { barrier.await(); } finally { inited = true; }
start=System.currentTimeMillis();
loop(num_requests);
}
catch(Exception e) {
error("failure", e);
successful=false;
+ if (!inited)
+ try { barrier.await(); } catch(Exception e1) {}
}
finally {
stop=System.currentTimeMillis();
More information about the jboss-cvs-commits
mailing list