Class MTC


  • public class MTC
    extends Object
    Mapped tracing context. Thread local context which holding the information for tracing.
    • Constructor Detail

      • MTC

        public MTC()
    • Method Detail

      • span

        @NotNull
        public static @NotNull Span span()
        Returns:
        Span which corresponded to current thread or null if it doesn't not set.
      • support

        public static MTC.TraceSurroundings support​(Span startSpan)
        Attach given span to current thread if it isn't null or NOOP_SPAN. Detach given span, close it and return previous span when MTC.TraceSurroundings.close() would be called.
        Parameters:
        startSpan - Span which should be added to current thread.
        Returns:
        MTC.TraceSurroundings for manage span life cycle or null in case of null or no-op span.
      • supportInitial

        public static void supportInitial​(Span startSpan)
        Support initial span.
        Parameters:
        startSpan - Span which should be added to current thread.
      • supportContinual

        public static MTC.TraceSurroundings supportContinual​(Span startSpan)
        Attach given span to current thread if it isn't null or NOOP_SPAN.
        Parameters:
        startSpan - Span which should be added to current thread.
        Returns:
        MTC.TraceSurroundings for manage span life cycle or null in case of null or no-op span.