opentracing: Add the operation name to the span's state
It is clearer to see the operation name in the state instead of only as
part of the entry name on the left.
Signed-off-by: Geneviève Bastien <gbastien+lttng@versatic.net>
Change-Id: I7614d119b71098a661d543b817de86fd878848e8
Reviewed-on: https://git.eclipse.org/r/c/tracecompass.incubator/org.eclipse.tracecompass.incubator/+/173044
Tested-by: Trace Compass Bot <tracecompass-bot@eclipse.org>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
diff --git a/tracetypes/org.eclipse.tracecompass.incubator.opentracing.core/src/org/eclipse/tracecompass/incubator/internal/opentracing/core/analysis/spanlife/SpanLifeDataProvider.java b/tracetypes/org.eclipse.tracecompass.incubator.opentracing.core/src/org/eclipse/tracecompass/incubator/internal/opentracing/core/analysis/spanlife/SpanLifeDataProvider.java
index 4d3a1d3..68e83c3 100644
--- a/tracetypes/org.eclipse.tracecompass.incubator.opentracing.core/src/org/eclipse/tracecompass/incubator/internal/opentracing/core/analysis/spanlife/SpanLifeDataProvider.java
+++ b/tracetypes/org.eclipse.tracecompass.incubator.opentracing.core/src/org/eclipse/tracecompass/incubator/internal/opentracing/core/analysis/spanlife/SpanLifeDataProvider.java
@@ -186,7 +186,7 @@
long startTime = interval.getStartTime();
long duration = interval.getEndTime() - startTime + 1;
Object state = interval.getValue();
- TimeGraphState value = new TimeGraphState(startTime, duration, state == null ? Integer.MIN_VALUE : 0);
+ TimeGraphState value = state == null ? new TimeGraphState(startTime, duration, Integer.MIN_VALUE) : new TimeGraphState(startTime, duration, 0, String.valueOf(state));
applyFilterAndAddState(eventList, value, entry.getKey(), predicates, monitor);
}
rows.add(new TimeGraphRowModel(entry.getKey(), eventList));