{
  "description": "The Adaptive Tail Sampling Processor performs adaptive trace sampling using first-match rules-based routing to adaptive samplers. Each sampler produces a known sample rate which is encoded as `ot=th` in W3C TraceState for correct downstream metric weighting.",
  "display_name": "Adaptive Tail Sampling Processor",
  "distribution": "contrib",
  "ecosystem": "collector",
  "id": "contrib-adaptivetailsamplingprocessor",
  "markdown_hash": "d2f85e143895",
  "name": "adaptivetailsamplingprocessor",
  "repository": "opentelemetry-collector-contrib",
  "status": {
    "class": "processor",
    "codeowners": {
      "active": [
        "MikeGoldsmith",
        "VinozzZ",
        "jmacd"
      ]
    },
    "distributions": [
      "contrib"
    ],
    "stability": {
      "alpha": [
        "traces"
      ]
    }
  },
  "telemetry": {
    "metrics": {
      "processor_adaptive_tail_sampling_decision_sample_rate": {
        "description": "Distribution of effective sample rates produced per rule. Useful for detecting adaptive samplers settling at unexpected rates.",
        "enabled": true,
        "histogram": {
          "value_type": "int"
        },
        "stability": "development",
        "unit": "{rate}"
      },
      "processor_adaptive_tail_sampling_decision_triggers": {
        "description": "Number of trace decisions made, labelled by which event triggered the decision (root_span, trace_timeout, eviction, shutdown, span_limit).",
        "enabled": true,
        "stability": "development",
        "sum": {
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{decisions}"
      },
      "processor_adaptive_tail_sampling_fingerprint_duration": {
        "description": "Time spent extracting a rule's fingerprint per decision, in microseconds, labelled by rule. A relative signal for spotting expensive fingerprints (wide scopes such as any. on large traces); absolute values depend on host and load.",
        "enabled": true,
        "histogram": {
          "value_type": "int"
        },
        "stability": "development",
        "unit": "us"
      },
      "processor_adaptive_tail_sampling_fleet_member_count": {
        "description": "Current fleet member count reported by the fleet_tracker extension; the processor divides each rule's goal_throughput by this value. Not emitted when fleet_tracker is unset.",
        "enabled": true,
        "gauge": {
          "value_type": "int"
        },
        "stability": "development",
        "unit": "{instances}"
      },
      "processor_adaptive_tail_sampling_fleet_tracker_errors": {
        "description": "Number of non-positive member counts received from the fleet tracker; the last good count is kept.",
        "enabled": true,
        "stability": "development",
        "sum": {
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{errors}"
      },
      "processor_adaptive_tail_sampling_incoming_tracestate_unparseable": {
        "description": "Number of spans whose incoming W3C tracestate could not be parsed when applying the sampling threshold.",
        "enabled": true,
        "stability": "development",
        "sum": {
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{spans}"
      },
      "processor_adaptive_tail_sampling_ottl_eval_errors": {
        "description": "Number of OTTL condition evaluation errors, labelled by the rule the condition belongs to (_root_span_condition for the root-span condition).",
        "enabled": true,
        "stability": "development",
        "sum": {
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{errors}"
      },
      "processor_adaptive_tail_sampling_sampler_burst_count": {
        "description": "Cumulative number of intervals in which an adaptive sampler (adaptive_percentage or adaptive_throughput) detected a burst of traffic, labelled by rule, sampler_type, and sampler_algorithm. Not emitted for adaptive_throughput rules using the windowed algorithm, which do not track this counter.",
        "enabled": true,
        "stability": "development",
        "sum": {
          "async": true,
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{bursts}"
      },
      "processor_adaptive_tail_sampling_sampler_keyspace_size": {
        "description": "Current number of distinct sampling keys tracked by an adaptive sampler (adaptive_percentage or adaptive_throughput), labelled by rule, sampler_type, and sampler_algorithm. A rising value indicates growing key cardinality, which can degrade sampler accuracy and memory use.",
        "enabled": true,
        "gauge": {
          "async": true,
          "value_type": "int"
        },
        "stability": "development",
        "unit": "{keys}"
      },
      "processor_adaptive_tail_sampling_sampler_request_count": {
        "description": "Cumulative number of sample-rate requests made to an adaptive sampler (adaptive_percentage or adaptive_throughput) since it started, labelled by rule, sampler_type, and sampler_algorithm.",
        "enabled": true,
        "stability": "development",
        "sum": {
          "async": true,
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{requests}"
      },
      "processor_adaptive_tail_sampling_trace_span_count": {
        "description": "Distribution of buffered span counts per trace at decision time, labelled by rule. Useful for sizing span_limit against the real trace-size distribution.",
        "enabled": true,
        "histogram": {
          "value_type": "int"
        },
        "stability": "development",
        "unit": "{spans}"
      },
      "processor_adaptive_tail_sampling_traces_active": {
        "description": "Number of traces currently in the accumulation buffer awaiting a decision.",
        "enabled": true,
        "gauge": {
          "value_type": "int"
        },
        "stability": "development",
        "unit": "{traces}"
      },
      "processor_adaptive_tail_sampling_traces_dropped": {
        "description": "Number of traces that were dropped, labelled by the rule that selected them. Sentinel rule values are prefixed with an underscore (e.g. _unmatched, _eviction).",
        "enabled": true,
        "stability": "development",
        "sum": {
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{traces}"
      },
      "processor_adaptive_tail_sampling_traces_evicted": {
        "description": "Number of traces evicted from the buffer due to num_traces pressure. Evicted traces are decided immediately per the configured eviction policy.",
        "enabled": true,
        "stability": "development",
        "sum": {
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{traces}"
      },
      "processor_adaptive_tail_sampling_traces_sampled": {
        "description": "Number of traces that were sampled, labelled by the rule that selected them. Sentinel rule values are prefixed with an underscore (e.g. _eviction).",
        "enabled": true,
        "stability": "development",
        "sum": {
          "monotonic": true,
          "value_type": "int"
        },
        "unit": "{traces}"
      }
    }
  },
  "type": "processor"
}