Skip to content

Conversation

@AnmolxSingh
Copy link
Contributor

Which problem is this PR solving?

Description of the changes

  • jtracer replaced with otel collector tracer

How was this change tested?

Checklist

Signed-off-by: anmol7344 <[email protected]>
@codecov
Copy link

codecov bot commented Oct 5, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 96.58%. Comparing base (300b511) to head (2235723).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7542      +/-   ##
==========================================
- Coverage   96.58%   96.58%   -0.01%     
==========================================
  Files         384      384              
  Lines       19404    19389      -15     
==========================================
- Hits        18742    18727      -15     
  Misses        478      478              
  Partials      184      184              
Flag Coverage Δ
badger_v1 8.83% <ø> (ø)
badger_v2 1.74% <ø> (ø)
cassandra-4.x-v1-manual 12.56% <ø> (ø)
cassandra-4.x-v2-auto 1.73% <ø> (ø)
cassandra-4.x-v2-manual 1.73% <ø> (ø)
cassandra-5.x-v1-manual 12.56% <ø> (ø)
cassandra-5.x-v2-auto 1.73% <ø> (ø)
cassandra-5.x-v2-manual 1.73% <ø> (ø)
clickhouse 1.66% <ø> (ø)
elasticsearch-6.x-v1 16.77% <ø> (ø)
elasticsearch-7.x-v1 16.80% <ø> (ø)
elasticsearch-8.x-v1 16.94% <ø> (ø)
elasticsearch-8.x-v2 1.74% <ø> (ø)
elasticsearch-9.x-v2 1.74% <ø> (ø)
grpc_v1 10.76% <ø> (ø)
grpc_v2 1.74% <ø> (ø)
kafka-3.x-v1 10.26% <ø> (ø)
kafka-3.x-v2 1.74% <ø> (ø)
memory_v2 1.74% <ø> (ø)
opensearch-1.x-v1 16.84% <ø> (ø)
opensearch-2.x-v1 16.84% <ø> (ø)
opensearch-2.x-v2 1.74% <ø> (ø)
opensearch-3.x-v2 1.74% <ø> (ø)
query 1.74% <ø> (ø)
tailsampling-processor 0.50% <ø> (ø)
unittests 95.48% <100.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Signed-off-by: anmol7344 <[email protected]>
Signed-off-by: anmol7344 <[email protected]>
}

