diff --git a/src/explorviz/live_trace_processing/reader/TCPReaderOneClient.java b/src/explorviz/live_trace_processing/reader/TCPReaderOneClient.java index 9f4e5ae1f85de543015bca62fd5103a2efe4ef57..b28db6dcbf13079873678dc297cbfbf96b6b1303 100644 --- a/src/explorviz/live_trace_processing/reader/TCPReaderOneClient.java +++ b/src/explorviz/live_trace_processing/reader/TCPReaderOneClient.java @@ -301,13 +301,15 @@ class TCPReaderOneClient extends Thread { final int objectId = buffer.getInt(); final int operationId = buffer.getInt(); final int clazzId = buffer.getInt(); + final int interfaceId = buffer.getInt(); try { final String operation = stringRegistry.getStringFromId(operationId); final String clazz = stringRegistry.getStringFromId(clazzId); + final String implementedInterface = stringRegistry.getStringFromId(interfaceId); putInRingBuffer(new BeforeOperationEventRecord(timestamp, traceId, orderIndex, - objectId, operation, clazz, hostApplicationMetadata)); + objectId, operation, clazz, implementedInterface, hostApplicationMetadata)); } catch (final IdNotAvailableException e) { putInWaitingMessages(buffer, BeforeOperationEventRecord.COMPRESSED_BYTE_LENGTH + 1); } @@ -354,13 +356,15 @@ class TCPReaderOneClient extends Thread { final int objectId = buffer.getInt(); final int operationId = buffer.getInt(); final int clazzId = buffer.getInt(); + final int interfaceId = buffer.getInt(); try { final String operation = stringRegistry.getStringFromId(operationId); final String clazz = stringRegistry.getStringFromId(clazzId); + final String implementedInterface = stringRegistry.getStringFromId(interfaceId); putInRingBuffer(new BeforeConstructorEventRecord(timestamp, traceId, orderIndex, - objectId, operation, clazz, hostApplicationMetadata)); + objectId, operation, clazz, implementedInterface, hostApplicationMetadata)); } catch (final IdNotAvailableException e) { putInWaitingMessages(buffer, BeforeConstructorEventRecord.COMPRESSED_BYTE_LENGTH_WITH_CLAZZ_ID); @@ -409,13 +413,15 @@ class TCPReaderOneClient extends Thread { final int orderIndex = buffer.getInt(); final int operationId = buffer.getInt(); final int clazzId = buffer.getInt(); + final int interfaceId = buffer.getInt(); try { final String operation = stringRegistry.getStringFromId(operationId); final String clazz = stringRegistry.getStringFromId(clazzId); + final String implementedInterface = stringRegistry.getStringFromId(interfaceId); putInRingBuffer(new BeforeStaticOperationEventRecord(timestamp, traceId, orderIndex, - operation, clazz, hostApplicationMetadata)); + operation, clazz, implementedInterface, hostApplicationMetadata)); } catch (final IdNotAvailableException e) { putInWaitingMessages(buffer, BeforeStaticOperationEventRecord.COMPRESSED_BYTE_LENGTH_WITH_CLAZZ_ID); diff --git a/test/explorviz/live_trace_processing/filter/reconstruction/TraceReconstructionBufferTest.java b/test/explorviz/live_trace_processing/filter/reconstruction/TraceReconstructionBufferTest.java index e7136d197b2e3d4e911381afbe6cda5a4a0b9c14..f20beac07bd85cb389bfc7c082f42fda9c3fc4e0 100644 --- a/test/explorviz/live_trace_processing/filter/reconstruction/TraceReconstructionBufferTest.java +++ b/test/explorviz/live_trace_processing/filter/reconstruction/TraceReconstructionBufferTest.java @@ -13,8 +13,8 @@ public class TraceReconstructionBufferTest { public void testInsertEvent() throws Exception { final TraceReconstructionBuffer traceReconstructionBuffer = new TraceReconstructionBuffer(); traceReconstructionBuffer.insertEvent(new BeforeOperationEventRecord(1000, 1, 0, 0, "test", - "TestClazz", new HostApplicationMetaDataRecord("testSystem", "testIp", "testHost", - "testApp"))); + "TestClazz", "", new HostApplicationMetaDataRecord("testSystem", "testIp", + "testHost", "testApp"))); assertTrue(true); // TODO } diff --git a/test/explorviz/live_trace_processing/filter/reduction/PatternSummarizationTest.java b/test/explorviz/live_trace_processing/filter/reduction/PatternSummarizationTest.java index e54fc47b7aa07339f2cd3385810a63ebd478c76a..aa34fe52fbc58361dd0fc5ea52725029b91419fb 100644 --- a/test/explorviz/live_trace_processing/filter/reduction/PatternSummarizationTest.java +++ b/test/explorviz/live_trace_processing/filter/reduction/PatternSummarizationTest.java @@ -19,13 +19,13 @@ public class PatternSummarizationTest { final List<AbstractEventRecord> traceEvents = new ArrayList<AbstractEventRecord>(); final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0, - "test.package.Clazz.A()", "ClazzA", new HostApplicationMetaDataRecord("testSystem", - "testIp", "host", "application")); + "test.package.Clazz.A()", "ClazzA", "", new HostApplicationMetaDataRecord( + "testSystem", "testIp", "host", "application")); beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(31L)); traceEvents.add(beforeEvent); final BeforeOperationEventRecord beforeEvent1 = new BeforeOperationEventRecord(2L, 1L, 1, - 0, "test.package.Clazz.B()", "ClazzB", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.B()", "ClazzB", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent1.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L)); traceEvents.add(beforeEvent1); @@ -35,7 +35,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent1); final BeforeOperationEventRecord beforeEvent2 = new BeforeOperationEventRecord(5L, 1L, 3, - 0, "test.package.Clazz.C()", "ClazzC", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.C()", "ClazzC", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent2.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent2); @@ -45,13 +45,13 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent2); final BeforeOperationEventRecord beforeEvent3 = new BeforeOperationEventRecord(7L, 1L, 5, - 0, "test.package.Clazz.D()", "ClazzD", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.D()", "ClazzD", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent3.setRuntimeStatisticInformation(new RuntimeStatisticInformation(9L)); traceEvents.add(beforeEvent3); final BeforeOperationEventRecord beforeEvent4 = new BeforeOperationEventRecord(8L, 1L, 6, - 0, "test.package.Clazz.E()", "ClazzE", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.E()", "ClazzE", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent4.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent4); @@ -61,7 +61,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent4); final BeforeOperationEventRecord beforeEvent5 = new BeforeOperationEventRecord(10L, 1L, 8, - 0, "test.package.Clazz.F()", "ClazzF", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.F()", "ClazzF", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent5.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent5); @@ -71,7 +71,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent5); final BeforeOperationEventRecord beforeEvent6 = new BeforeOperationEventRecord(12L, 1L, 10, - 0, "test.package.Clazz.E()", "ClazzE", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.E()", "ClazzE", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent6.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent6); @@ -81,7 +81,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent6); final BeforeOperationEventRecord beforeEvent7 = new BeforeOperationEventRecord(14L, 1L, 12, - 0, "test.package.Clazz.F()", "ClazzF", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.F()", "ClazzF", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent7.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent7); @@ -95,7 +95,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent3); final BeforeOperationEventRecord beforeEvent8 = new BeforeOperationEventRecord(17L, 1L, 15, - 0, "test.package.Clazz.B()", "ClazzB", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.B()", "ClazzB", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent8.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2L)); traceEvents.add(beforeEvent8); @@ -105,7 +105,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent8); final BeforeOperationEventRecord beforeEvent9 = new BeforeOperationEventRecord(20L, 1L, 17, - 0, "test.package.Clazz.C()", "ClazzC", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.C()", "ClazzC", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent9.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent9); @@ -115,13 +115,13 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent9); final BeforeOperationEventRecord beforeEvent10 = new BeforeOperationEventRecord(22L, 1L, - 19, 0, "test.package.Clazz.D()", "ClazzD", new HostApplicationMetaDataRecord( + 19, 0, "test.package.Clazz.D()", "ClazzD", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent10.setRuntimeStatisticInformation(new RuntimeStatisticInformation(9L)); traceEvents.add(beforeEvent10); final BeforeOperationEventRecord beforeEvent11 = new BeforeOperationEventRecord(23L, 1L, - 20, 0, "test.package.Clazz.E()", "ClazzE", new HostApplicationMetaDataRecord( + 20, 0, "test.package.Clazz.E()", "ClazzE", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent11.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent11); @@ -131,7 +131,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent11); final BeforeOperationEventRecord beforeEvent12 = new BeforeOperationEventRecord(25L, 1L, - 22, 0, "test.package.Clazz.F()", "ClazzF", new HostApplicationMetaDataRecord( + 22, 0, "test.package.Clazz.F()", "ClazzF", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent12.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent12); @@ -141,7 +141,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent12); final BeforeOperationEventRecord beforeEvent13 = new BeforeOperationEventRecord(27L, 1L, - 24, 0, "test.package.Clazz.E()", "ClazzE", new HostApplicationMetaDataRecord( + 24, 0, "test.package.Clazz.E()", "ClazzE", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent13.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent13); @@ -151,7 +151,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent13); final BeforeOperationEventRecord beforeEvent14 = new BeforeOperationEventRecord(29L, 1L, - 26, 0, "test.package.Clazz.F()", "ClazzF", new HostApplicationMetaDataRecord( + 26, 0, "test.package.Clazz.F()", "ClazzF", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent14.setRuntimeStatisticInformation(new RuntimeStatisticInformation(1L)); traceEvents.add(beforeEvent14); @@ -176,13 +176,13 @@ public class PatternSummarizationTest { final List<AbstractEventRecord> traceEvents = new ArrayList<AbstractEventRecord>(); final BeforeOperationEventRecord beforeEvent = new BeforeOperationEventRecord(1L, 1L, 0, 0, - "test.package.Clazz.A()", "ClazzA", new HostApplicationMetaDataRecord("testSystem", - "testIp", "host", "application")); + "test.package.Clazz.A()", "ClazzA", "", new HostApplicationMetaDataRecord( + "testSystem", "testIp", "host", "application")); beforeEvent.setRuntimeStatisticInformation(new RuntimeStatisticInformation(31L)); traceEvents.add(beforeEvent); final BeforeOperationEventRecord beforeEvent1 = new BeforeOperationEventRecord(2L, 1L, 1, - 0, "test.package.Clazz.B()", "ClazzB", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.B()", "ClazzB", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent1.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2, 4, 8)); traceEvents.add(beforeEvent1); @@ -192,7 +192,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent1); final BeforeOperationEventRecord beforeEvent2 = new BeforeOperationEventRecord(5L, 1L, 3, - 0, "test.package.Clazz.C()", "ClazzC", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.C()", "ClazzC", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent2.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2, 2, 2)); traceEvents.add(beforeEvent2); @@ -202,13 +202,13 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent2); final BeforeOperationEventRecord beforeEvent3 = new BeforeOperationEventRecord(7L, 1L, 5, - 0, "test.package.Clazz.D()", "ClazzD", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.D()", "ClazzD", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent3.setRuntimeStatisticInformation(new RuntimeStatisticInformation(2, 18, 162)); traceEvents.add(beforeEvent3); final BeforeOperationEventRecord beforeEvent4 = new BeforeOperationEventRecord(8L, 1L, 6, - 0, "test.package.Clazz.E()", "ClazzE", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.E()", "ClazzE", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent4.setRuntimeStatisticInformation(new RuntimeStatisticInformation(4, 4, 4)); traceEvents.add(beforeEvent4); @@ -218,7 +218,7 @@ public class PatternSummarizationTest { traceEvents.add(afterEvent4); final BeforeOperationEventRecord beforeEvent5 = new BeforeOperationEventRecord(10L, 1L, 8, - 0, "test.package.Clazz.F()", "ClazzF", new HostApplicationMetaDataRecord( + 0, "test.package.Clazz.F()", "ClazzF", "", new HostApplicationMetaDataRecord( "testSystem", "testIp", "host", "application")); beforeEvent5.setRuntimeStatisticInformation(new RuntimeStatisticInformation(4, 4, 4)); traceEvents.add(beforeEvent5);