pulp / pulp/pulpcore

WARNING: An instrument with name ... already exists

Open
#4,993 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Issue
Dominant language
Python
Stars
598
Forks
168
Avg merge
1d 4h
Merged PRs (30d)
86

Description

Version
3.44.1

Describe the bug

Warnings are constantly emitted in the content app logs.

pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:20 +0000] "GET /pulp/content/foo/foo/gems/regexp_parser-2.9.0.gem HTTP/1.1" 200 59227 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:20 +0000] "GET /pulp/content/foo/foo/gems/rack-test-2.1.0.gem HTTP/1.1" 200 21841 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:20 +0000] "GET /pulp/content/foo/foo/gems/mini_mime-1.1.5.gem HTTP/1.1" 200 36181 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:20 +0000] "GET /pulp/content/foo/foo/gems/matrix-0.4.2.gem HTTP/1.1" 200 27958 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:21 +0000] "GET /pulp/content/foo/foo/gems/public_suffix-5.0.4.gem HTTP/1.1" 200 103787 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:21 +0000] "GET /pulp/content/foo/foo/gems/addressable-2.8.6.gem HTTP/1.1" 200 107893 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:21 +0000] "GET /pulp/content/foo/foo/gems/capybara-3.40.0.gem HTTP/1.1" 200 384893 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:21 +0000] "GET /pulp/content/foo/foo/quick/Marshal.4.8/bowser-1.1.0.gemspec.rz HTTP/1.1" 200 1257 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:21 +0000] "GET /pulp/content/foo/foo/gems/beryl-0.3.1.gem HTTP/1.1" 200 17712 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:21 +0000] "GET /pulp/content/foo/foo/gems/bowser-1.1.0.gem HTTP/1.1" 200 25389 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.active_requests, type UpDownCounter, unit requests and description measures the number of concurrent HTTP requests those are currently in flight has been created already.
::ffff:10.129.16.9 [29/Jan/2024:21:40:21 +0000] "GET /pulp/content/foo/foo/latest_specs.4.8.gz HTTP/1.1" 200 1521682 "-" "Ruby, RubyGems/3.4.10 x86_64-linux Ruby/3.2.2 (2023-03-30 patchlevel 53)"
pulp [None]: opentelemetry.sdk.metrics._internal:WARNING: An instrument with name http.server.duration, type Histogram, unit ms and description measures the duration of the inbound HTTP request has been created already.

THe command used to start the service is:

/usr/local/bin/opentelemetry-instrument --service_name pulp-content --exporter_otlp_endpoint http://pulp-otel-collector-svc:4318 --exporter_otlp_insecure true pulpcore-content --access-logfile -

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the warnings with the documented /usr/local/bin/opentelemetry-instrument ... pulpcore-content --access-logfile - command and inspect the repeated http.server.duration and http.server.active_requests messages. Trace the pulpcore-content entry point and its OpenTelemetry instrumentation; done means requests no longer produce repeated duplicate-instrument warnings.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
observability
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.