func newServer(config *Config, otel component.TelemetrySettings) *server {
func newServer(config *Config, telemetry component.TelemetrySettings) *server {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we use the name telset

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes I noticed it in V1 codebase my bad.

@github-actions
Copy link

github-actions bot commented Oct 5, 2025

Metrics Comparison Summary

Total changes across all snapshots: 162

Detailed changes per snapshot

summary_metrics_snapshot_memory

📊 Metrics Diff Summary

Total Changes: 56

  • 🆕 Added: 0 metrics
  • ❌ Removed: 56 metrics
  • 🔄 Modified: 0 metrics

❌ Removed Metrics

  • http_server_request_body_size_bytes (18 variants)
View diff sample
-http_server_request_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="0",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="10",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="100",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="1000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="10000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="25",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
...
- `http_server_request_duration_seconds` (17 variants)
View diff sample
-http_server_request_duration_seconds{http_request_method="POST",http_response_status_code="200",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="POST",http_response_status_code="200",le="0.005",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="POST",http_response_status_code="200",le="0.01",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="POST",http_response_status_code="200",le="0.025",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="POST",http_response_status_code="200",le="0.05",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="POST",http_response_status_code="200",le="0.075",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="POST",http_response_status_code="200",le="0.1",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
...
- `http_server_response_body_size_bytes` (18 variants)
View diff sample
-http_server_response_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="0",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="10",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="100",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="1000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="10000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="POST",http_response_status_code="200",le="25",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="0.0.0.0",server_port="4318",url_scheme="http"}
...
- `otelcol_receiver_accepted_spans` (1 variants)
View diff sample
-otelcol_receiver_accepted_spans{otel_scope_name="go.opentelemetry.io/collector/receiver/receiverhelper",otel_scope_schema_url="",otel_scope_version="",receiver="otlp",transport="http"}
- `otelcol_receiver_failed_spans` (1 variants)
View diff sample
-otelcol_receiver_failed_spans{otel_scope_name="go.opentelemetry.io/collector/receiver/receiverhelper",otel_scope_schema_url="",otel_scope_version="",receiver="otlp",transport="http"}
- `otelcol_receiver_refused_spans` (1 variants)
View diff sample
-otelcol_receiver_refused_spans{otel_scope_name="go.opentelemetry.io/collector/receiver/receiverhelper",otel_scope_schema_url="",otel_scope_version="",receiver="otlp",transport="http"}
### summary_metrics_snapshot_cassandra ## 📊 Metrics Diff Summary

Total Changes: 53

  • 🆕 Added: 0 metrics
  • ❌ Removed: 53 metrics
  • 🔄 Modified: 0 metrics

❌ Removed Metrics

  • http_server_request_body_size_bytes (18 variants)
View diff sample
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="0",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="100",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="1000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="25",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
...
- `http_server_request_duration_seconds` (17 variants)
View diff sample
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.005",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.01",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.025",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.05",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.075",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.1",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
...
- `http_server_response_body_size_bytes` (18 variants)
View diff sample
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="0",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="100",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="1000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="25",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
...
### summary_metrics_snapshot_cassandra ## 📊 Metrics Diff Summary

Total Changes: 53

  • 🆕 Added: 0 metrics
  • ❌ Removed: 53 metrics
  • 🔄 Modified: 0 metrics

❌ Removed Metrics

  • http_server_request_body_size_bytes (18 variants)
View diff sample
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="0",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="100",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="1000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="25",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
...
- `http_server_request_duration_seconds` (17 variants)
View diff sample
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.005",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.01",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.025",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.05",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.075",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_request_duration_seconds{http_request_method="GET",http_response_status_code="503",le="0.1",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
...
- `http_server_response_body_size_bytes` (18 variants)
View diff sample
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="+Inf",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="0",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="100",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="1000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="10000",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
-http_server_response_body_size_bytes{http_request_method="GET",http_response_status_code="503",le="25",network_protocol_name="http",network_protocol_version="1.1",otel_scope_name="go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",otel_scope_schema_url="",otel_scope_version="0.63.0",server_address="localhost",server_port="13133",url_scheme="http"}
...

➡️ View full metrics file

Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see what this PR is changing, looks just cosmetic

@AnmolxSingh
Copy link
Contributor Author

AnmolxSingh commented Oct 6, 2025

I want to clarify — is it because JaegerQuery currently does not emit any spans?

My goal with this PR is to migrate to the OTEL collector tracer from jtracer, and I want to make sure I understand what would make this PR functional and non-cosmetic.

}
}(ctx)
// Getting Tracer from OTEL
tp = otel.GetTracerProvider()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you are not getting the tracer configured by OTEL collector, you're getting a global tracer, which may or may not be the same.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you mean i should define and configure the otel tracer here itself?
something like this?

res := resource.NewWithAttributes(
		semconv.SchemaURL,
		semconv.ServiceNameKey.String("jaeger-query"),
	)

exporter, err := otlptracegrpc.New(context.Background(),
    otlptracegrpc.WithEndpoint(endpoint),
    otlptracegrpc.WithInsecure(),
)
if err != nil {
   return fmt.Errorf("failed to create OTLP trace exporter", err)
}

tp := sdktrace.NewTracerProvider(
    sdktrace.WithBatcher(exporter),
    sdktrace.WithResource(res),
)

otel.SetTracerProvider(tp)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OTEL collector initializes all telemetry factories. The point of the ticket was that we shouldn't duplicate that initialization (which allows fewer customizations) and instead rely on the factories created by OTEL Collector framework.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

even i thought this (as it would just defy the purpose of the issue) i just wanted to clarify by asking as I got confused.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was looking at the Collector code and found this in service/service.go:
https://github.com/open-telemetry/opentelemetry-collector/blob/3b5555471b93052c4fbe4ef412d974a999d1b27f/service/service.go#L169

It seems like Service.New() initializes the tracerProvider via the telemetry factory.
For this issue, should we use this TracerProvider in Jaeger Query, or is there a different factory we should be referencing?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are already getting it via component.TelemetrySettings, so we should be using that's in there instead of creating our own. But we need to verify that we're getting the same traces in the end.

Signed-off-by: anmol7344 <[email protected]>
Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What testing have you done?

tp = jtracer.NoOp().OTEL
tp = noop.NewTracerProvider()

