Author: jsong Date: Tue Jan 25 13:57:30 2005 New Revision: 126432 URL: http://svn.apache.org/viewcvs?view=rev&rev=126432 Log: Contributed by Jamie Zyskowski: update controls perf for new beehive build process, add framework-synchronized strlen custom control scenario Added: incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlST.java incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlSTImpl.java incubator/beehive/trunk/controls/test/perf/perfEnv.bat incubator/beehive/trunk/controls/test/perf/perfEnv.sh incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenSTPgmTest.java incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlenST/ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlenST/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/controls.jsp incubator/beehive/trunk/controls/test/perf/webapps/reportweb.properties Removed: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/controller.properties Modified: incubator/beehive/trunk/controls/test/perf/bin/benchmark.bat incubator/beehive/trunk/controls/test/perf/bin/benchmark.sh incubator/beehive/trunk/controls/test/perf/bin/perf.bat incubator/beehive/trunk/controls/test/perf/bin/perf.sh incubator/beehive/trunk/controls/test/perf/bin/run.bat incubator/beehive/trunk/controls/test/perf/bin/run.sh incubator/beehive/trunk/controls/test/perf/build.xml incubator/beehive/trunk/controls/test/perf/cases/controls-perf.xml incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/PerfResultControlImpl.java incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarargsControlImpl.java incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarretControlImpl.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/dproxy/StrlenDProxyTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javabean/StrlenBeanTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javaclass/StrlenClassTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/methodinv/StrlenMethodInvTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenPgmTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarargsPgmTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarretPgmTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/PerfTest.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/StandAlonePerfRunner.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/WebPerfRunner.java incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/utils/Constants.java incubator/beehive/trunk/controls/test/perf/webapps/build.xml incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ControlsForm.java incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ReportForm.java incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/XmlbeansForm.java incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/graphing/SnapshotProducer.java incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/Controller.jpf incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/index.jsp incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/snapshot.jsp incubator/beehive/trunk/controls/test/tools/mantis/build.xml
Modified: incubator/beehive/trunk/controls/test/perf/bin/benchmark.bat Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/bin/benchmark.bat?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/bin/benchmark.bat&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/bin/benchmark.bat&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/bin/benchmark.bat (original) +++ incubator/beehive/trunk/controls/test/perf/bin/benchmark.bat Tue Jan 25 13:57:30 2005 @@ -1 +1 @@ -java -Xmx64m -classpath %BEEHIVE_HOME%\controls\test\perf\build org.apache.beehive.controls.perf.benchmarks.%* +java -Xmx64m -classpath %BEEHIVE_PERFROOT%\build org.apache.beehive.controls.perf.benchmarks.%* Modified: incubator/beehive/trunk/controls/test/perf/bin/benchmark.sh Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/bin/benchmark.sh?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/bin/benchmark.sh&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/bin/benchmark.sh&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/bin/benchmark.sh (original) +++ incubator/beehive/trunk/controls/test/perf/bin/benchmark.sh Tue Jan 25 13:57:30 2005 @@ -1 +1 @@ -java -Xmx64m -classpath $BEEHIVE_HOME/controls/test/perf/build org.apache.beehive.controls.perf.benchmarks.$* +java -Xmx64m -classpath $BEEHIVE_PERFROOT/build org.apache.beehive.controls.perf.benchmarks.$* Modified: incubator/beehive/trunk/controls/test/perf/bin/perf.bat Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/bin/perf.bat?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/bin/perf.bat&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/bin/perf.bat&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/bin/perf.bat (original) +++ incubator/beehive/trunk/controls/test/perf/bin/perf.bat Tue Jan 25 13:57:30 2005 @@ -1 +1 @@ -java -Xmx64m -classpath %BEEHIVE_HOME%\controls\test\perf\build;%BEEHIVE_HOME%\controls\test\perf\ctlbuild;%BEEHIVE_HOME%\controls\build\jars\controls.jar org.apache.beehive.controls.perf.standalone.%* +java -Xmx64m -classpath %BEEHIVE_PERFROOT%\build;%BEEHIVE_PERFROOT%\ctlbuild;%BEEHIVE_PERFROOT%\..\..\..\controls\build\jars\controls.jar org.apache.beehive.controls.perf.standalone.%* Modified: incubator/beehive/trunk/controls/test/perf/bin/perf.sh Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/bin/perf.sh?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/bin/perf.sh&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/bin/perf.sh&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/bin/perf.sh (original) +++ incubator/beehive/trunk/controls/test/perf/bin/perf.sh Tue Jan 25 13:57:30 2005 @@ -1 +1 @@ -java -Xmx64m -classpath $BEEHIVE_HOME/controls/test/perf/build:$BEEHIVE_HOME/controls/test/perf/ctlbuild:$BEEHIVE_HOME/controls/build/jars/controls.jar org.apache.beehive.controls.perf.standalone.$* +java -Xmx64m -classpath $BEEHIVE_PERFROOT/build:$BEEHIVE_PERFROOT/ctlbuild:$BEEHIVE_PERFROOT/../../../controls/build/jars/controls.jar org.apache.beehive.controls.perf.standalone.$* Modified: incubator/beehive/trunk/controls/test/perf/bin/run.bat Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/bin/run.bat?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/bin/run.bat&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/bin/run.bat&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/bin/run.bat (original) +++ incubator/beehive/trunk/controls/test/perf/bin/run.bat Tue Jan 25 13:57:30 2005 @@ -1,31 +1,8 @@ -echo off - -echo *****CUSTOM CONTROL PERF RUN START***** -echo -echo *****STRLEN TEST START***** -echo -call perf.bat StrlenPgmTest %* -echo -call benchmark.bat dproxy.StrlenDProxyTest %* -echo -call benchmark.bat methodinv.StrlenMethodInvTest %* -echo -call benchmark.bat javabean.StrlenBeanTest %* -echo -call benchmark.bat javaclass.StrlenClassTest %* -echo -echo *****STRLEN TEST END***** -echo -echo *****VARARGS TEST START***** -echo +call perf.bat StrlenPgmTest $* +call perf.bat StrlenSTPgmTest $* +call benchmark.bat dproxy.StrlenDProxyTest $* +call benchmark.bat methodinv.StrlenMethodInvTest $* +call benchmark.bat javabean.StrlenBeanTest $* +call benchmark.bat javaclass.StrlenClassTest $* call perf.bat VarargsPgmTest -echo -echo *****VARARGS TEST END***** -echo -echo *****VAR RETURN TEST START***** -echo call perf.bat VarretPgmTest -echo -echo *****VAR RETURN TEST END***** -echo -echo *****CUSTOM CONTROL PERF RUN END***** Modified: incubator/beehive/trunk/controls/test/perf/bin/run.sh Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/bin/run.sh?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/bin/run.sh&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/bin/run.sh&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/bin/run.sh (original) +++ incubator/beehive/trunk/controls/test/perf/bin/run.sh Tue Jan 25 13:57:30 2005 @@ -1,29 +1,8 @@ -echo "*****CUSTOM CONTROL PERF RUN START*****" -echo "" -echo "*****STRLEN TEST START*****" -echo "" sh ./perf.sh StrlenPgmTest $* -echo "" +sh ./perf.sh StrlenSTPgmTest $* sh ./benchmark.sh dproxy.StrlenDProxyTest $* -echo "" sh ./benchmark.sh methodinv.StrlenMethodInvTest $* -echo "" sh ./benchmark.sh javabean.StrlenBeanTest $* -echo "" sh ./benchmark.sh javaclass.StrlenClassTest $* -echo "" -echo "*****STRLEN TEST END*****" -echo "" -echo "*****VARARGS TEST START*****" -echo "" sh ./perf.sh VarargsPgmTest -echo "" -echo "*****VARARGS TEST END*****" -echo "" -echo "*****VAR RETURN TEST START*****" -echo "" sh ./perf.sh VarretPgmTest -echo "" -echo "*****VAR RETURN TEST END*****" -echo "" -echo "*****CUSTOM CONTROL PERF RUN END*****" Modified: incubator/beehive/trunk/controls/test/perf/build.xml Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/build.xml?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/build.xml&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/build.xml&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/build.xml (original) +++ incubator/beehive/trunk/controls/test/perf/build.xml Tue Jan 25 13:57:30 2005 @@ -4,6 +4,7 @@ <target name="usage"> <echo> Usage: +bootstrap - for report web only (downloads cewolf jars) [re]build - builds everything [re]build.tests - build tests and utils [re]build.controls - build controls only @@ -23,6 +24,7 @@ <property file="${beehive.home}/controls/test/common/path.properties"/> <!-- root dirs for finding everything --> + <echo message="beehive.home set to ${beehive.home}"/> <property name="control.perf.root" value="${beehive.home}/controls/test/perf"/> <!-- control perf dirs --> @@ -64,6 +66,9 @@ </path> <path id="tch.run.classpath"> + <pathelement path="${httpunit.jar}"/> + <pathelement path="${httpunit-xerces.jar}"/> + <pathelement path="${nekohtml.jar}"/> <path refid="xbean.dependency.path"/> <path refid="controls.dependency.path"/> <path refid="velocity.dependency.path"/> @@ -77,9 +82,6 @@ for them --> <pathelement path="${jakarta.jar}"/> - <pathelement path="${httpunit.jar}"/> - <pathelement path="${httpunit-xerces.jar}"/> - <pathelement path="${nekohtml.jar}"/> <pathelement path="${control.perf.build}"/> </path> @@ -100,6 +102,8 @@ dest="${control.perf.external}/cewolf-0.9.8.zip" verbose="true"/> <unzip src="${control.perf.external}/cewolf-0.9.8.zip" dest="${control.perf.external}"/> + <!-- delete so crimson.jar doesn't get copied into the report webapp - it causes parsing errors --> + <delete file="${control.perf.external}/cewolf-0.9.8/lib/crimson.jar"/> </target> <target name="clean.bootstrap"> @@ -161,7 +165,7 @@ <target name="run_client"> <property name="gtlf.dtd.use.remote" value="true"/> - <property name="gtlf.dtd.remote" value="http://svn.apache.org/viewcvs.cgi/*checkout*/incubator/beehive/trunk/controls/test/infra/gtlf/gtlf-config-2.0.dtd?root=Apache-SVN"/> + <property name="gtlf.dtd.remote" value="http://incubator.apache.org/beehive/dtd/gtlf/gtlf-config-2.0.dtd"/> <property name="gtlf.dtd.local" value="infra/gtlf/gtlf-config-2.0.dtd"/> <property name="tch.base-logfile-name" value="tch"/> @@ -195,7 +199,7 @@ <property name="test.freq" value="bvt"/> <property name="tch.log.debug-level" value="0"/> <property name="tch.fail-build" value="true"/> - <property name="tch.replication.entry-point" value="ant -f ${controls.perf.root}/build.xml bvt"/> + <property name="tch.replication.entry-point" value="ant -f ${control.perf.root}/build.xml bvt"/> <antcall target="run_client"/> </target> @@ -209,14 +213,14 @@ <ant antfile="webapps/build.xml" target="build" /> <echo message="sleep to allow tomcat to become available for deployment"/> <sleep seconds="20"/> - <echo message="continue the new thread, deploy controlsWeb"/> + <echo message="continue the new thread, deploy controlsPerfWeb"/> <ant antfile="webapps/build.xml" target="ensure.deployed"/> <echo message="continue the new thread, run perf tests"/> <antcall target="checkin.tests.client"/> - <echo message="continue the new thread, undeploy controlsWeb"/> + <echo message="continue the new thread, undeploy controlsPerfWeb"/> <ant antfile="webapps/build.xml" target="undeploy"/> <echo message="stop tomcat server, finish the new thread"/> - <ant antfile="webapps/build.xml" target="stop"/> + <ant antfile="webapps/build.xml" target="stop"/> </sequential> </parallel> </target> Modified: incubator/beehive/trunk/controls/test/perf/cases/controls-perf.xml Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/cases/controls-perf.xml?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/cases/controls-perf.xml&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/cases/controls-perf.xml&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/cases/controls-perf.xml (original) +++ incubator/beehive/trunk/controls/test/perf/cases/controls-perf.xml Tue Jan 25 13:57:30 2005 @@ -9,7 +9,7 @@ <controlsperf> <cmdline>%{control.perf.root}/bin/perf StrlenPgmTest</cmdline> <hash>-1989672960</hash> - <bar>4026</bar> + <bar>1202</bar> <drift>0.20</drift> <timeout>10000</timeout> </controlsperf> @@ -18,7 +18,25 @@ <controlsperf> <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf</url> <hash>-1989672960</hash> - <bar>4026</bar> + <bar>1202</bar> + <drift>0.20</drift> + <timeout>10000</timeout> + </controlsperf> + </test> + <test name="StrlenSTPgmTest_standalone"> + <controlsperf> + <cmdline>%{control.perf.root}/bin/perf StrlenSTPgmTest</cmdline> + <hash>-1989672960</hash> + <bar>5288</bar> + <drift>0.20</drift> + <timeout>10000</timeout> + </controlsperf> + </test> + <test name="StrlenSTPgmTest_jpf"> + <controlsperf> + <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlenST/Controller.jpf</url> + <hash>-1989672960</hash> + <bar>5288</bar> <drift>0.20</drift> <timeout>10000</timeout> </controlsperf> @@ -28,7 +46,7 @@ <cmdline>%{control.perf.root}/bin/benchmark dproxy.StrlenDProxyTest</cmdline> <hash>-1989672960</hash> <bar>724</bar> - <drift>0.20</drift> + <drift>0.35</drift> <timeout>10000</timeout> </controlsperf> </test> @@ -36,8 +54,8 @@ <controlsperf> <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf</url> <hash>-1989672960</hash> - <bar>1116</bar> - <drift>0.20</drift> + <bar>724</bar> + <drift>0.35</drift> <timeout>10000</timeout> </controlsperf> </test> @@ -45,7 +63,7 @@ <controlsperf> <cmdline>%{control.perf.root}/bin/benchmark methodinv.StrlenMethodInvTest</cmdline> <hash>-1989672960</hash> - <bar>11397</bar> + <bar>3054</bar> <drift>0.20</drift> <timeout>100000</timeout> </controlsperf> @@ -54,7 +72,7 @@ <controlsperf> <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf</url> <hash>-1989672960</hash> - <bar>11928</bar> + <bar>3054</bar> <drift>0.20</drift> <timeout>10000</timeout> </controlsperf> @@ -63,8 +81,8 @@ <controlsperf> <cmdline>%{control.perf.root}/bin/benchmark javabean.StrlenBeanTest</cmdline> <hash>-1989672960</hash> - <bar>42</bar> - <drift>0.20</drift> + <bar>60</bar> + <drift>0.50</drift> <timeout>1000</timeout> </controlsperf> </test> @@ -72,8 +90,8 @@ <controlsperf> <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf</url> <hash>-1989672960</hash> - <bar>65</bar> - <drift>0.20</drift> + <bar>60</bar> + <drift>0.50</drift> <timeout>1000</timeout> </controlsperf> </test> @@ -82,7 +100,7 @@ <cmdline>%{control.perf.root}/bin/benchmark javaclass.StrlenClassTest</cmdline> <hash>-1989672960</hash> <bar>42</bar> - <drift>0.20</drift> + <drift>0.40</drift> <timeout>10000</timeout> </controlsperf> </test> @@ -91,7 +109,7 @@ <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf</url> <hash>-1989672960</hash> <bar>65</bar> - <drift>0.20</drift> + <drift>0.40</drift> <timeout>10000</timeout> </controlsperf> </test> @@ -99,7 +117,7 @@ <controlsperf> <cmdline>%{control.perf.root}/bin/perf VarargsPgmTest</cmdline> <hash>-1284084288</hash> - <bar>4031</bar> + <bar>2914</bar> <drift>0.20</drift> <timeout>10000</timeout> </controlsperf> @@ -108,7 +126,7 @@ <controlsperf> <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf</url> <hash>-1284084288</hash> - <bar>4031</bar> + <bar>2914</bar> <drift>0.20</drift> <timeout>10000</timeout> </controlsperf> @@ -117,7 +135,7 @@ <controlsperf> <cmdline>%{control.perf.root}/bin/perf VarretPgmTest</cmdline> <hash>95000000</hash> - <bar>12242</bar> + <bar>4176</bar> <drift>0.20</drift> <timeout>10000</timeout> </controlsperf> @@ -126,7 +144,7 @@ <controlsperf> <url>http://%{test.hostname}:%{test.port}/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf</url> <hash>95000000</hash> - <bar>12242</bar> + <bar>4176</bar> <drift>0.20</drift> <timeout>10000</timeout> </controlsperf> Modified: incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/PerfResultControlImpl.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/PerfResultControlImpl.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/PerfResultControlImpl.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/PerfResultControlImpl.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/PerfResultControlImpl.java (original) +++ incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/PerfResultControlImpl.java Tue Jan 25 13:57:30 2005 @@ -24,6 +24,7 @@ doc.validate(); _resultSets.put(p_result.getAbsolutePath(),doc.getResultSet()); + // initialize the latest filename if(null == _latestFilename) _latestFilename = p_result.getAbsolutePath(); else @@ -32,7 +33,7 @@ Calendar candidateDate = doc.getResultSet().getEnvironment().getDate(); if(currentDate.getTimeInMillis() < candidateDate.getTimeInMillis()) _latestFilename = p_result.getAbsolutePath(); - } + } } public void loadResults(File p_dir) throws XmlException,IOException @@ -47,7 +48,6 @@ } } - } @@ -70,5 +70,6 @@ { return _latestFilename; } + } Added: incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlST.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlST.java?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlST.java Tue Jan 25 13:57:30 2005 @@ -0,0 +1,9 @@ +package org.apache.beehive.controls.perf.controls.custom; + +import org.apache.beehive.controls.api.bean.ControlInterface; + [EMAIL PROTECTED] +public interface StrlenControlST +{ + public int stringLength(String input); +} Added: incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlSTImpl.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlSTImpl.java?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/StrlenControlSTImpl.java Tue Jan 25 13:57:30 2005 @@ -0,0 +1,12 @@ +package org.apache.beehive.controls.perf.controls.custom; + +import org.apache.beehive.controls.api.bean.ControlImplementation; +import org.apache.beehive.controls.api.bean.Threading; +import org.apache.beehive.controls.api.bean.ThreadingPolicy; + [EMAIL PROTECTED] [EMAIL PROTECTED](ThreadingPolicy.SINGLE_THREADED) +public class StrlenControlSTImpl implements StrlenControlST +{ + public int stringLength(String input){ return input.length();} +} Modified: incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarargsControlImpl.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarargsControlImpl.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarargsControlImpl.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarargsControlImpl.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarargsControlImpl.java (original) +++ incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarargsControlImpl.java Tue Jan 25 13:57:30 2005 @@ -1,8 +1,11 @@ package org.apache.beehive.controls.perf.controls.custom; import org.apache.beehive.controls.api.bean.ControlImplementation; +import org.apache.beehive.controls.api.bean.Threading; +import org.apache.beehive.controls.api.bean.ThreadingPolicy; @ControlImplementation [EMAIL PROTECTED](ThreadingPolicy.MULTI_THREADED) public class VarargsControlImpl implements VarargsControl { public int getIntSum(int... args) Modified: incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarretControlImpl.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarretControlImpl.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarretControlImpl.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarretControlImpl.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarretControlImpl.java (original) +++ incubator/beehive/trunk/controls/test/perf/ctlsrc/org/apache/beehive/controls/perf/controls/custom/VarretControlImpl.java Tue Jan 25 13:57:30 2005 @@ -2,8 +2,11 @@ import java.lang.StringBuffer; import org.apache.beehive.controls.api.bean.ControlImplementation; +import org.apache.beehive.controls.api.bean.Threading; +import org.apache.beehive.controls.api.bean.ThreadingPolicy; @ControlImplementation [EMAIL PROTECTED](ThreadingPolicy.MULTI_THREADED) public class VarretControlImpl implements VarretControl { public String createString(int p_size) Added: incubator/beehive/trunk/controls/test/perf/perfEnv.bat Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/perfEnv.bat?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/perfEnv.bat Tue Jan 25 13:57:30 2005 @@ -0,0 +1 @@ +set BEEHIVE_PERFROOT=%~dp0. Added: incubator/beehive/trunk/controls/test/perf/perfEnv.sh Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/perfEnv.sh?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/perfEnv.sh Tue Jan 25 13:57:30 2005 @@ -0,0 +1,2 @@ +BEEHIVE_PERFROOT=`pwd` +export BEEHIVE_PERFROOT Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/dproxy/StrlenDProxyTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/dproxy/StrlenDProxyTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/dproxy/StrlenDProxyTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/dproxy/StrlenDProxyTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/dproxy/StrlenDProxyTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/dproxy/StrlenDProxyTest.java Tue Jan 25 13:57:30 2005 @@ -11,7 +11,6 @@ { public static void main(String[] args) throws Throwable { - System.out.println("TEST: "+StrlenDProxyTest.class.getName()); final int iterations = Constants.STRLEN_ITERATIONS; String input = ""; @@ -48,8 +47,9 @@ cputime = System.currentTimeMillis() - cputime; // print the results - System.out.println("hash="+stringSum); - System.out.println("time="+cputime); + System.out.print(Constants.DELIM+StrlenDProxyTest.class.getName()+" "); + System.out.print("hash "+stringSum+" "); + System.out.println("time "+cputime); } private int run(String input, IStrlen strlen) throws Throwable Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javabean/StrlenBeanTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javabean/StrlenBeanTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javabean/StrlenBeanTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javabean/StrlenBeanTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javabean/StrlenBeanTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javabean/StrlenBeanTest.java Tue Jan 25 13:57:30 2005 @@ -9,7 +9,7 @@ { public static void main(String[] args) throws Throwable { - System.out.println("TEST: "+StrlenBeanTest.class.getName()); + final int iterations = Constants.STRLEN_ITERATIONS; String input = ""; @@ -43,8 +43,9 @@ cputime = System.currentTimeMillis() - cputime; // print the results - System.out.println("hash="+stringSum); - System.out.println("time="+cputime); + System.out.print(Constants.DELIM+StrlenBeanTest.class.getName()+" "); + System.out.print("hash "+stringSum+" "); + System.out.println("time "+cputime); } private int run(String input, StrlenBean bean) throws Throwable Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javaclass/StrlenClassTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javaclass/StrlenClassTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javaclass/StrlenClassTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javaclass/StrlenClassTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javaclass/StrlenClassTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/javaclass/StrlenClassTest.java Tue Jan 25 13:57:30 2005 @@ -10,7 +10,6 @@ { public static void main(String[] args) throws Throwable { - System.out.println("TEST: "+StrlenClassTest.class.getName()); final int iterations = Constants.STRLEN_ITERATIONS; String input = ""; @@ -45,8 +44,9 @@ cputime = System.currentTimeMillis() - cputime; // print the results - System.out.println("hash="+stringSum); - System.out.println("time="+cputime); + System.out.print(Constants.DELIM+StrlenClassTest.class.getName()+" "); + System.out.print("hash "+stringSum+" "); + System.out.println("time "+cputime); } private int run(String input, CStrlen strlen) throws Throwable Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/methodinv/StrlenMethodInvTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/methodinv/StrlenMethodInvTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/methodinv/StrlenMethodInvTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/methodinv/StrlenMethodInvTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/methodinv/StrlenMethodInvTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/benchmarks/methodinv/StrlenMethodInvTest.java Tue Jan 25 13:57:30 2005 @@ -9,7 +9,6 @@ { public static void main(String[] args) throws Throwable { - System.out.println("TEST: "+StrlenMethodInvTest.class.getName()); final int iterations = Constants.STRLEN_ITERATIONS; String input = ""; @@ -43,8 +42,9 @@ cputime = System.currentTimeMillis() - cputime; // print the results - System.out.println("hash="+stringSum); - System.out.println("time="+cputime); + System.out.print(Constants.DELIM+StrlenMethodInvTest.class.getName()+" "); + System.out.print("hash "+stringSum+" "); + System.out.println("time "+cputime); } private int run(String input, Method method) throws Throwable Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenPgmTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenPgmTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenPgmTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenPgmTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenPgmTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenPgmTest.java Tue Jan 25 13:57:30 2005 @@ -10,7 +10,6 @@ { public static void main(String[] args) throws Exception { - System.out.println("TEST: "+StrlenPgmTest.class.getName()); final int iterations = Constants.STRLEN_ITERATIONS; String input = ""; @@ -44,8 +43,9 @@ cputime = System.currentTimeMillis() - cputime; // print the results - System.out.println("hash="+stringSum); - System.out.println("time="+cputime); + System.out.print(Constants.DELIM+StrlenPgmTest.class.getName()+" "); + System.out.print("hash "+stringSum+" "); + System.out.println("time "+cputime); } Added: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenSTPgmTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenSTPgmTest.java?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/StrlenSTPgmTest.java Tue Jan 25 13:57:30 2005 @@ -0,0 +1,57 @@ +package org.apache.beehive.controls.perf.standalone; + +import org.apache.beehive.controls.perf.utils.Constants; +import org.apache.beehive.controls.perf.utils.PerfUtil; + +// custom control +import org.apache.beehive.controls.perf.controls.custom.StrlenControlSTBean; + +public class StrlenSTPgmTest +{ + public static void main(String[] args) throws Exception + { + final int iterations = Constants.STRLEN_ITERATIONS; + String input = ""; + + PerfUtil util = new PerfUtil(); + if(args.length == 0){ + input = util.createString(Constants.DEFAULT_STR_SIZE); + } + else{ + input = util.createString(Integer.parseInt(args[0])); + } + + StrlenSTPgmTest test = new StrlenSTPgmTest(); + long cputime; + int stringSum = 0; + + // programatically instantiate the control to be used by the test + StrlenControlSTBean control = (StrlenControlSTBean)java.beans.Beans.instantiate(null, + "org.apache.beehive.controls.perf.controls.custom.StrlenControlSTBean"); + + // warm up the vm + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + stringSum += test.run(input,control); + } + cputime = System.currentTimeMillis() - cputime; + + // run it again for the real measurement + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + stringSum += test.run(input,control); + } + cputime = System.currentTimeMillis() - cputime; + + // print the results + System.out.print(Constants.DELIM+StrlenPgmTest.class.getName()+" "); + System.out.print("hash "+stringSum+" "); + System.out.println("time "+cputime); + + } + + private int run(String input, StrlenControlSTBean control) throws Exception + { + return(control.stringLength(input)); + } +} Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarargsPgmTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarargsPgmTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarargsPgmTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarargsPgmTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarargsPgmTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarargsPgmTest.java Tue Jan 25 13:57:30 2005 @@ -16,8 +16,7 @@ final int iterations = Constants.VARARGS_ITERATIONS; PerfUtil util = new PerfUtil(); int[] input = util.createIntArray(Constants.DEFAULT_VARARG_PARAMS[Constants.DEFAULT_VARARG_PARAMS.length-1]); - - System.out.println("TEST: "+VarargsPgmTest.class.getName()); + VarargsPgmTest test = new VarargsPgmTest(); long cputime; int hash = 0; @@ -32,6 +31,7 @@ int sum = 0; long duration = 0; cputime = 0; + System.out.print(Constants.DELIM+VarargsPgmTest.class.getName()+" "); for(int j=0; j<Constants.DEFAULT_VARARG_PARAMS.length; j++) { input = util.createIntArray(Constants.DEFAULT_VARARG_PARAMS[j]); @@ -44,17 +44,18 @@ duration = System.currentTimeMillis() - duration; // print the results - System.out.println("array size="+input.length); - System.out.println("expected sum="+expectedSum(input)); - System.out.println("actual sum="+sum); - System.out.println("duration="+duration+"\n"); + System.out.print("array_size"+j+"="+input.length+" "); + System.out.print("expected_sum"+j+"="+expectedSum(input)+" "); + System.out.print("actual_sum"+j+"="+sum+" "); + System.out.print("duration"+j+"="+duration+" "); // update the overall result hash += sum; cputime += duration; } - System.out.println("hash="+hash); - System.out.println("time="+cputime); + + System.out.print("hash "+hash+" "); + System.out.println("time "+cputime); } private int run(int[] input, VarargsControlBean control) throws Exception Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarretPgmTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarretPgmTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarretPgmTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarretPgmTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarretPgmTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/standalone/VarretPgmTest.java Tue Jan 25 13:57:30 2005 @@ -11,12 +11,12 @@ public static void main(String[] args) throws Exception { // programatically instantiate the control to be used by the test - VarretControlBean control = (VarretControlBean)java.beans.Beans.instantiate(null,"org.apache.beehive.controls.perf.controls.custom.VarretControlBean"); + VarretControlBean control = (VarretControlBean)java.beans.Beans.instantiate(null, + "org.apache.beehive.controls.perf.controls.custom.VarretControlBean"); final int iterations = Constants.VARRET_ITERATIONS; int[] input = Constants.DEFAULT_VARRET_PARAMS; - - System.out.println("TEST: "+VarretPgmTest.class.getName()); + VarretPgmTest test = new VarretPgmTest(); long cputime; int hash = 0; @@ -31,6 +31,7 @@ long duration = 0; int length = 0; cputime = 0; + System.out.print(Constants.DELIM+VarretPgmTest.class.getName()+" "); for(int j=0; j<Constants.DEFAULT_VARRET_PARAMS.length; j++) { length = 0; @@ -42,16 +43,16 @@ duration = System.currentTimeMillis() - duration; // print the results - System.out.println("input="+input[j]); - System.out.println("length sum="+length); - System.out.println("duration="+duration+"\n"); + System.out.print("input"+j+"="+input[j]+" "); + System.out.print("length_sum"+j+"="+length+" "); + System.out.print("duration"+j+"="+duration+" "); // update the overall result hash += length; cputime += duration; } - System.out.println("hash="+hash); - System.out.println("time="+cputime); + System.out.print("hash "+hash+" "); + System.out.println("time "+cputime); } private String run(int input, VarretControlBean control) throws Exception Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/PerfTest.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/PerfTest.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/PerfTest.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/PerfTest.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/PerfTest.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/PerfTest.java Tue Jan 25 13:57:30 2005 @@ -21,7 +21,7 @@ private String _sCmdline = null; private String _sUrl = null; private int _iHash; - private long _lBar; + private float _fBar; private float _fDrift; private long _lTimeout; @@ -45,7 +45,7 @@ logicTask.init(getLogicalTestName(), _sCmdline, _iHash, - _lBar, + _fBar, _fDrift, _lTimeout); return logicTask; @@ -56,7 +56,7 @@ logicTask.init(getLogicalTestName(), _sUrl, _iHash, - _lBar, + _fBar, _fDrift, _lTimeout); return logicTask; @@ -95,7 +95,7 @@ public void addConfiguredBar(Bar p_bar) { - this._lBar = Long.parseLong(handleValue(p_bar.getText())); + this._fBar = Float.parseFloat(handleValue(p_bar.getText())); } public void addConfiguredDrift(Drift p_drift) Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/StandAlonePerfRunner.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/StandAlonePerfRunner.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/StandAlonePerfRunner.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/StandAlonePerfRunner.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/StandAlonePerfRunner.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/StandAlonePerfRunner.java Tue Jan 25 13:57:30 2005 @@ -11,6 +11,7 @@ import org.apache.beehive.test.tools.tch.extension.exectask.common.ResultLogger; import org.apache.beehive.controls.perf.utils.StreamCapture; +import org.apache.beehive.controls.perf.utils.Constants; /** * @author [EMAIL PROTECTED] @@ -50,7 +51,11 @@ public TaskContext run(TaskContext in) { - long lActualTime = -1; + //float fActualTime = -1; + long lActualTime = -1; + //float fActualMemory = -1; + long lActualMemory = -1; + float fActualDrift = -1; int iActualHash = -1; // run the commandline @@ -66,41 +71,82 @@ scStdOut.join(_lTimeout); // grab the test result from stdout - StringTokenizer st = new StringTokenizer(scStdOut.getString(),"\n"); - while(st.hasMoreTokens()){ + StringTokenizer st = new StringTokenizer(scStdOut.getString()," "); + while(st.hasMoreTokens()) + { String sCurrent = st.nextToken(); - if(sCurrent.startsWith("time=")){ - StringTokenizer stTime = new StringTokenizer(sCurrent,"="); - stTime.nextToken(); - lActualTime = Long.parseLong(stTime.nextToken()); + if(sCurrent.indexOf("time") == 0 && sCurrent.length() == "time".length()) + { + lActualTime = Long.parseLong(st.nextToken().trim()); + } + if(sCurrent.indexOf("memory") == 0 && sCurrent.length() == "memory".length()) + { + lActualMemory = Long.parseLong(st.nextToken().trim()); } - else if(sCurrent.startsWith("hash=")){ - StringTokenizer stHash = new StringTokenizer(sCurrent,"="); - stHash.nextToken(); - iActualHash = Integer.parseInt(stHash.nextToken()); + else if(sCurrent.indexOf("hash") == 0 && sCurrent.length() == "hash".length()) + { + iActualHash = Integer.parseInt(st.nextToken().trim()); } } - // calculate the drift - float fActualDrift = ((lActualTime - _fBar)/_fBar); + // calculate the drift for time (or memory if time isn't given) + if(-1 != lActualTime) + { + fActualDrift = ((lActualTime - _fBar)/_fBar); + } + else if(-1 != lActualMemory) + { + fActualDrift = ((lActualMemory - _fBar)/_fBar); + } + // log the test result + String perfResultFormat = "\n"+Constants.DELIM+_sTestname+" hash "+iActualHash+" "; + _logger.inform("----------"); _logger.inform("allowed hash="+_iHash); _logger.inform("actual hash="+iActualHash); _logger.inform("----------"); - _logger.inform("allowed time="+_fBar); - _logger.inform("actual time="+lActualTime); - _logger.inform("----------"); + + if(-1 != lActualTime && -1 != lActualMemory) + { + _logger.inform("allowed time="+_fBar); + _logger.inform("actual time="+lActualTime); + _logger.inform("actual memory="+lActualMemory); + _logger.inform("----------"); + perfResultFormat += "time "+lActualTime+" memory "+lActualMemory; + } + else if(-1 != lActualMemory && -1 == lActualTime) + { + _logger.inform("allowed memory="+_fBar); + _logger.inform("actual memory="+lActualMemory); + _logger.inform("----------"); + perfResultFormat += " memory "+lActualMemory; + } + else if(-1 != lActualTime) + { + _logger.inform("allowed time="+_fBar); + _logger.inform("actual time="+lActualTime); + _logger.inform("----------"); + perfResultFormat += "time "+lActualTime; + } + else + { + _logger.inform("ERROR: neither time nor memory are set"); + _logger.inform("----------"); + } + _logger.inform("allowed drift (abs)="+_fDrift); _logger.inform("actual drift="+fActualDrift); - - _logger.inform("\nTEST: "+_sTestname+" time "+lActualTime+" hash "+iActualHash); + _logger.inform("----------"); + _logger.inform(perfResultFormat); // evaluate the result if(iActualHash != _iHash) { _logger.failure("HASH ERROR"); + _logger.inform("command line output:\n"+scStdOut.getString()); + _logger.inform("command line srderr:\n"+scStdErr.getString()); } else if(Math.abs(fActualDrift) > _fDrift) { Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/WebPerfRunner.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/WebPerfRunner.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/WebPerfRunner.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/WebPerfRunner.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/WebPerfRunner.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/tch/WebPerfRunner.java Tue Jan 25 13:57:30 2005 @@ -1,11 +1,10 @@ package org.apache.beehive.controls.perf.tch; // java utils -import java.lang.InterruptedException; import java.lang.Math; -import java.io.IOException; import java.util.StringTokenizer; // milton requirements +import org.apache.beehive.controls.perf.utils.Constants; import org.apache.beehive.test.tools.milton.common.Report; import com.meterware.httpunit.WebConversation; import com.meterware.httpunit.WebResponse; @@ -16,6 +15,8 @@ import org.apache.beehive.test.tools.tch.core.test.AbstractTestLogicTask; import org.apache.beehive.test.tools.tch.core.test.ResultHandler; import org.apache.beehive.test.tools.tch.extension.exectask.common.ResultLogger; +//import org.apache.beehive.test.tools.tch.extension.exectask.common.ResultHelper; +//import org.apache.beehive.test.tools.tch.util.TchConstants; /** * @author [EMAIL PROTECTED] @@ -25,21 +26,23 @@ private String _sTestname = null; private String _sUrl = null; private int _iHash; - private long _lBar; + private float _fBar; private float _fDrift; private long _lTimeout; private ResultLogger _logger; + private ResultHandler _resultHandler; public WebPerfRunner(ResultHandler inResultHandler) { super("WebPerfRunner",inResultHandler); + _resultHandler = inResultHandler; } public void init(String p_sTestname, String p_sUrl, int p_iHash, - long p_lBar, + float p_fBar, float p_fDrift, long p_lTimeout) { @@ -47,7 +50,7 @@ this._sTestname = p_sTestname; this._sUrl = p_sUrl; this._iHash = p_iHash; - this._lBar = p_lBar; + this._fBar = p_fBar; this._fDrift = p_fDrift; this._lTimeout = p_lTimeout; this._logger = this.getResultLogger(); @@ -61,44 +64,7 @@ try { // run the url report - if(!urlreport.assertReport()) - { - _logger.failure("test failed!"); - return null; - } - - float actualDrift = ((urlreport.getTime()-_lBar)/_lBar); - - // log the test result from UrlReport - _logger.inform("allowed hash="+_iHash); - _logger.inform("actual hash="+urlreport.getHash()); - _logger.inform("----------"); - _logger.inform("allowed time="+_lBar); - _logger.inform("actual time="+urlreport.getTime()); - _logger.inform("----------"); - _logger.inform("allowed drift (abs)="+_fDrift); - _logger.inform("actual drift="+actualDrift); - - // log result for processing into perf-result - _logger.inform("\nTEST: "+_sTestname+" time "+urlreport.getTime()+" hash "+urlreport.getHash()); - - // evaluate the result - if(urlreport.getHash() != _iHash) - { - _logger.failure("HASH ERROR"); - } - else if(Math.abs(actualDrift) > _fDrift) - { - if(actualDrift < 0){ - _logger.failure("PERF IMPROVED - QA NEEDS TO RESET THE BAR"); - } - else{ - _logger.failure("PERF REGRESSION BEYOND ALLOWED DRIFT"); - } - } - else{ - _logger.success("PASS"); - } + urlreport.assertReport(); } catch(Throwable e){ _logger.failure("got throwable:"+e.getMessage()); @@ -107,6 +73,7 @@ { _logger.inform(stack[i].toString()); } + _logger.abort("URL Report threw Throwable: "+e.getMessage(),"",e,e); return null; } return null; @@ -116,8 +83,10 @@ private class UrlReport { private String _url = null; - private int _actualHash = -1; - private long _actualTime = -1; + long lActualTime = -1; + long lActualMemory = -1; + float fActualDrift = -1; + int iActualHash = -1; UrlReport(String p_url) { @@ -128,6 +97,8 @@ { WebConversation wc = new WebConversation(); WebResponse wr = wc.getResponse(_url); + + //_logger.debug("WEB RESPONSE IS:\n"+wr.getText()); if(wr.getResponseCode() != 200) { @@ -141,6 +112,7 @@ String message = null; String exception = null; + WebTable wt = wr.getTableWithID(Report.RESULT_TABLE_ID); if(null == wt) { @@ -167,41 +139,115 @@ if (null != exception && ! exception.equals("")) _logger.failure("FAIL - Exception: " + exception); - - // initialize hash, time + + // grab the test result from stdout StringTokenizer st = new StringTokenizer(message," "); - while(st.hasMoreTokens()) - { - String current = st.nextToken(); - if(current.startsWith("hash=")) + while(st.hasMoreTokens()){ + String sCurrent = st.nextToken(); + + if(sCurrent.indexOf("time") == 0 && sCurrent.length() == "time".length()) + { + lActualTime = Long.parseLong(st.nextToken().trim()); + } + if(sCurrent.indexOf("memory") == 0 && sCurrent.length() == "memory".length()) { - StringTokenizer st2 = new StringTokenizer(current,"="); - st2.nextToken(); - _actualHash = Integer.parseInt(st2.nextToken()); + lActualMemory = Long.parseLong(st.nextToken().trim()); } - else if(current.startsWith("time=")) + else if(sCurrent.indexOf("hash") == 0 && sCurrent.length() == "hash".length()) { - StringTokenizer st2 = new StringTokenizer(current,"="); - st2.nextToken(); - _actualTime = Long.parseLong(st2.nextToken()); + iActualHash = Integer.parseInt(st.nextToken().trim()); } } - // Check the status and report accordingly - if (! status.equals(Report.PASS)) - return false; + // calculate the drift for time (or memory if time isn't given) + if(-1 != lActualTime) + { + fActualDrift = ((lActualTime - _fBar)/_fBar); + } + else if(-1 != lActualMemory) + { + fActualDrift = ((lActualMemory - _fBar)/_fBar); + } + + + // log the test result + String perfResultFormat = "\n"+Constants.DELIM+_sTestname+" hash "+iActualHash+" "; + _logger.inform("----------"); + _logger.inform("allowed hash="+_iHash); + _logger.inform("actual hash="+iActualHash); + _logger.inform("----------"); + + if(-1 != lActualTime && -1 != lActualMemory) + { + _logger.inform("allowed time="+_fBar); + _logger.inform("actual time="+lActualTime); + _logger.inform("actual memory="+lActualMemory); + _logger.inform("----------"); + perfResultFormat += "time "+lActualTime+" memory "+lActualMemory; + } + else if(-1 != lActualMemory && -1 == lActualTime) + { + _logger.inform("allowed memory="+_fBar); + _logger.inform("actual memory="+lActualMemory); + _logger.inform("----------"); + perfResultFormat += " memory "+lActualMemory; + } + else if(-1 != lActualTime) + { + _logger.inform("allowed time="+_fBar); + _logger.inform("actual time="+lActualTime); + _logger.inform("----------"); + perfResultFormat += "time "+lActualTime; + } else + { + _logger.inform("ERROR: neither time nor memory are set"); + _logger.inform("----------"); + } + + _logger.inform("allowed drift (abs)="+_fDrift); + _logger.inform("actual drift="+fActualDrift); + _logger.inform("----------"); + _logger.inform(perfResultFormat); + + // evaluate the result + if(iActualHash != _iHash) + { + _logger.failure("HASH ERROR"); + _logger.inform("message:\n"+message); + } + else if(Math.abs(fActualDrift) > _fDrift) + { + if(fActualDrift < 0){ + _logger.failure("PERF IMPROVED - QA NEEDS TO RESET THE BAR"); + return false; + } + else{ + _logger.failure("PERF REGRESSION BEYOND ALLOWED DRIFT"); + return false; + } + } + else{ + _logger.success("PASS"); return true; + } + + return false; } - long getTime() + float getTime() + { + return lActualTime; + } + + float getMemory() { - return _actualTime; + return lActualMemory; } int getHash() { - return _actualHash; + return iActualHash; } } Modified: incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/utils/Constants.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/utils/Constants.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/utils/Constants.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/utils/Constants.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/utils/Constants.java (original) +++ incubator/beehive/trunk/controls/test/perf/src/org/apache/beehive/controls/perf/utils/Constants.java Tue Jan 25 13:57:30 2005 @@ -13,4 +13,6 @@ public static final int VARRET_ITERATIONS = 10000; public static final int[] DEFAULT_VARRET_PARAMS = new int[]{100,200,400,800,1600,3200}; + + public static final String DELIM = "TEST: "; } Modified: incubator/beehive/trunk/controls/test/perf/webapps/build.xml Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/build.xml?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/build.xml&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/build.xml&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/build.xml (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/build.xml Tue Jan 25 13:57:30 2005 @@ -14,7 +14,6 @@ <project name="Beehive/Controls/Perf-webapp" default="usage" basedir="."> <import file="../../../../beehive-imports.xml"/> - <property file="${beehive.home}/controls/test/common/path.properties"/> <property name="controls.perf.root" value="${beehive.home}/controls/test/perf"/> @@ -56,13 +55,9 @@ <echo message="-----------------------------------------------------"/> <echo message="| ${webapp.name} build starting |"/> <echo message="-----------------------------------------------------"/> + <antcall target="${webapp.name}.stage"/> - <deploy-netui webappDir="${webapp.stage.dir}/${webapp.name}"/> - - <!-- TODO: remove this copy once milton.jar is not deleted by the updeploy.netui call --> - <!--copy file="${beehive.dir}/controls/test/infra/milton/milton.jar" todir="${webapp.name}/WEB-INF/lib"/--> - <build-webapp webappDir="${webapp.stage.dir}/${webapp.name}"/> <echo message="----------------------------------------------"/> @@ -71,7 +66,7 @@ </target> <!-- staging targets --> - <target name="controlsPerfWeb.stage" depends="clean"> + <target name="controlsPerfWeb.stage"> <copy todir="${webapp.stage.dir}/${webapp.name}"> <fileset dir="${webapp.dir}"/> </copy> @@ -85,16 +80,20 @@ <copy file="${controls.perf.root}/build/lib/controlperf.jar" todir="${webapp.stage.dir}/${webapp.name}/WEB-INF/lib"/> </target> - <target name="reportWeb.stage" depends="clean"> + <target name="reportWeb.stage" if="reportweb.properties.exists" depends="check.reportweb.properties"> + + <echo message="XMLBEANS REPORTS: xmlbeans.report.dir=${xmlbeans.report.dir}"/> + <echo message="BEEHIVE REPORTS: beehive.report.dir=${beehive.report.dir}"/> + <copy todir="${webapp.stage.dir}/${webapp.name}"> <fileset dir="${webapp.dir}"/> </copy> <!-- inject stuff --> - <ant antfile="${controls.test.dir}/webapps/build.xml" target="-inject.milton" inheritAll="false"> - <property name="webapp.dir" location="${webapp.stage.dir}/${webapp.name}"/> - <property name="do.inject.milton" value="true"/> - </ant> + <ant antfile="${controls.test.dir}/webapps/build.xml" target="-inject.milton" inheritAll="false"> + <property name="webapp.dir" location="${webapp.stage.dir}/${webapp.name}"/> + <property name="do.inject.milton" value="true"/> + </ant> <copy todir="${webapp.stage.dir}/${webapp.name}/WEB-INF/lib"> <fileset dir="${controls.perf.root}/external/cewolf-0.9.8/lib"> <exclude name="servlet.jar"/> @@ -102,15 +101,27 @@ </copy> <copy file="${controls.perf.root}/external/perf-results.jar" todir="${webapp.stage.dir}/${webapp.name}/WEB-INF/lib"/> <copy file="${controls.perf.root}/ctlbuild/lib/customcontrols.jar" todir="${webapp.stage.dir}/${webapp.name}/WEB-INF/lib"/> - <copy file="${webapp.dir}/jpf/controller.properties" todir="${webapp.stage.dir}/${webapp.name}/WEB-INF/classes/jpf"/> + + <!-- these must be provided at build time for the machine's localations --> + <copy file="${basedir}/reportweb.properties" todir="${webapp.stage.dir}/${webapp.name}/jpf/" overwrite="true"/> </target> + <target name="check.reportweb.properties"> + <echo message="MAKE SURE TO SET xmlbeans.report.dir AND beehive.report.dir in reportweb.properties"/> + <property file="${basedir}/reportweb.properties"/> + <available property="reportweb.properties.exists" + file="${basedir}/reportweb.properties" type="file"/> + </target> + + + + <target name="clean" description="Clean webapp"> <echo message="----------------------------------------------"/> <echo message="| ${webapp.name} clean starting |"/> <echo message="----------------------------------------------"/> - <build-webapp webappDir="${webapp.stage.dir}/${webapp.name}"/> + <clean-webapp webappDir="${webapp.stage.dir}/${webapp.name}"/> <delete dir="${webapp.stage.dir}/${webapp.name}"/> Modified: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/dproxy/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -40,7 +40,7 @@ public class Controller extends PageFlowController { private Report _report = new Report(); - private static Logger logger = Logger.getRootLogger(); + private transient Logger logger = Logger.getRootLogger(); @Jpf.Action() protected Forward begin() @@ -48,7 +48,7 @@ BasicConfigurator.configure(); try { - log("TEST: StrlenDproxyJpfTest"); + log(Constants.DELIM+"StrlenDproxyJpfTest"); final int iterations = Constants.STRLEN_ITERATIONS; PerfUtil util = new PerfUtil(); String input = util.createString(Constants.DEFAULT_STR_SIZE); @@ -76,8 +76,8 @@ cputime = System.currentTimeMillis() - cputime; // log the results - log("hash="+hash); - log("time="+cputime); + log("hash "+hash); + log("time "+cputime); _report.setStatus(Report.PASS); } catch(Exception e) @@ -86,6 +86,7 @@ _report.setExceptionStack(e); } + logger = null; return new Forward(Report.RESULTS, Report.KEY, _report); } Modified: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javabean/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -38,7 +38,7 @@ public class Controller extends PageFlowController { private Report _report = new Report(); - private static Logger logger = Logger.getRootLogger(); + private transient Logger logger = Logger.getRootLogger(); @Jpf.Action() protected Forward begin() @@ -71,8 +71,8 @@ cputime = System.currentTimeMillis() - cputime; // log the results - log("hash="+hash); - log("time="+cputime); + log("hash "+hash); + log("time "+cputime); _report.setStatus(Report.PASS); } catch(Exception e) @@ -81,6 +81,7 @@ _report.setExceptionStack(e); } + logger = null; return new Forward(Report.RESULTS, Report.KEY, _report); } Modified: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/javaclass/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -38,7 +38,7 @@ public class Controller extends PageFlowController { private Report _report = new Report(); - private static Logger logger = Logger.getRootLogger(); + private transient Logger logger = Logger.getRootLogger(); @Jpf.Action() protected Forward begin() @@ -71,8 +71,8 @@ cputime = System.currentTimeMillis() - cputime; // log the results - log("hash="+hash); - log("time="+cputime); + log("hash "+hash); + log("time "+cputime); _report.setStatus(Report.PASS); } catch(Exception e) @@ -80,7 +80,7 @@ _report.setStatus(Report.FAIL); _report.setExceptionStack(e); } - + logger = null; return new Forward(Report.RESULTS, Report.KEY, _report); } Modified: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/benchmarks/strlen/methodinv/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -17,83 +17,84 @@ */ package jpf.test.controls.performance.benchmarks.strlen.methodinv; -// for logging +//for logging import org.apache.log4j.Logger; import org.apache.log4j.Level; import org.apache.log4j.BasicConfigurator; -// netui +//netui import org.apache.beehive.netui.pageflow.PageFlowController; import org.apache.beehive.netui.pageflow.Forward; import org.apache.beehive.netui.pageflow.annotations.Jpf; import org.apache.beehive.test.tools.milton.common.Report; -// perf imports +//perf imports import java.lang.reflect.Method; import org.apache.beehive.controls.perf.benchmarks.CStrlen; import org.apache.beehive.controls.perf.utils.Constants; import org.apache.beehive.controls.perf.utils.PerfUtil; @Jpf.Controller( - forwards = { - @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) - }) -public class Controller extends PageFlowController -{ - private Report _report = new Report(); - private static Logger logger = Logger.getRootLogger(); - - @Jpf.Action() - protected Forward begin() - { - BasicConfigurator.configure(); + forwards = { + @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) + }) + public class Controller extends PageFlowController + { + private Report _report = new Report(); + private transient Logger logger = Logger.getRootLogger(); + + @Jpf.Action() + protected Forward begin() + { + BasicConfigurator.configure(); try { - log("TEST: StrlenMethodinvJpfTest"); - final int iterations = Constants.STRLEN_ITERATIONS; - PerfUtil util = new PerfUtil(); - String input = util.createString(Constants.DEFAULT_STR_SIZE); - long cputime; - int hash = 0; - - // instantiate the method to be used for the test - Method method = CStrlen.class.getMethod("stringLength",new Class[]{String.class}); - - // warm up the vm - cputime = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - hash += run(input, method); - } - cputime = System.currentTimeMillis() - cputime; - - // run it again for the real measurement - cputime = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - hash += run(input, method); - } - cputime = System.currentTimeMillis() - cputime; - - // log the results - log("hash="+hash); - log("time="+cputime); + log("TEST: StrlenMethodinvJpfTest"); + final int iterations = Constants.STRLEN_ITERATIONS; + PerfUtil util = new PerfUtil(); + String input = util.createString(Constants.DEFAULT_STR_SIZE); + long cputime; + int hash = 0; + + // instantiate the method to be used for the test + Method method = CStrlen.class.getMethod("stringLength",new Class[]{String.class}); + + // warm up the vm + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, method); + } + cputime = System.currentTimeMillis() - cputime; + + // run it again for the real measurement + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, method); + } + cputime = System.currentTimeMillis() - cputime; + + // log the results + log("hash "+hash); + log("time "+cputime); _report.setStatus(Report.PASS); - } - catch(Exception e) + } + catch(Exception e) { _report.setStatus(Report.FAIL); _report.setExceptionStack(e); - } - - return new Forward(Report.RESULTS, Report.KEY, _report); - } - - private int run(String p_input, Method p_method) throws Exception - { - Object oResult = p_method.invoke(CStrlen.class.newInstance(),(Object)p_input); - return ( (Integer)oResult ).intValue(); - } - - private void log(String message) - { - logger.info("PERF "+message); - _report.addMessage(message); - } -} + } + + logger = null; + return new Forward(Report.RESULTS, Report.KEY, _report); + } + + private int run(String p_input, Method p_method) throws Exception + { + Object oResult = p_method.invoke(CStrlen.class.newInstance(),(Object)p_input); + return ( (Integer)oResult ).intValue(); + } + + private void log(String message) + { + logger.info("PERF "+message); + _report.addMessage(message); + } + } Modified: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlen/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -17,7 +17,7 @@ */ package jpf.test.controls.performance.programmatic.strlen; -// for logging +//for logging import org.apache.log4j.Logger; import org.apache.log4j.Level; import org.apache.log4j.BasicConfigurator; @@ -26,76 +26,77 @@ import org.apache.beehive.netui.pageflow.Forward; import org.apache.beehive.netui.pageflow.annotations.Jpf; import org.apache.beehive.test.tools.milton.common.Report; -// perf imports +//perf imports import org.apache.beehive.controls.perf.controls.custom.StrlenControlBean; import org.apache.beehive.controls.perf.utils.Constants; import org.apache.beehive.controls.perf.utils.PerfUtil; @Jpf.Controller( - forwards = { - @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) - }) -public class Controller extends PageFlowController -{ - private Report _report = new Report(); - private static Logger logger = Logger.getRootLogger(); - - @Jpf.Action() - protected Forward begin() - { - BasicConfigurator.configure(); + forwards = { + @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) + }) + public class Controller extends PageFlowController + { + private Report _report = new Report(); + private transient Logger logger = Logger.getRootLogger(); + + @Jpf.Action() + protected Forward begin() + { + BasicConfigurator.configure(); try { - // instantiate the control - StrlenControlBean control =(StrlenControlBean)java.beans.Beans.instantiate( - Thread.currentThread().getContextClassLoader(), - "org.apache.beehive.controls.perf.controls.custom.StrlenControlBean"); - - final int iterations = Constants.STRLEN_ITERATIONS; - PerfUtil util = new PerfUtil(); - String input = util.createString(Constants.DEFAULT_STR_SIZE); - - log("TEST: StrlenPgmJpfTest"); - long cputime; - int hash = 0; - - // warm up the vm - cputime = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - hash += run(input, control); - } - cputime = System.currentTimeMillis() - cputime; - - // run it again for the real measurement - cputime = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - hash += run(input, control); - } - cputime = System.currentTimeMillis() - cputime; - - // log the results - log("hash="+hash); - log("time="+cputime); + // instantiate the control + StrlenControlBean control =(StrlenControlBean)java.beans.Beans.instantiate( + Thread.currentThread().getContextClassLoader(), + "org.apache.beehive.controls.perf.controls.custom.StrlenControlBean"); + + final int iterations = Constants.STRLEN_ITERATIONS; + PerfUtil util = new PerfUtil(); + String input = util.createString(Constants.DEFAULT_STR_SIZE); + + log("TEST: StrlenPgmJpfTest"); + long cputime; + int hash = 0; + + // warm up the vm + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, control); + } + cputime = System.currentTimeMillis() - cputime; + + // run it again for the real measurement + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, control); + } + cputime = System.currentTimeMillis() - cputime; + + // log the results + log("hash "+hash); + log("time "+cputime); _report.setStatus(Report.PASS); - } - catch(Exception e) + } + catch(Exception e) { _report.setStatus(Report.FAIL); _report.setExceptionStack(e); - } - - return new Forward(Report.RESULTS, Report.KEY, _report); - } - - - private int run(String p_input, StrlenControlBean p_control) - { - return p_control.stringLength(p_input); - } - - private void log(String message) - { - logger.info("PERF "+message); - _report.addMessage(message); - } -} + } + + logger = null; + return new Forward(Report.RESULTS, Report.KEY, _report); + } + + + private int run(String p_input, StrlenControlBean p_control) + { + return p_control.stringLength(p_input); + } + + private void log(String message) + { + logger.info("PERF "+message); + _report.addMessage(message); + } + } Added: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlenST/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlenST/Controller.jpf?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/strlenST/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -0,0 +1,102 @@ +/* + * + * N E T U I + * + * Copyright 2004 The Apache Software Foundation. + * + * All Rights Reserved. Unpublished rights reserved under the copyright laws + * of the United States. The software contained on this media is proprietary + * to and embodies the confidential technology of BEA Systems, Inc. The + * possession or receipt of this information does not convey any right to + * disclose its contents, reproduce it, or use, or license the use, + * for manufacture or sale, the information or anything described + * therein. Any use, disclosure, or reproduction without BEA System's + * prior written permission is strictly prohibited. + * + * $Header:$ + */ +package jpf.test.controls.performance.programmatic.strlenST; + +//for logging +import org.apache.log4j.Logger; +import org.apache.log4j.Level; +import org.apache.log4j.BasicConfigurator; + +import org.apache.beehive.netui.pageflow.PageFlowController; +import org.apache.beehive.netui.pageflow.Forward; +import org.apache.beehive.netui.pageflow.annotations.Jpf; +import org.apache.beehive.test.tools.milton.common.Report; +//perf imports +import org.apache.beehive.controls.perf.controls.custom.StrlenControlSTBean; +import org.apache.beehive.controls.perf.utils.Constants; +import org.apache.beehive.controls.perf.utils.PerfUtil; + [EMAIL PROTECTED]( + forwards = { + @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) + }) + public class Controller extends PageFlowController + { + private Report _report = new Report(); + private transient Logger logger = Logger.getRootLogger(); + + @Jpf.Action() + protected Forward begin() + { + BasicConfigurator.configure(); + try + { + // instantiate the control + StrlenControlSTBean control =(StrlenControlSTBean)java.beans.Beans.instantiate( + Thread.currentThread().getContextClassLoader(), + "org.apache.beehive.controls.perf.controls.custom.StrlenControlSTBean"); + + final int iterations = Constants.STRLEN_ITERATIONS; + PerfUtil util = new PerfUtil(); + String input = util.createString(Constants.DEFAULT_STR_SIZE); + + log("TEST: StrlenSTPgmJpfTest"); + long cputime; + int hash = 0; + + // warm up the vm + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, control); + } + cputime = System.currentTimeMillis() - cputime; + + // run it again for the real measurement + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, control); + } + cputime = System.currentTimeMillis() - cputime; + + // log the results + log("hash "+hash); + log("time "+cputime); + _report.setStatus(Report.PASS); + } + catch(Exception e) + { + _report.setStatus(Report.FAIL); + _report.setExceptionStack(e); + } + + logger = null; + return new Forward(Report.RESULTS, Report.KEY, _report); + } + + + private int run(String p_input, StrlenControlSTBean p_control) + { + return p_control.stringLength(p_input); + } + + private void log(String message) + { + logger.info("PERF "+message); + _report.addMessage(message); + } + } Modified: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varargs/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -17,118 +17,119 @@ */ package jpf.test.controls.performance.programmatic.varargs; -// for logging +//for logging import org.apache.log4j.Logger; import org.apache.log4j.Level; import org.apache.log4j.BasicConfigurator; -// for netui +//for netui import org.apache.beehive.netui.pageflow.PageFlowController; import org.apache.beehive.netui.pageflow.Forward; import org.apache.beehive.netui.pageflow.annotations.Jpf; -// milton +//milton import org.apache.beehive.test.tools.milton.common.Report; -// perf imports +//perf imports import org.apache.beehive.controls.perf.controls.custom.VarargsControlBean; import org.apache.beehive.controls.perf.utils.Constants; import org.apache.beehive.controls.perf.utils.PerfUtil; @Jpf.Controller( - forwards = { - @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) - }) -public class Controller extends PageFlowController -{ - private Report _report = new Report(); - private static Logger logger = Logger.getRootLogger(); - - @Jpf.Action() - protected Forward begin() - { - BasicConfigurator.configure(); + forwards = { + @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) + }) + public class Controller extends PageFlowController + { + private Report _report = new Report(); + private transient Logger logger = Logger.getRootLogger(); + + @Jpf.Action() + protected Forward begin() + { + BasicConfigurator.configure(); try { - // instantiate the control programmatically - VarargsControlBean control =(VarargsControlBean)java.beans.Beans.instantiate( - Thread.currentThread().getContextClassLoader(), - "org.apache.beehive.controls.perf.controls.custom.VarargsControlBean"); - - final int iterations = Constants.VARARGS_ITERATIONS; - PerfUtil util = new PerfUtil(); - int[] input = util.createIntArray(Constants.DEFAULT_VARARG_PARAMS[Constants.DEFAULT_VARARG_PARAMS.length-1]); - - log("TEST: VarargsPgmJpfTest"); - long cputime; - int hash = 0; - - // warm up the vm with the largest array input - cputime = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - hash += run(input, control); - } - cputime = System.currentTimeMillis() - cputime; - - // loop through the various sizes for the inputed int array - int sum = 0; - long duration = 0; - cputime = 0; - for(int j=0; j<Constants.DEFAULT_VARARG_PARAMS.length; j++) - { - input = util.createIntArray(Constants.DEFAULT_VARARG_PARAMS[j]); - sum = 0; - // run it for the measurement - duration = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - hash += run(input, control); - } - duration = System.currentTimeMillis() - duration; - - // log the results for this input - log("array size="+input.length); - log("expected sum="+expectedSum(input)); - log("actual sum="+sum); - log("duration="+duration); - - // update the overall result - hash += sum; - cputime += duration; - } - - // log the overall result - log("hash="+hash); - log("time="+cputime); - + // instantiate the control programmatically + VarargsControlBean control =(VarargsControlBean)java.beans.Beans.instantiate( + Thread.currentThread().getContextClassLoader(), + "org.apache.beehive.controls.perf.controls.custom.VarargsControlBean"); + + final int iterations = Constants.VARARGS_ITERATIONS; + PerfUtil util = new PerfUtil(); + int[] input = util.createIntArray(Constants.DEFAULT_VARARG_PARAMS[Constants.DEFAULT_VARARG_PARAMS.length-1]); + + log("TEST: VarargsPgmJpfTest"); + long cputime; + int hash = 0; + + // warm up the vm with the largest array input + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, control); + } + cputime = System.currentTimeMillis() - cputime; + + // loop through the various sizes for the inputed int array + int sum = 0; + long duration = 0; + cputime = 0; + for(int j=0; j<Constants.DEFAULT_VARARG_PARAMS.length; j++) + { + input = util.createIntArray(Constants.DEFAULT_VARARG_PARAMS[j]); + sum = 0; + // run it for the measurement + duration = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input, control); + } + duration = System.currentTimeMillis() - duration; + + // log the results for this input + log("array_size"+j+"="+input.length); + log("expected_sum"+j+"="+expectedSum(input)); + log("actual_sum"+j+"="+sum); + log("duration"+j+"="+duration+" "); + + // update the overall result + hash += sum; + cputime += duration; + } + + // log the overall result + log("hash "+hash); + log("time "+cputime); + _report.setStatus(Report.PASS); - } - catch(Exception e) + } + catch(Exception e) { _report.setStatus(Report.FAIL); _report.setExceptionStack(e); - } - - return new Forward(Report.RESULTS, Report.KEY, _report); - } - - - private int run(int[] p_input, VarargsControlBean p_control) - { - return p_control.getIntSum(p_input); - } - - private static int expectedSum(int[] p_intArray) - { - int result = 0; - for(int i : p_intArray) - { - result += i; - } - - result = Constants.VARARGS_ITERATIONS*result; - return result; - } - - private void log(String message) - { - logger.info("PERF "+message); - _report.addMessage(message); - } -} + } + + logger = null; + return new Forward(Report.RESULTS, Report.KEY, _report); + } + + + private int run(int[] p_input, VarargsControlBean p_control) + { + return p_control.getIntSum(p_input); + } + + private static int expectedSum(int[] p_intArray) + { + int result = 0; + for(int i : p_intArray) + { + result += i; + } + + result = Constants.VARARGS_ITERATIONS*result; + return result; + } + + private void log(String message) + { + logger.info("PERF "+message); + _report.addMessage(message); + } + } Modified: incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/controlsPerfWeb/jpf/test/controls/performance/programmatic/varret/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -17,102 +17,102 @@ */ package jpf.test.controls.performance.programmatic.varret; -// for logging +//for logging import org.apache.log4j.Logger; import org.apache.log4j.Level; import org.apache.log4j.BasicConfigurator; -// for netui +//for netui import org.apache.beehive.netui.pageflow.PageFlowController; import org.apache.beehive.netui.pageflow.Forward; import org.apache.beehive.netui.pageflow.annotations.Jpf; -// milton +//milton import org.apache.beehive.test.tools.milton.common.Report; -// perf imports +//perf imports import org.apache.beehive.controls.perf.controls.custom.VarretControlBean; import org.apache.beehive.controls.perf.utils.Constants; import org.apache.beehive.controls.perf.utils.PerfUtil; @Jpf.Controller( - forwards = { - @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) - }) -public class Controller extends PageFlowController -{ - private Report _report = new Report(); - private static Logger logger = Logger.getRootLogger(); - - @Jpf.Action() - protected Forward begin() - { - BasicConfigurator.configure(); + forwards = { + @Jpf.Forward(name=Report.RESULTS, path = Report.RESULTSJSP) + }) + public class Controller extends PageFlowController + { + private Report _report = new Report(); + private transient Logger logger = Logger.getRootLogger(); + + @Jpf.Action() + protected Forward begin() + { + BasicConfigurator.configure(); try { - // instantiate the control programmatically - VarretControlBean control =(VarretControlBean)java.beans.Beans.instantiate( - Thread.currentThread().getContextClassLoader(), - "org.apache.beehive.controls.perf.controls.custom.VarretControlBean"); - - final int iterations = Constants.VARRET_ITERATIONS; - int[] input = Constants.DEFAULT_VARRET_PARAMS; - - log("TEST: VarretPgmJpfTest"); - long cputime; - int hash = 0; - - // warm up the vm with the largest array input - cputime = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - hash += run(input[input.length-1], control).length(); - } - cputime = System.currentTimeMillis() - cputime; - - // loop through the various sizes for the inputed int - long duration = 0; - int length = 0; - cputime = 0; - for(int j=0; j<Constants.DEFAULT_VARRET_PARAMS.length; j++) - { - length = 0; - // run it for the measurement - duration = System.currentTimeMillis(); - for(int i=0; i<iterations; i++){ - length += run(input[j], control).length(); - } - duration = System.currentTimeMillis() - duration; - - // log the results for this input - log("int input="+input[j]); - log("length sum="+length); - log("duration="+duration+"\n"); - - // update the overall result - hash += length; - cputime += duration; - } - - log("hash="+hash); - log("time="+cputime); - + // instantiate the control programmatically + VarretControlBean control =(VarretControlBean)java.beans.Beans.instantiate( + Thread.currentThread().getContextClassLoader(), + "org.apache.beehive.controls.perf.controls.custom.VarretControlBean"); + + final int iterations = Constants.VARRET_ITERATIONS; + int[] input = Constants.DEFAULT_VARRET_PARAMS; + + log("TEST: VarretPgmJpfTest"); + long cputime; + int hash = 0; + + // warm up the vm with the largest array input + cputime = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + hash += run(input[input.length-1], control).length(); + } + cputime = System.currentTimeMillis() - cputime; + + // loop through the various sizes for the inputed int + long duration = 0; + int length = 0; + cputime = 0; + for(int j=0; j<Constants.DEFAULT_VARRET_PARAMS.length; j++) + { + length = 0; + // run it for the measurement + duration = System.currentTimeMillis(); + for(int i=0; i<iterations; i++){ + length += run(input[j], control).length(); + } + duration = System.currentTimeMillis() - duration; + + // log the results for this input + log("int_input"+j+"="+input[j]); + log("length_sum"+j+"="+length); + log("duration"+j+"="+duration+" "); + + // update the overall result + hash += length; + cputime += duration; + } + + log("hash "+hash); + log("time "+cputime); + _report.setStatus(Report.PASS); - } - catch(Exception e) + } + catch(Exception e) { _report.setStatus(Report.FAIL); _report.setExceptionStack(e); - } - - return new Forward(Report.RESULTS, Report.KEY, _report); - } - - - private String run(int p_input, VarretControlBean p_control) - { - return (p_control.createString(p_input)); - } - - private void log(String message) - { - logger.info("PERF "+message); - _report.addMessage(message); - } -} + } + logger = null; + return new Forward(Report.RESULTS, Report.KEY, _report); + } + + + private String run(int p_input, VarretControlBean p_control) + { + return (p_control.createString(p_input)); + } + + private void log(String message) + { + logger.info("PERF "+message); + _report.addMessage(message); + } + } Modified: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ControlsForm.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ControlsForm.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ControlsForm.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ControlsForm.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ControlsForm.java (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ControlsForm.java Tue Jan 25 13:57:30 2005 @@ -1,4 +1,4 @@ -package jpf.forms; +package forms; public class ControlsForm { Modified: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ReportForm.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ReportForm.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ReportForm.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ReportForm.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ReportForm.java (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/ReportForm.java Tue Jan 25 13:57:30 2005 @@ -1,10 +1,14 @@ -package jpf.forms; +package forms; public class ReportForm { public String filename; public String regex; - public String xvals; - public String yvals; + public String xaxis; + public String xlabel; + public String yaxis; + public String ylabel; public String type; + public String width; + public String height; } Modified: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/XmlbeansForm.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/XmlbeansForm.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/XmlbeansForm.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/XmlbeansForm.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/XmlbeansForm.java (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/forms/XmlbeansForm.java Tue Jan 25 13:57:30 2005 @@ -1,4 +1,4 @@ -package jpf.forms; +package forms; public class XmlbeansForm { Modified: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/graphing/SnapshotProducer.java Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/graphing/SnapshotProducer.java?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/graphing/SnapshotProducer.java&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/graphing/SnapshotProducer.java&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/graphing/SnapshotProducer.java (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/WEB-INF/src/graphing/SnapshotProducer.java Tue Jan 25 13:57:30 2005 @@ -38,10 +38,18 @@ // keys used to retreive params passed from the jsp form String k_regex = "regex"; String k_filename = "filename"; + String k_xaxis = "xaxis"; + String k_yaxis = "yaxis"; + // retreive the param values String regex = (String)params.get((Object)k_regex); String filename = (String)params.get((Object)k_filename); + String xaxis = (String)params.get((Object)k_xaxis); + String yaxis = (String)params.get((Object)k_yaxis); ResultSetDocument.ResultSet resultset = null; + if(null == yaxis) yaxis = "time"; + if(null == xaxis) xaxis = "name"; + try{ ResultSetDocument doc = ResultSetDocument.Factory.parse(new File(filename)); resultset = doc.getResultSet(); @@ -60,9 +68,7 @@ else System.out.println("resutls are null :-("); - DefaultCategoryDataset dataset = new DefaultCategoryDataset(); - - + DefaultCategoryDataset dataset = new DefaultCategoryDataset(); // loop through results and populate the data set Result[] results = resultset.getResultArray(); for(int i=0; i<results.length; i++) @@ -80,22 +86,51 @@ if(name.matches(regex)) - { - - if(results[i].isSetTime()) + { + if(yaxis.equalsIgnoreCase("time") && results[i].isSetTime()) + { + System.out.println("adding y-axis time data for test: "+name); + if(xaxis.equalsIgnoreCase("name") || + null == getCustomValue(xaxis,results[i])) + dataset.addValue( (Number) results[i].getTime(), name, "scenarios"); + else + { + Float xvalue = Float.parseFloat(getCustomValue(xaxis,results[i])); + dataset.addValue( (Number) results[i].getTime(), xvalue, "scneraios"); + } + } + else if(yaxis.equalsIgnoreCase("memory") && results[i].isSetMemory()) + { + System.out.println("adding y-axis memory data for test: "+name); + if(null == getCustomValue(xaxis,results[i])) + dataset.addValue( (Number) results[i].getMemory(), name, "scenarios"); + else + { + Float xvalue = Float.parseFloat(getCustomValue(xaxis,results[i])); + dataset.addValue( (Number) results[i].getMemory(), xvalue, "scneraios"); + } + } + else if(xaxis.equalsIgnoreCase("memory") && + results[i].isSetMemory() && + null != getCustomValue(yaxis,results[i])) { - System.out.println("adding time data: "+name); - dataset.addValue( (Number) results[i].getTime(), name, "scenarios"); + System.out.println("adding x-axis memory data for test: "+name); + Float yvalue = Float.parseFloat(getCustomValue(yaxis,results[i])); + dataset.addValue( (Number)yvalue, name+"[mem="+results[i].getMemory()+"]","scenarios"); } - else if(results[i].isSetMemory()) + else if(null != getCustomValue(yaxis,results[i]) && + null != getCustomValue(xaxis,results[i])) { - System.out.println("adding mem data: "+name); - dataset.addValue( (Number) results[i].getMemory(), name, "scenarios"); + System.out.println("adding custom y-axis data ("+yaxis+") for test: "+name); + System.out.println("adding custom x-axis data ("+xaxis+") for test: "+name); + Float yvalue = Float.parseFloat(getCustomValue(yaxis,results[i])); + Float xvalue = Float.parseFloat(getCustomValue(xaxis,results[i])); + dataset.addValue( (Number)yvalue, xvalue, "scenarios"); } else { - System.out.println("ERROR finding data"); - dataset.addValue( (double)500,"UNRECOGNIZED PERF VALUE","UNRECOGNIZED PERF VALUE"); + System.out.println("ERROR finding data for test: "+name); + //dataset.addValue( (double)500,"UNRECOGNIZED PERF VALUE","UNRECOGNIZED PERF VALUE"); } } @@ -113,5 +148,18 @@ public String getProducerId() { return "SnapshotProducer"; + } + + private String getCustomValue(String p_name, Result p_result) + { + Custom[] customs = p_result.getCustomArray(); + for(int i=0; i<customs.length; i++) + { + if(p_name.equalsIgnoreCase(customs[i].getName())) + { + return customs[i].getValue(); + } + } + return null; } } Modified: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/Controller.jpf Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/Controller.jpf?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/Controller.jpf&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/Controller.jpf&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/Controller.jpf (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/Controller.jpf Tue Jan 25 13:57:30 2005 @@ -37,7 +37,7 @@ import org.openuri.perf.*; //report web utils -import jpf.forms.*; +import forms.*; @Jpf.Controller( @@ -45,6 +45,7 @@ @Jpf.Forward(name="index",path="index.jsp"), @Jpf.Forward(name="snapshot",path="snapshot.jsp"), @Jpf.Forward(name="xmlbeans",path="xmlbeans.jsp"), + @Jpf.Forward(name="controls",path="controls.jsp"), @Jpf.Forward(name="error",path="/error.jsp") }) public class Controller extends PageFlowController @@ -100,8 +101,12 @@ getRequest().setAttribute("filename",form.filename); getRequest().setAttribute("regex",form.regex); getRequest().setAttribute("type",form.type); - getRequest().setAttribute("xlabel",form.xvals); - getRequest().setAttribute("ylabel",form.yvals); + getRequest().setAttribute("xaxis",form.xaxis); + getRequest().setAttribute("xlabel",form.xlabel); + getRequest().setAttribute("yaxis",form.yaxis); + getRequest().setAttribute("ylabel",form.ylabel); + getRequest().setAttribute("width",form.width); + getRequest().setAttribute("height",form.height); return new Forward("snapshot"); } @@ -109,47 +114,33 @@ protected Forward xmlbeans(XmlbeansForm form) { initializeProperties(); - // from form - System.out.println("inside xmlbeans()"); - System.out.println("filename="+form.filename); - String filename = form.filename; - - // if no filename given, use the newest - if( (null == filename || filename.equalsIgnoreCase("")) - && _isInited) + System.out.println("REPORTWEB: filename="+form.filename); + String filename = null; + try { - filename = ((PerfResultControlBean)_controls.get("xmlbeans")).getLatestFilename(); + filename = ensureControlInited(form.filename,"xmlbeans"); + System.out.println("REPORTWEB: initialized filname to: "+filename); } - else if((null == filename || filename.equalsIgnoreCase("")) - && !_isInited) + catch(ClassNotFoundException cnfe) { - - try - { - initializeControl(_props.getProperty("xmlbeansdir"),"xmlbeans"); - } - catch(ClassNotFoundException cnfe) - { - Forward f = new Forward("error"); - getRequest().setAttribute("msg", "ClassNotFouncException "+cnfe.getMessage()); - cnfe.printStackTrace(); - return f; - } - catch(XmlException xe) - { - Forward f = new Forward("error"); - getRequest().setAttribute("msg", "XmlException "+xe.getMessage()); - xe.printStackTrace(); - return f; - } - catch(IOException ioe) - { - Forward f = new Forward("error"); - getRequest().setAttribute("msg", "IOException "+ioe.getMessage()); - ioe.printStackTrace(); - return f; - } - filename = ((PerfResultControlBean)_controls.get("xmlbeans")).getLatestFilename(); + Forward f = new Forward("error"); + getRequest().setAttribute("msg", "ClassNotFouncException "+cnfe.getMessage()); + cnfe.printStackTrace(); + return f; + } + catch(XmlException xe) + { + Forward f = new Forward("error"); + getRequest().setAttribute("msg", "XmlException "+xe.getMessage()); + xe.printStackTrace(); + return f; + } + catch(IOException ioe) + { + Forward f = new Forward("error"); + getRequest().setAttribute("msg", "IOException "+ioe.getMessage()); + ioe.printStackTrace(); + return f; } ResultSetDocument.ResultSet resultSet = ((PerfResultControlBean)_controls.get("xmlbeans")).getResultSet(filename); @@ -162,7 +153,7 @@ // TODO: didn't work as of 12/14/2004 getRequest().setAttribute("CursorWalk",".*CursorWalk.*"); getRequest().setAttribute("CursorGetSetGet",".*CursorGet.*"); - getRequest().setAttribute("BisLoad",".*BisLoad.*"); + getRequest().setAttribute("BisLoad",".*.BisLoad.*"); getRequest().setAttribute("DomWalk",".*DomWalk.*"); getRequest().setAttribute("POValidate",".*POValidate.*"); getRequest().setAttribute("POTopDown",".*POTopDown[^Save].*"); @@ -176,15 +167,74 @@ protected Forward controls(ControlsForm form) { initializeProperties(); - getRequest().setAttribute("msg","not yet implemented"); - return new Forward("error"); + System.out.println("REPORTWEB: filename="+form.filename); + String filename = null; + try + { + filename = ensureControlInited(form.filename,"controls"); + if(null == filename) + System.out.println("ERROR: could find given or most recent file"); + } + catch(ClassNotFoundException cnfe) + { + Forward f = new Forward("error"); + getRequest().setAttribute("msg", "ClassNotFouncException "+cnfe.getMessage()); + cnfe.printStackTrace(); + return f; + } + catch(XmlException xe) + { + Forward f = new Forward("error"); + getRequest().setAttribute("msg", "XmlException "+xe.getMessage()); + xe.printStackTrace(); + return f; + } + catch(IOException ioe) + { + Forward f = new Forward("error"); + getRequest().setAttribute("msg", "IOException "+ioe.getMessage()); + ioe.printStackTrace(); + return f; + } + + ResultSetDocument.ResultSet resultSet = ((PerfResultControlBean)_controls.get("controls")).getResultSet(filename); + getRequest().setAttribute("date",resultSet.getEnvironment().getDate().toString()); + getRequest().setAttribute("jvm",resultSet.getEnvironment().getJvm()); + getRequest().setAttribute("os",resultSet.getEnvironment().getOs()); + getRequest().setAttribute("filename",filename); + // set various regexes so the jsp can pass them to the data producer(s) + // TODO: figure out why these strings can't just be in the jsp + // TODO: didn't work as of 12/14/2004 + getRequest().setAttribute("StrlenPgm",".*Strlen.*"); + getRequest().setAttribute("VarargsPgm",".*VarargsPgm.*"); + getRequest().setAttribute("VarretPgm",".*VarretPgm.*"); + return new Forward("controls"); } + + // private utilities private void initializeControl(String p_dir,String p_key) throws XmlException,IOException,ClassNotFoundException { PerfResultControlBean control = (PerfResultControlBean) java.beans.Beans.instantiate(this.getClass().getClassLoader(), "org.apache.beehive.controls.perf.controls.custom.PerfResultControlBean"); - control.loadResults(new File(p_dir)); + File datadir = new File(p_dir); + if (null == datadir) + { + System.out.println("ERROR: could not find data files in dir: "+p_dir); + throw new IOException("ERROR: could not find data files in dir: "+p_dir); + } + else + { + System.out.println("USING data files in dir: "+datadir.getAbsolutePath()); + File[] files = datadir.listFiles(); + if(null == files) System.out.println("ERROR - files is null"); + System.out.println("Number of files in dir: "+files.length); + for(int i=0; i<files.length; i++) + { + System.out.println("File "+i+" = "+files[i].getAbsolutePath()); + } + } + control.loadResults(datadir); _controls.put(p_key,control); } @@ -194,7 +244,7 @@ try { _props = new Properties(); - FileInputStream in = new FileInputStream(getServletContext().getRealPath("/jpf/controller.properties")); + FileInputStream in = new FileInputStream(getServletContext().getRealPath("/jpf/reportweb.properties")); _props.load(in); in.close(); _props.list(System.out); @@ -207,5 +257,23 @@ { ioe.printStackTrace(); } + } + + private String ensureControlInited(String p_filename, String p_controlKey) throws ClassNotFoundException,XmlException,IOException + { + String filenameResult = null; + // if no filename given, use the newest + if( (null == p_filename || p_filename.equalsIgnoreCase("")) + && _isInited) + { + filenameResult = ((PerfResultControlBean)_controls.get(p_controlKey)).getLatestFilename(); + } + else if((null == p_filename || p_filename.equalsIgnoreCase("")) + && !_isInited) + { + initializeControl(_props.getProperty(p_controlKey+"dir"),p_controlKey); + filenameResult = ((PerfResultControlBean)_controls.get(p_controlKey)).getLatestFilename(); + } + return filenameResult; } } Deleted: /incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/controller.properties Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/controller.properties?view=auto&rev=126431 ============================================================================== Added: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/controls.jsp Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/controls.jsp?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/controls.jsp Tue Jan 25 13:57:30 2005 @@ -0,0 +1,78 @@ +<%@ page language="java" contentType="text/html;charset=UTF-8"%> +<%@ taglib uri="http://beehive.apache.org/netui/tags-databinding-1.0" prefix="netui-data"%> +<%@ taglib uri="http://beehive.apache.org/netui/tags-html-1.0" prefix="netui"%> +<%@ taglib uri="http://beehive.apache.org/netui/tags-template-1.0" prefix="netui-template"%> +<[EMAIL PROTECTED] uri='http://cewolf.sourceforge.net/taglib/cewolf.tld' prefix='cewolf' %> + +<netui:html> + <head> + <title>report web</title> + <link rel="stylesheet" type="text/css" href="runtimePerf.css" /> + <meta content="text/html; charset=windows-1252" http-equiv=Content-Type> + </head> + + <netui:body> + + <h3 class=margin>Beehive Controls Runtime Performance</h3> + <p>Date: <netui:label value="${requestScope.date}"/> + <p>JVM: <netui:label value="${requestScope.jvm}"/> + <p>OS: <netui:label value="${requestScope.os}"/> + <p>Filename: <netui:label value="${requestScope.filename}"/> + + <jsp:useBean id="strlenpgm_data" class="graphing.SnapshotProducer"/> + <cewolf:chart + id="StrlenPgm" + title="String Length Custom Control" + type="verticalbar" + xaxislabel="scneario" + yaxislabel="time(ms)"> + <cewolf:data> + <cewolf:producer id="strlenpgm_data"> + <cewolf:param name="filename" value="${requestScope.filename}" /> + <cewolf:param name="regex" value="${requestScope.StrlenPgm}" /> + </cewolf:producer> + </cewolf:data> + </cewolf:chart> + <p> + <cewolf:img chartid="StrlenPgm" renderer="cewolf" width="600" height="400"/> + <P> + + + <jsp:useBean id="varargspgm_data" class="graphing.SnapshotProducer"/> + <cewolf:chart + id="VarargsPgm" + title="Variable Arguments Custom Control" + type="verticalbar" + xaxislabel="scneario" + yaxislabel="time(ms)"> + <cewolf:data> + <cewolf:producer id="varargspgm_data"> + <cewolf:param name="filename" value="${requestScope.filename}" /> + <cewolf:param name="regex" value="${requestScope.VarargsPgm}" /> + </cewolf:producer> + </cewolf:data> + </cewolf:chart> + <p> + <cewolf:img chartid="VarargsPgm" renderer="cewolf" width="600" height="400"/> + <P> + + <jsp:useBean id="varretpgm_data" class="graphing.SnapshotProducer"/> + <cewolf:chart + id="VarretPgm" + title="Variable Return Value Size Custom Control" + type="verticalbar" + xaxislabel="scneario" + yaxislabel="time(ms)"> + <cewolf:data> + <cewolf:producer id="varretpgm_data"> + <cewolf:param name="filename" value="${requestScope.filename}" /> + <cewolf:param name="regex" value="${requestScope.VarretPgm}" /> + </cewolf:producer> + </cewolf:data> + </cewolf:chart> + <p> + <cewolf:img chartid="VarretPgm" renderer="cewolf" width="600" height="400"/> + <P> + + </netui:body> +</netui:html> Modified: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/index.jsp Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/index.jsp?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/index.jsp&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/index.jsp&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/index.jsp (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/index.jsp Tue Jan 25 13:57:30 2005 @@ -14,9 +14,10 @@ PerfResultControlBean xmlbeanResults = (PerfResultControlBean)controls.get("xmlbeans"); PerfResultControlBean controlResults = (PerfResultControlBean)controls.get("controls"); %> + <netui:html> <head> - <title>report web</title> + <title>Runtime Performance Web</title> <link rel="stylesheet" type="text/css" href="../runtimePerf.css" /> <meta content="text/html; charset=windows-1252" http-equiv=Content-Type> </head> @@ -47,7 +48,12 @@ ResultSetDocument.ResultSet xmlbeanResultSet = (ResultSetDocument.ResultSet)xmlbeanResultSets.get((Object)filename); %> <tr> - <td id="RESULT FILENAME"><% out.print(filename); %></td> + <td id="RESULT FILENAME"> + <netui:anchor action="xmlbeans"> + <netui:parameter name="actionForm.filename" value=" <% out.print(filename); %> "/> + <% out.print(filename); %> + </netui:anchor> + </td> <td id="RESULT DATE"><% out.print(xmlbeanResultSet.getEnvironment().getDate()); %></td> <td id="RESULT OS"><% out.print(xmlbeanResultSet.getEnvironment().getOs()); %></td> <td id="RESULT JVM"><% out.print(xmlbeanResultSet.getEnvironment().getJvm()); %></td> @@ -103,20 +109,46 @@ <netui:button value="Submit" type="submit"/> </netui:form> + <h4 class=margin>Custom Series Graph Form</h4> + <netui:form action="snapshot"> + Filename: + <netui:textBox dataSource="actionForm.filename"/> + Regex: + <netui:textBox dataSource="actionForm.regex"/> + X axis label: + <netui:textBox dataSource="actionForm.xlabel"/> + Y axis label: + <netui:textBox dataSource="actionForm.ylabel"/> + Type: + <netui:textBox dataSource="actionForm.type"/> + Width: + <netui:textBox dataSource="actionForm.width"/> + Height: + <netui:textBox dataSource="actionForm.height"/> + <netui:button value="Submit" type="submit"/> + </netui:form> - <h4 class=margin>Custom Graph Form</h4> + <h4 class=margin>Custom Snapshot Graph Form</h4> <netui:form action="snapshot"> Filename: <netui:textBox dataSource="actionForm.filename"/> Regex: <netui:textBox dataSource="actionForm.regex"/> - X axis: - <netui:textBox dataSource="actionForm.xvals"/> - Y axis: - <netui:textBox dataSource="actionForm.yvals"/> + X axis value name: + <netui:textBox dataSource="actionForm.xaxis"/> + X axis label: + <netui:textBox dataSource="actionForm.xlabel"/> + Y axis value name: + <netui:textBox dataSource="actionForm.yaxis"/> + Y axis label: + <netui:textBox dataSource="actionForm.ylabel"/> Type: <netui:textBox dataSource="actionForm.type"/> + Width: + <netui:textBox dataSource="actionForm.width"/> + Height: + <netui:textBox dataSource="actionForm.height"/> <netui:button value="Submit" type="submit"/> </netui:form> Modified: incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/snapshot.jsp Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/snapshot.jsp?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/snapshot.jsp&r1=126431&p2=incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/snapshot.jsp&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/snapshot.jsp (original) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportWeb/jpf/snapshot.jsp Tue Jan 25 13:57:30 2005 @@ -15,11 +15,13 @@ <cewolf:producer id="snapshot_data"> <cewolf:param name="filename" value="${requestScope.filename}" /> <cewolf:param name="regex" value="${requestScope.regex}"/> + <cewolf:param name="xaxis" value="${requestScope.xaxis}"/> + <cewolf:param name="yaxis" value="${requestScope.yaxis}"/> </cewolf:producer> </cewolf:data> </cewolf:chart> <p> - <cewolf:img chartid="${requestScope.chartid}" renderer="cewolf" width="600" height="400"/> + <cewolf:img chartid="${requestScope.chartid}" renderer="cewolf" width="${requestScope.width}" height="${requestScope.height}"/> <P> </body> Added: incubator/beehive/trunk/controls/test/perf/webapps/reportweb.properties Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/perf/webapps/reportweb.properties?view=auto&rev=126432 ============================================================================== --- (empty file) +++ incubator/beehive/trunk/controls/test/perf/webapps/reportweb.properties Tue Jan 25 13:57:30 2005 @@ -0,0 +1,2 @@ +xmlbeansdir=d:\\internal\\dev\\sandbox\\runtimePerf\\xmlbeans\\reports +controlsdir=d:\\internal\\dev\\sandbox\\runtimePerf\\beehive\\reports Modified: incubator/beehive/trunk/controls/test/tools/mantis/build.xml Url: http://svn.apache.org/viewcvs/incubator/beehive/trunk/controls/test/tools/mantis/build.xml?view=diff&rev=126432&p1=incubator/beehive/trunk/controls/test/tools/mantis/build.xml&r1=126431&p2=incubator/beehive/trunk/controls/test/tools/mantis/build.xml&r2=126432 ============================================================================== --- incubator/beehive/trunk/controls/test/tools/mantis/build.xml (original) +++ incubator/beehive/trunk/controls/test/tools/mantis/build.xml Tue Jan 25 13:57:30 2005 @@ -1,7 +1,7 @@ <!-- build file --> <project name="mantis-build" default="usage"> - <import file="../../beehive-imports.xml"/> + <import file="../../../../beehive-imports.xml"/> <target name="usage"> <echo>
