Interface TracerBuilder


public interface TracerBuilder
Builder class for creating Tracer instances.

Tracers are identified by their scope name, version, and schema URL. These identifying fields, along with attributes, combine to form the instrumentation scope, which is attached to all spans produced by the Tracer.

Since:
1.4.0
  • Method Details

    • setSchemaUrl

      TracerBuilder setSchemaUrl(String schemaUrl)
      Set the scope schema URL of the resulting Tracer. Schema URL is part of Tracer identity.
      Parameters:
      schemaUrl - The schema URL.
      Returns:
      this
    • setInstrumentationVersion

      TracerBuilder setInstrumentationVersion(String instrumentationScopeVersion)
      Sets the instrumentation scope version of the resulting Tracer. Version is part of Tracer identity.
      Parameters:
      instrumentationScopeVersion - The instrumentation scope version.
      Returns:
      this
    • build

      Tracer build()
      Gets or creates a Tracer instance.
      Returns:
      a Tracer instance configured with the provided options.