if s.config.EnableTracing {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need this setting? Can it not be controlled from telemetry section of otel config?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should it be removed from QueryOptions struct as well?

@AnmolxSingh
Copy link
Contributor Author

What testing have you done?

I believe that Jaeger Query does not emit spans with the current setup and if so should it be made to emit spans for testing purpose?

@yurishkuro
Copy link
Member

I believe that Jaeger Query does not emit spans with the current setup and if so should it be made to emit spans for testing purpose?

it always has, if you reload jaeger UI a few times you should see jaeger service in the dropdown. If not then something is broken.

@AnmolxSingh
Copy link
Contributor Author

if you reload jaeger UI a few times you should see jaeger service in the dropdown

Oh, I see! I was always running the Jaeger v1 all-in-one Docker image, so I hadn’t really never noticed the dropdown changes.

@AnmolxSingh
Copy link
Contributor Author

I tried testing Jaeger v2 locally by building the binary from cmd/jaeger, but it does not recognize the --config flag. I also didn’t see any reference to this in the documentation — it only mentions running v2 via YAML using the Docker image.
Could you clarify if local builds support YAML configuration, or would I need to make a docker image to test with a YAML file?

@yurishkuro
Copy link
Member

it makes no difference is you run a binary or docker image. Jaeger accepts --config parameter, the the examples of configs are in cmd/jaeger

@AnmolxSingh
Copy link
Contributor Author

it makes no difference is you run a binary or docker image

Oh sorry! Actually I misunderstood the error. I built Jaeger v2 from cmd/jaeger and tried to run it with config.yaml file but it fails due to some missing UI assets

ui assets not embedded in the binary, using a placeholder
error: open actual/index.html.gz: file does not exist

and

cannot read UI config file ./cmd/jaeger/config-ui.json

is there a make/generate step for embedding the UI into the binary when building locally?

@yurishkuro
Copy link
Member

make build-ui

@AnmolxSingh
Copy link
Contributor Author

Hi @yurishkuro
I wanted to update on the backend change I’ve been working on. I’ve tried testing it locally, but I’ve run into a blocker: the make build-ui step fails on my Windows machine due to Linux-specific build scripts and system limitations. As a result, I cannot run the backend with the UI locally to test end-to-end.

I’ve tried WSL and other options, but none worked in my environment. I understand from the scripts that Jaeger development is Linux-first. Given these constraints, could you advise the recommended workflow for contributors on Windows? Would it be acceptable to submit the backend change for review/testing on a Linux environment, or is there an alternative approach for testing?

Thank you for your guidance and time!

@yurishkuro
Copy link
Member

post the errors you're getting if you're asking for help.

did you initialize the ui submodule? the build-ui normally works by downloading the bundle from the release, you don't actually need to build anything.

@AnmolxSingh
Copy link
Contributor Author

did you initialize the ui submodule?

Ah! sorry for not posting the steps I performed earlier and thanks for the hint! I realized I hadn’t initialized the UI submodule, and after doing that, the make build-ui step worked as expected. I’m now able to run the backend with the UI locally.

@AnmolxSingh
Copy link
Contributor Author

AnmolxSingh commented Oct 10, 2025

I tested this pr and attaching the screenshots of the changes.

After changes from this pr

Screenshot 2025-10-10 141932

Even after refreshing several times I did not see Jaeger service in the dropdown.

Screenshot 2025-10-10 141907

Before changes from this pr

Screenshot 2025-10-10 141104

Jaeger service was always showing in the dropdown and showing traces even before sending traces from HotROD demo.

@AnmolxSingh
Copy link
Contributor Author

It seems this change currently breaks span collection for Jaeger service.

Steps to reproduce :-

  • run go build -o jaeger in the cmd/jaeger repo
  • run ./cmd/jaeger/jaeger --config=./cmd/jaeger/config.yaml from root folder
  • use the hotrod demo app for tracing

With this setup, I wasn't able to see spans being collected.

@yurishkuro
Copy link
Member

in main branch today:

$ JAEGER_VERSION=2.11.0 HOTROD_VERSION=1.74.0 docker compose up
image image

@AnmolxSingh
Copy link
Contributor Author

@yurishkuro
Yes, this is what I meant in my earlier message - before the changes from this PR, the jaeger service was showing up, but after applying the changes from this branch, it no longer appears. So it seems the changes aren’t working as expected.

@AnmolxSingh
Copy link
Contributor Author

@yurishkuro i enabled tracing for the collector in config.yaml and did local testing by building a binary.
Screenshot 2025-10-17 230541

jaeger service comes up in the dropdown

@AnmolxSingh AnmolxSingh marked this pull request as ready for review October 17, 2025 18:21
@AnmolxSingh AnmolxSingh requested a review from a team as a code owner October 17, 2025 18:21
@dosubot dosubot bot added the v2 label Oct 17, 2025
Copy link
Member

@yurishkuro yurishkuro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These traces are not supposed to be captured, they created infinity loop:
Image

}
}(ctx)
}
tp := s.telset.TracerProvider
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this variable necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not necessary we are already getting it

