diff --git a/.settings/edu.umd.cs.findbugs.core.prefs b/.settings/edu.umd.cs.findbugs.core.prefs index 4442f99a1266c33209dc8bb735d7f22d0b2973d7..603ed55567c663673b6aea7afc1413901cdf756a 100644 --- a/.settings/edu.umd.cs.findbugs.core.prefs +++ b/.settings/edu.umd.cs.findbugs.core.prefs @@ -1,5 +1,5 @@ #FindBugs User Preferences -#Thu Apr 30 18:23:15 CEST 2015 +#Mon May 04 12:59:03 CEST 2015 detector_threshold=3 effort=max excludefilter0=.fbExcludeFilterFile|true diff --git a/pom.xml b/pom.xml index 90f4fb324b8d478b26881fa47f2684c15905c9df..0f3824da73c3c1f7e95215edf0f5764524adbb92 100644 --- a/pom.xml +++ b/pom.xml @@ -68,7 +68,7 @@ <dependency> <groupId>net.sourceforge.teetime</groupId> <artifactId>teetime</artifactId> - <version>1.1</version> + <version>1.2-SNAPSHOT</version> </dependency> <dependency> <groupId>net.kieker-monitoring</groupId> @@ -81,12 +81,6 @@ <version>4.11</version> <scope>test</scope> </dependency> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest-core</artifactId> - <version>1.3</version> - <scope>test</scope> - </dependency> <dependency> <groupId>org.hamcrest</groupId> <artifactId>hamcrest-library</artifactId> @@ -109,11 +103,6 @@ <artifactId>guava</artifactId> <version>18.0</version> </dependency> - <dependency> - <groupId>org.jctools</groupId> - <artifactId>jctools-core</artifactId> - <version>1.0</version> - </dependency> </dependencies> <build> diff --git a/src/performancetest/java/teetime/examples/traceReading/ChwHomeTcpTraceReadingTest.java b/src/performancetest/java/teetime/examples/traceReading/ChwHomeTcpTraceReadingTest.java index c80634ed7b513c3ee58e799714a863b282017ac6..34fe9805a9c7db883976af9607fc2fddc9a6f454 100644 --- a/src/performancetest/java/teetime/examples/traceReading/ChwHomeTcpTraceReadingTest.java +++ b/src/performancetest/java/teetime/examples/traceReading/ChwHomeTcpTraceReadingTest.java @@ -66,8 +66,8 @@ public class ChwHomeTcpTraceReadingTest { public void performAnalysis() { final TcpTraceLoggingExtAnalysisConfiguration configuration = new TcpTraceLoggingExtAnalysisConfiguration(); - final Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TcpTraceLoggingExtAnalysisConfiguration> analysis; + analysis = new Analysis<TcpTraceLoggingExtAnalysisConfiguration>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTcpTraceReconstructionAnalysisTest.java b/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTcpTraceReconstructionAnalysisTest.java index db85ffe1cc58d4ddcb0924bcad0a19b80b9bbacb..aeb37a966423f04dfa310f9bbac727f7620f0507 100644 --- a/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTcpTraceReconstructionAnalysisTest.java +++ b/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTcpTraceReconstructionAnalysisTest.java @@ -63,8 +63,7 @@ public class ChwHomeTcpTraceReconstructionAnalysisTest { public void performAnalysis() { final TcpTraceReconstructionConf configuration = new TcpTraceReconstructionConf(); - final Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TcpTraceReconstructionConf> analysis = new Analysis<TcpTraceReconstructionConf>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTraceReconstructionAnalysisTest.java b/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTraceReconstructionAnalysisTest.java index 01b5daacfb2a68813413c1d02d54f321c8548748..b8accd27c1c37ee7112f257864d295e6eece0bc6 100644 --- a/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTraceReconstructionAnalysisTest.java +++ b/src/performancetest/java/teetime/examples/traceReconstruction/ChwHomeTraceReconstructionAnalysisTest.java @@ -61,8 +61,7 @@ public class ChwHomeTraceReconstructionAnalysisTest { public void performAnalysisWithEprintsLogs() { final TraceReconstructionConf configuration = new TraceReconstructionConf(new File(RESOURCE_DIR + "data/Eprints-logs")); - Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TraceReconstructionConf> analysis = new Analysis<TraceReconstructionConf>(configuration); this.stopWatch.start(); try { @@ -91,8 +90,7 @@ public class ChwHomeTraceReconstructionAnalysisTest { public void performAnalysisWithKiekerLogs() { final TraceReconstructionConf configuration = new TraceReconstructionConf(new File(RESOURCE_DIR + "data/kieker-logs")); - Analysis analysis = new Analysis(configuration); - analysis.init(); + Analysis<TraceReconstructionConf> analysis = new Analysis<TraceReconstructionConf>(configuration); this.stopWatch.start(); try { @@ -121,8 +119,7 @@ public class ChwHomeTraceReconstructionAnalysisTest { public void performAnalysisWithKieker2Logs() { final TraceReconstructionConf configuration = new TraceReconstructionConf(new File(RESOURCE_DIR + "data/kieker2-logs")); - Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TraceReconstructionConf> analysis = new Analysis<TraceReconstructionConf>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTcpTraceReconstructionAnalysisTest.java b/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTcpTraceReconstructionAnalysisTest.java index 1e93672552b3fa2507bac09db685e1ada4d43d8b..61f51e7b4ea77825f3a0096828a76a1fa2a92d1e 100644 --- a/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTcpTraceReconstructionAnalysisTest.java +++ b/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTcpTraceReconstructionAnalysisTest.java @@ -56,8 +56,7 @@ public class ChwWorkTcpTraceReconstructionAnalysisTest { public void performAnalysis() { final TcpTraceReconstructionConf configuration = new TcpTraceReconstructionConf(); - Analysis analysis = new Analysis(configuration); - analysis.init(); + Analysis<TcpTraceReconstructionConf> analysis = new Analysis<TcpTraceReconstructionConf>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTraceReconstructionAnalysisTest.java b/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTraceReconstructionAnalysisTest.java index 3c1117568adeff16d2a37c4c7f1044c85630cf46..c719e62cabbda9f25db2fd9b82b5d2bfc760c0f4 100644 --- a/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTraceReconstructionAnalysisTest.java +++ b/src/performancetest/java/teetime/examples/traceReconstruction/ChwWorkTraceReconstructionAnalysisTest.java @@ -58,9 +58,7 @@ class ChwWorkTraceReconstructionAnalysisTest { @Test public void performAnalysisWithEprintsLogs() { final TraceReconstructionConf configuration = new TraceReconstructionConf(new File("src/test/data/Eprints-logs")); - - Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TraceReconstructionConf> analysis = new Analysis<TraceReconstructionConf>(configuration); this.stopWatch.start(); try { @@ -86,9 +84,7 @@ class ChwWorkTraceReconstructionAnalysisTest { @Test public void performAnalysisWithKiekerLogs() { final TraceReconstructionConf configuration = new TraceReconstructionConf(new File("src/test/data/kieker-logs")); - - Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TraceReconstructionConf> analysis = new Analysis<TraceReconstructionConf>(configuration); this.stopWatch.start(); try { @@ -116,9 +112,7 @@ class ChwWorkTraceReconstructionAnalysisTest { @Test public void performAnalysisWithKieker2Logs() { final TraceReconstructionConf configuration = new TraceReconstructionConf(new File("src/test/data/kieker2-logs")); - - Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TraceReconstructionConf> analysis = new Analysis<TraceReconstructionConf>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwHomeTcpTraceReconstructionAnalysisWithThreadsTest.java b/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwHomeTcpTraceReconstructionAnalysisWithThreadsTest.java index 62755a6fd4351dcacc374a3143b3e0acefa714e6..b5f7f6041746ff722856a5bc2ed78b9b027d1a4c 100644 --- a/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwHomeTcpTraceReconstructionAnalysisWithThreadsTest.java +++ b/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwHomeTcpTraceReconstructionAnalysisWithThreadsTest.java @@ -73,8 +73,8 @@ public class ChwHomeTcpTraceReconstructionAnalysisWithThreadsTest { void performAnalysis(final int numWorkerThreads) { final TcpTraceReconstructionAnalysisWithThreadsConfiguration configuration = new TcpTraceReconstructionAnalysisWithThreadsConfiguration(numWorkerThreads); - Analysis analysis = new Analysis(configuration); - analysis.init(); + Analysis<TcpTraceReconstructionAnalysisWithThreadsConfiguration> analysis; + analysis = new Analysis<TcpTraceReconstructionAnalysisWithThreadsConfiguration>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwWorkTcpTraceReconstructionAnalysisWithThreadsTest.java b/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwWorkTcpTraceReconstructionAnalysisWithThreadsTest.java index 8ec08f8a275d6a5f8c49ec850df832ce9e5a045e..8595e05c67fba99d3265b986ec314b9bd54ec6dc 100644 --- a/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwWorkTcpTraceReconstructionAnalysisWithThreadsTest.java +++ b/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/ChwWorkTcpTraceReconstructionAnalysisWithThreadsTest.java @@ -88,8 +88,8 @@ public class ChwWorkTcpTraceReconstructionAnalysisWithThreadsTest { void performAnalysis(final int numWorkerThreads) { final TcpTraceReconstructionAnalysisWithThreadsConfiguration configuration = new TcpTraceReconstructionAnalysisWithThreadsConfiguration(numWorkerThreads); - final Analysis analysis = new Analysis(configuration); - analysis.init(); + final Analysis<TcpTraceReconstructionAnalysisWithThreadsConfiguration> analysis; + analysis = new Analysis<TcpTraceReconstructionAnalysisWithThreadsConfiguration>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/TcpTraceReconstructionAnalysisWithThreadsConfiguration.java b/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/TcpTraceReconstructionAnalysisWithThreadsConfiguration.java index 674b832a402bfd98e341eb954c5c4f1967bcddf7..787169d6e46b8274464db404c99a81b07a5d4d1a 100644 --- a/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/TcpTraceReconstructionAnalysisWithThreadsConfiguration.java +++ b/src/performancetest/java/teetime/examples/traceReconstructionWithThreads/TcpTraceReconstructionAnalysisWithThreadsConfiguration.java @@ -25,11 +25,11 @@ import teetime.framework.AbstractStage; import teetime.framework.AnalysisConfiguration; import teetime.framework.Pipeline; import teetime.framework.Stage; +import teetime.framework.pipe.IMonitorablePipe; import teetime.framework.pipe.IPipe; import teetime.framework.pipe.IPipeFactory; import teetime.framework.pipe.PipeFactoryRegistry.PipeOrdering; import teetime.framework.pipe.PipeFactoryRegistry.ThreadCommunication; -import teetime.framework.pipe.SpScPipe; import teetime.stage.Clock; import teetime.stage.Counter; import teetime.stage.ElementDelayMeasuringStage; @@ -70,7 +70,7 @@ public class TcpTraceReconstructionAnalysisWithThreadsConfiguration extends Anal private final StageFactory<Counter<EventBasedTrace>> traceCounterFactory; private final StageFactory<ElementThroughputMeasuringStage<EventBasedTrace>> traceThroughputFilterFactory; - private final List<IPipe> tcpRelayPipes = new LinkedList<IPipe>(); + private final List<IMonitorablePipe> tcpRelayPipes = new LinkedList<IMonitorablePipe>(); private final IPipeFactory intraThreadPipeFactory; private final IPipeFactory interThreadPipeFactory; @@ -183,7 +183,7 @@ public class TcpTraceReconstructionAnalysisWithThreadsConfiguration extends Anal // connect stages IPipe tcpRelayPipe = interThreadPipeFactory.create(tcpReaderPipeline.getNewOutputPort(), relay.getInputPort(), TCP_RELAY_MAX_SIZE); - this.tcpRelayPipes.add(tcpRelayPipe); + this.tcpRelayPipes.add((IMonitorablePipe) tcpRelayPipe); // SysOutFilter<EventBasedTrace> sysout = new SysOutFilter<EventBasedTrace>(tcpRelayPipe); interThreadPipeFactory.create(clockStage.getNewOutputPort(), recordThroughputFilter.getTriggerInputPort(), 10); @@ -256,9 +256,8 @@ public class TcpTraceReconstructionAnalysisWithThreadsConfiguration extends Anal public int getMaxNumWaits() { int maxNumWaits = 0; - for (IPipe pipe : this.tcpRelayPipes) { - SpScPipe interThreadPipe = (SpScPipe) pipe; - maxNumWaits = Math.max(maxNumWaits, interThreadPipe.getNumWaits()); + for (IMonitorablePipe pipe : this.tcpRelayPipes) { + maxNumWaits = Math.max(maxNumWaits, pipe.getNumWaits()); } return maxNumWaits; } diff --git a/src/performancetest/java/teetime/examples/traceReductionWithThreads/ChwWorkTcpTraceReductionAnalysisWithThreadsTest.java b/src/performancetest/java/teetime/examples/traceReductionWithThreads/ChwWorkTcpTraceReductionAnalysisWithThreadsTest.java index 9f33491d5ca5cb8207c96c5486a7a3f63895cc01..4b7468c578bb6a1c370d259f54ab9244a22b4b90 100644 --- a/src/performancetest/java/teetime/examples/traceReductionWithThreads/ChwWorkTcpTraceReductionAnalysisWithThreadsTest.java +++ b/src/performancetest/java/teetime/examples/traceReductionWithThreads/ChwWorkTcpTraceReductionAnalysisWithThreadsTest.java @@ -102,8 +102,8 @@ public class ChwWorkTcpTraceReductionAnalysisWithThreadsTest { void performAnalysis(final int numWorkerThreads) { final TcpTraceReductionAnalysisWithThreadsConfiguration configuration = new TcpTraceReductionAnalysisWithThreadsConfiguration(numWorkerThreads); - Analysis analysis = new Analysis(configuration); - analysis.init(); + Analysis<TcpTraceReductionAnalysisWithThreadsConfiguration> analysis; + analysis = new Analysis<TcpTraceReductionAnalysisWithThreadsConfiguration>(configuration); this.stopWatch.start(); try { diff --git a/src/performancetest/java/teetime/examples/traceReductionWithThreads/TcpTraceReductionAnalysisWithThreadsConfiguration.java b/src/performancetest/java/teetime/examples/traceReductionWithThreads/TcpTraceReductionAnalysisWithThreadsConfiguration.java index f20ce395e025080ab26e8df4c420d5fe50eaad10..8c03d88b7fe1422ed58e5e3690081ea8c96d2857 100644 --- a/src/performancetest/java/teetime/examples/traceReductionWithThreads/TcpTraceReductionAnalysisWithThreadsConfiguration.java +++ b/src/performancetest/java/teetime/examples/traceReductionWithThreads/TcpTraceReductionAnalysisWithThreadsConfiguration.java @@ -27,11 +27,11 @@ import teetime.framework.AbstractStage; import teetime.framework.AnalysisConfiguration; import teetime.framework.Pipeline; import teetime.framework.Stage; +import teetime.framework.pipe.IMonitorablePipe; import teetime.framework.pipe.IPipe; import teetime.framework.pipe.IPipeFactory; import teetime.framework.pipe.PipeFactoryRegistry.PipeOrdering; import teetime.framework.pipe.PipeFactoryRegistry.ThreadCommunication; -import teetime.framework.pipe.SpScPipe; import teetime.stage.Clock; import teetime.stage.Counter; import teetime.stage.ElementDelayMeasuringStage; @@ -62,7 +62,7 @@ public class TcpTraceReductionAnalysisWithThreadsConfiguration extends AnalysisC private final List<EventBasedTrace> elementCollection = new LinkedList<EventBasedTrace>(); - private final List<IPipe> tcpRelayPipes = new ArrayList<IPipe>(); + private final List<IMonitorablePipe> tcpRelayPipes = new ArrayList<IMonitorablePipe>(); private final int numWorkerThreads; private final ConcurrentHashMapWithDefault<Long, EventBasedTrace> traceId2trace; @@ -183,7 +183,7 @@ public class TcpTraceReductionAnalysisWithThreadsConfiguration extends AnalysisC // connect stages final IPipe pipe = interThreadPipeFactory.create(tcpPipeline.getLastStage().getNewOutputPort(), relay.getInputPort(), TCP_RELAY_MAX_SIZE); - this.tcpRelayPipes.add(pipe); + this.tcpRelayPipes.add((IMonitorablePipe) pipe); intraThreadPipeFactory.create(relay.getOutputPort(), recordCounter.getInputPort()); intraThreadPipeFactory.create(recordCounter.getOutputPort(), traceMetadataCounter.getInputPort()); @@ -241,9 +241,8 @@ public class TcpTraceReductionAnalysisWithThreadsConfiguration extends AnalysisC public int getMaxNumWaits() { int maxNumWaits = 0; - for (IPipe pipe : this.tcpRelayPipes) { - SpScPipe interThreadPipe = (SpScPipe) pipe; - maxNumWaits = Math.max(maxNumWaits, interThreadPipe.getNumWaits()); + for (IMonitorablePipe pipe : this.tcpRelayPipes) { + maxNumWaits = Math.max(maxNumWaits, pipe.getNumWaits()); } return maxNumWaits; } diff --git a/src/performancetest/java/util/test/PerformanceTest.java b/src/performancetest/java/util/test/PerformanceTest.java index 5a4f034e5690362ef77510d79cfbe7ca423670d1..845f9239c4042e76488d584e92d8878f7c151821 100644 --- a/src/performancetest/java/util/test/PerformanceTest.java +++ b/src/performancetest/java/util/test/PerformanceTest.java @@ -30,6 +30,8 @@ import teetime.util.StopWatch; import teetime.util.TimestampObject; import teetime.util.test.eval.PerformanceResult; import teetime.util.test.eval.StatisticsUtil; +import teetime.util.test.framework.MeasurementRepository; +import teetime.util.test.framework.PerformanceCheckProfileRepository; public abstract class PerformanceTest {