Commit 6e62e31c authored by Florian Fittkau's avatar Florian Fittkau

clazz determination for abstract detection

parent 596adb8c
......@@ -299,12 +299,14 @@ class TCPReaderOneClient extends Thread {
final int orderIndex = buffer.getInt();
final int objectId = buffer.getInt();
final int operationId = buffer.getInt();
final int clazzId = buffer.getInt();
try {
final String operation = stringRegistry.getStringFromId(operationId);
final String clazz = stringRegistry.getStringFromId(clazzId);
putInRingBuffer(new BeforeOperationEventRecord(timestamp, traceId, orderIndex,
objectId, operation, hostApplicationMetadata));
objectId, operation, clazz, hostApplicationMetadata));
} catch (final IdNotAvailableException e) {
putInWaitingMessages(buffer, BeforeOperationEventRecord.COMPRESSED_BYTE_LENGTH + 1);
}
......@@ -350,12 +352,14 @@ class TCPReaderOneClient extends Thread {
final int orderIndex = buffer.getInt();
final int objectId = buffer.getInt();
final int operationId = buffer.getInt();
final int clazzId = buffer.getInt();
try {
final String operation = stringRegistry.getStringFromId(operationId);
final String clazz = stringRegistry.getStringFromId(clazzId);
putInRingBuffer(new BeforeConstructorEventRecord(timestamp, traceId, orderIndex,
objectId, operation, hostApplicationMetadata));
objectId, operation, clazz, hostApplicationMetadata));
} catch (final IdNotAvailableException e) {
putInWaitingMessages(buffer,
BeforeConstructorEventRecord.COMPRESSED_BYTE_LENGTH_WITH_CLAZZ_ID);
......@@ -403,12 +407,14 @@ class TCPReaderOneClient extends Thread {
final long traceId = buffer.getLong();
final int orderIndex = buffer.getInt();
final int operationId = buffer.getInt();
final int clazzId = buffer.getInt();
try {
final String operation = stringRegistry.getStringFromId(operationId);
final String clazz = stringRegistry.getStringFromId(clazzId);
putInRingBuffer(new BeforeStaticOperationEventRecord(timestamp, traceId, orderIndex,
operation, hostApplicationMetadata));
operation, clazz, hostApplicationMetadata));
} catch (final IdNotAvailableException e) {
putInWaitingMessages(buffer,
BeforeStaticOperationEventRecord.COMPRESSED_BYTE_LENGTH_WITH_CLAZZ_ID);
......
......@@ -13,7 +13,8 @@ public class TraceReconstructionBufferTest {
public void testInsertEvent() throws Exception {
final TraceReconstructionBuffer traceReconstructionBuffer = new TraceReconstructionBuffer();
traceReconstructionBuffer.insertEvent(new BeforeOperationEventRecord(1000, 1, 0, 0, "test",
new HostApplicationMetaDataRecord("testSystem", "testIp", "testHost", "testApp")));
"TestClazz", new HostApplicationMetaDataRecord("testSystem", "testIp", "testHost",
"testApp")));
assertTrue(true); // TODO
}
......
......@@ -24,14 +24,14 @@ public class AssociativityFilterTest {
final List<AbstractEventRecord> traceEvents = new ArrayList<AbstractEventRecord>();
final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0,
"test.package.Clazz.method1()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
"test.package.Clazz.method1()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(11L));
traceEvents.add(beforeEvent);
final BeforeOperationEventRecord beforeEvent1 = new BeforeOperationEventRecord(2L, 1L, 1,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent1.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L));
traceEvents.add(beforeEvent1);
......@@ -40,8 +40,8 @@ public class AssociativityFilterTest {
traceEvents.add(afterEvent1);
final BeforeOperationEventRecord beforeEvent2 = new BeforeOperationEventRecord(5L, 1L, 3,
0, "test.package.OtherClazz.method3()", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
0, "test.package.OtherClazz.method3()", "ClazzF",
new HostApplicationMetaDataRecord("testSystem", "testIp", "host", "application"));
beforeEvent2.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L));
traceEvents.add(beforeEvent2);
......@@ -50,8 +50,8 @@ public class AssociativityFilterTest {
traceEvents.add(afterEvent2);
final BeforeOperationEventRecord beforeEvent3 = new BeforeOperationEventRecord(7L, 1L, 5,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent3.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L));
traceEvents.add(beforeEvent3);
......@@ -60,8 +60,8 @@ public class AssociativityFilterTest {
traceEvents.add(afterEvent3);
final BeforeOperationEventRecord beforeEvent4 = new BeforeOperationEventRecord(10L, 1L, 7,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent4.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L));
traceEvents.add(beforeEvent4);
......@@ -81,14 +81,14 @@ public class AssociativityFilterTest {
final List<AbstractEventRecord> traceEvents = new ArrayList<AbstractEventRecord>();
final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0,
"test.package.Clazz.method1()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
"test.package.Clazz.method1()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(11L));
traceEvents.add(beforeEvent);
final BeforeOperationEventRecord beforeEvent2 = new BeforeOperationEventRecord(5L, 1L, 3,
0, "test.package.OtherClazz.method3()", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
0, "test.package.OtherClazz.method3()", "ClazzF",
new HostApplicationMetaDataRecord("testSystem", "testIp", "host", "application"));
beforeEvent2.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L));
traceEvents.add(beforeEvent2);
......
......@@ -24,16 +24,16 @@ public class IterationFilterTest {
final List<AbstractEventRecord> traceEvents = new ArrayList<AbstractEventRecord>();
final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0,
"test.package.Clazz.method1()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
"test.package.Clazz.method1()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(11L));
traceEvents.add(beforeEvent);
beforeEvent.getRuntimeStatisticInformation().makeAccumulator(0);
final BeforeOperationEventRecord beforeEvent1 = new BeforeOperationEventRecord(2L, 1L, 1,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent1.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L));
traceEvents.add(beforeEvent1);
......@@ -42,8 +42,8 @@ public class IterationFilterTest {
traceEvents.add(afterEvent1);
final BeforeOperationEventRecord beforeEvent2 = new BeforeOperationEventRecord(5L, 1L, 3,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent2.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L));
traceEvents.add(beforeEvent2);
......@@ -52,8 +52,8 @@ public class IterationFilterTest {
traceEvents.add(afterEvent2);
final BeforeOperationEventRecord beforeEvent3 = new BeforeOperationEventRecord(7L, 1L, 5,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent3.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L));
traceEvents.add(beforeEvent3);
......@@ -62,8 +62,8 @@ public class IterationFilterTest {
traceEvents.add(afterEvent3);
final BeforeOperationEventRecord beforeEvent4 = new BeforeOperationEventRecord(10L, 1L, 7,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent4.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L));
traceEvents.add(beforeEvent4);
......@@ -84,11 +84,11 @@ public class IterationFilterTest {
final HostApplicationMetaDataRecord hostApplicationMetadata = new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application");
final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0,
"test.package.Clazz.method1()", hostApplicationMetadata);
"test.package.Clazz.method1()", "ClazzF", hostApplicationMetadata);
traceEvents.add(beforeEvent);
beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(11L));
final BeforeOperationEventRecord beforeEvent1 = new BeforeOperationEventRecord(10L, 1L, 7,
0, "test.package.Clazz.method2()", hostApplicationMetadata);
0, "test.package.Clazz.method2()", "ClazzF", hostApplicationMetadata);
traceEvents.add(beforeEvent1);
beforeEvent1.setRuntimeStatisticInformation(new RuntimeStatisticInformation(4, 6, 10));
final AfterOperationEventRecord afterEvent1 = new AfterOperationEventRecord(11L, 1L, 8,
......
......@@ -24,14 +24,14 @@ public class MonotoneSubsequenceTest {
final List<AbstractEventRecord> traceEvents = new ArrayList<AbstractEventRecord>();
final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0,
"test.package.Clazz.method1()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
"test.package.Clazz.method1()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(11L));
traceEvents.add(beforeEvent);
final BeforeOperationEventRecord beforeEvent1 = new BeforeOperationEventRecord(2L, 1L, 1,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent1.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L));
traceEvents.add(beforeEvent1);
......@@ -40,8 +40,8 @@ public class MonotoneSubsequenceTest {
traceEvents.add(afterEvent1);
final BeforeOperationEventRecord beforeEvent2 = new BeforeOperationEventRecord(5L, 1L, 3,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent2.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L));
traceEvents.add(beforeEvent2);
......@@ -50,8 +50,8 @@ public class MonotoneSubsequenceTest {
traceEvents.add(afterEvent2);
final BeforeOperationEventRecord beforeEvent3 = new BeforeOperationEventRecord(7L, 1L, 5,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent3.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L));
traceEvents.add(beforeEvent3);
......@@ -60,8 +60,8 @@ public class MonotoneSubsequenceTest {
traceEvents.add(afterEvent3);
final BeforeOperationEventRecord beforeEvent4 = new BeforeOperationEventRecord(10L, 1L, 7,
0, "test.package.Clazz.method2()", new HostApplicationMetaDataRecord("testSystem",
"testIp", "host", "application"));
0, "test.package.Clazz.method2()", "ClazzF", new HostApplicationMetaDataRecord(
"testSystem", "testIp", "host", "application"));
beforeEvent4.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L));
traceEvents.add(beforeEvent4);
......@@ -84,7 +84,7 @@ public class MonotoneSubsequenceTest {
"testSystem", "testIp", "host", "application");
final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0,
"test.package.Clazz.method1()", hostApplicationMetadata);
"test.package.Clazz.method1()", "ClazzF", hostApplicationMetadata);
traceEvents.add(beforeEvent);
beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(11L));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment