java.lang.Object
io.helidon.nima.webserver.tracing.TracingFeature
All Implemented Interfaces:
Weighted, HttpFeature, ServerLifecycle, Comparable<Weighted>, Supplier<HttpFeature>

public class TracingFeature extends Object implements HttpFeature, Weighted
Tracing configuration for webserver. Tracing configuration has two components - an overall (application wide) TracingConfig and a path specific PathTracingConfig.
  • Method Details

    • create

      public static TracingFeature create(Tracer tracer)
      Create a tracing configuration that is enabled for all paths and spans (that are enabled by default).
      Parameters:
      tracer - tracer to use for tracing spans created by this feature
      Returns:
      tracing configuration to register with HttpRouting.Builder.register(java.util.function.Supplier[])
    • create

      public static TracingFeature create(Tracer tracer, TracingConfig configuration)
      Create a new tracing support base on TracingConfig.
      Parameters:
      tracer - tracer to use for tracing spans created by this feature
      configuration - traced system configuration
      Returns:
      a new tracing support to register with web server routing
    • create

      public static TracingFeature create(Tracer tracer, Config config)
      Create a new tracing support base on Config.
      Parameters:
      tracer - tracer to use for tracing spans created by this feature
      config - to base this support on
      Returns:
      a new tracing support to register with web server routing
    • builder

      public static TracingFeature.Builder builder()
      A fluent API builder to create tracing support.
      Returns:
      a new builder instance
    • setup

      public void setup(HttpRouting.Builder routing)
      Description copied from interface: HttpFeature
      Method to set up a feature.
      Specified by:
      setup in interface HttpFeature
      Parameters:
      routing - routing builder
    • weight

      public double weight()
      Description copied from interface: Weighted
      Weight of this class (maybe because it is defined dynamically, so it cannot be defined by an annotation). If not dynamic, you can use the Weight annotation rather than implementing this interface as long as it is supported by the library using this Weighted.
      Specified by:
      weight in interface Weighted
      Returns:
      the weight of this service, must be a non-negative number