level: debug
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663
traces:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't this by default in this config, but in cmd/jaeger/internal/all-in-one.yaml

Copy link
Contributor Author

@AnmolxSingh AnmolxSingh Oct 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my bad, I remember you mentioned this even during the call.
I had a doubt in mind, if we are going to enable tracing then why only in all-in-one not all the config files? Does this approach give the user the option to enable the setting?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All in one historically came with tracing enabled 100%. For real production scenarios people can configure their own sampling.

@AnmolxSingh
Copy link
Contributor Author

AnmolxSingh commented Oct 18, 2025

@yurishkuro Thanks for the review so far! Appreciate your time and guidance.

These traces are not supposed to be captured, they created infinity loop:

I’ve been thinking about ways to handle this, but none seem ideal:

  • Disabling them via .yaml exposes an enable/disable option, which seems useless since these spans shouldn’t be captured at all.
  • Filtering them via built-in functions (if available) might require touching parts of the codebase that may not be worth it.
  • Initializing a no-op tracer for these spans could be an option. (But what I believe it may treat the entire exporter as off)

Would you recommend one of these approaches, or is there a better way to prevent this infinite loop?

Co-authored-by: Yuri Shkuro <[email protected]>
Signed-off-by: Anmol <[email protected]>
@yurishkuro
Copy link
Member

OTEL SDK doesn't make it particularly easy to control via configuration which trace points can result in spans and which should not. Technically it's possible to do that in the span processor or exporter but the preferred place would be Sampler. Does OTEL framework provide a way to customize the sampler? If not, one other alternative we could try is using Jaeger remote sampler where we set default sampling to be 0 but enable it for the API endpoints (it's more difficult to configure this way than implementing a sampler in the code).

Also, does OTEL Go SDK support file-based configuration? There has been work to allow configuring samplers via config, I don't know the status of that. Suggest you do some research.

@AnmolxSingh
Copy link
Contributor Author

AnmolxSingh commented Oct 23, 2025

@yurishkuro I looked into possible ways to handle this and found out:-

Technically it's possible to do that in the span processor or exporter but the preferred place would be Sampler. Does OTEL framework provide a way to customize the sampler?

I could not find anywhere that OTEL framework allows customizing sampler after initialization.(if you are referring to head based sampling)

Also, does OTEL Go SDK support file-based configuration?

This feature exists only for java, and it is experimental.

I think possible solution for now seems to be the Jaeger remote sampler. I have a doubt, though: would it work as head-based sampling for us in this case?

Or can we create a wrapper and override the span creation in query service if we cannot customize the sampler?(if its possible)

@yurishkuro
Copy link
Member

what would it take to have a hook in OTEL Collector that would allow us to customize the tracer?

@AnmolxSingh
Copy link
Contributor Author

I looked into this, and I think the cleanest way to allow customization of the TracerProvider in the OTEL Collector is to introduce a generic sampler hook. The likely place to implement this would be here (if I’m not mistaken):
https://github.com/open-telemetry/opentelemetry-collector/blob/0f3b0c974e235da85282c6d6ff5734e55e8f4fbc/service/telemetry/otelconftelemetry/tracer.go#L37

The idea would be:

  1. Collector exposes a package-level hook variable and a registration function:
var globalSamplerHook SamplerHook

func RegisterSamplerHook(hook SamplerHook) {
    globalSamplerHook = hook
}
  1. During TracerProvider creation (InitTracerProvider() / createTracerProvider()), the Collector wraps the sampler so that, for each span, it calls this hook if it’s registered:
sdktrace.WithSampler(sdktrace.ParentBased(sdktrace.SamplerFunc(func(p sdktrace.SamplingParameters) sdktrace.SamplingResult {
    if globalSamplerHook != nil {
        return globalSamplerHook(p)
    }
    return sdktrace.SamplingResult{Decision: sdktrace.RecordAndSample}
})))
  1. Jaeger Query can then register its hook early in startup, before the TracerProvider is initialized, to control which spans are created (e.g., drop exporter spans to avoid loops).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

jtracer from Jaeger-V2 should be removed

2 participants