Class AbstractSpanDecorator

java.lang.Object
org.apache.camel.telemetry.decorators.AbstractSpanDecorator
All Implemented Interfaces:
SpanDecorator
Direct Known Subclasses:
AbstractHttpSpanDecorator, AbstractInternalSpanDecorator, AbstractMessagingSpanDecorator, CqlSpanDecorator, ElasticsearchSpanDecorator, FileSpanDecorator, JdbcSpanDecorator, LogSpanDecorator, MongoDBSpanDecorator, ProcessorSpanDecorator, SqlSpanDecorator, TimerSpanDecorator

public abstract class AbstractSpanDecorator extends Object implements SpanDecorator
An abstract base implementation of the SpanDecorator interface.
  • Constructor Details

    • AbstractSpanDecorator

      public AbstractSpanDecorator()
  • Method Details

    • stripSchemeAndOptions

      public static String stripSchemeAndOptions(org.apache.camel.Endpoint endpoint)
      This method removes the scheme, any leading slash characters and options from the supplied URI. This is intended to extract a meaningful name from the URI that can be used in situations, such as the operation name.
      Parameters:
      endpoint - The endpoint
      Returns:
      The stripped value from the URI
    • stripSchemeAndOptions

      public static String stripSchemeAndOptions(String endpointUri)
    • toQueryParameters

      public static Map<String,String> toQueryParameters(String uri)
    • getOperationName

      public String getOperationName(org.apache.camel.Exchange exchange, org.apache.camel.Endpoint endpoint)
      Specified by:
      getOperationName in interface SpanDecorator
    • beforeTracingEvent

      public void beforeTracingEvent(Span span, org.apache.camel.Exchange exchange, org.apache.camel.Endpoint endpoint)
      Specified by:
      beforeTracingEvent in interface SpanDecorator
    • afterTracingEvent

      public void afterTracingEvent(Span span, org.apache.camel.Exchange exchange)
      Specified by:
      afterTracingEvent in interface SpanDecorator
    • getExtractor

      public SpanContextPropagationExtractor getExtractor(org.apache.camel.Exchange exchange)
      Specified by:
      getExtractor in interface SpanDecorator
    • getInjector

      public SpanContextPropagationInjector getInjector(org.apache.camel.Exchange exchange)
      Specified by:
      getInjector in interface SpanDecorator