OTLP gRPC exporter reads RetryInfo only from the google.rpc.retryinfo-bin trailer, not from the status details
Maintainer antworten meist innerhalb von 2 Tagen
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 72/100
- Issue-Typ
- Bug
- Klarheit
- Klar beschrieben
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- grpc, python
- Bereich
- backend-api-design
Rechercherichtung
Start in exporter/opentelemetry-exporter-otlp-proto-grpc/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py around the RetryInfo trailer handling at lines 432–440. Read the gRPC status details handling and the test in exporter/opentelemetry-exporter-otlp-proto-grpc/tests/test_otlp_exporter_mixin.py, which currently mocks only google.rpc.retryinfo-bin. Done means RetryInfo in grpc-status-details-bin sets the retry delay, with the existing trailer behavior covered as a fallback.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Describe your environment
opentelemetry-exporter-otlp-proto-grpc 1.45.2 (the code is the same on main).
What happened?
The OTLP gRPC exporter reads the server's RetryInfo only from a trailer named google.rpc.retryinfo-bin:
The OTLP specification tells a server to send RetryInfo as a detail of the gRPC status (Failures, OTLP/gRPC Throttling). Its sample server code uses status.New(...).WithDetails(&errdetails.RetryInfo{...}). gRPC sends those details in the grpc-status-details-bin trailer, as an encoded google.rpc.Status. A server that follows the specification, such as one written with grpc-go or the OpenTelemetry Collector's receiver, sends no google.rpc.retryinfo-bin trailer.
So the Python exporter never sees the delay that such a server asks for. It falls back to its own backoff of 2**n * uniform(0.8, 1.2) seconds. The OTel Go SDK, the Collector's exporter and the .NET exporter read the delay from the status details.
Steps to Reproduce
- Run a gRPC OTLP server whose
ExportreturnsUNAVAILABLE(orRESOURCE_EXHAUSTED) built withstatus.New(code, msg).WithDetails(&errdetails.RetryInfo{RetryDelay: durationpb.New(3 * time.Second)}). - Export a span with
OTLPSpanExporterto it. - Log the time of each attempt on the server.
Expected Result
The exporter waits the 3 s that RetryInfo asks for before it retries.
Actual Result
The exporter retries after about 1 s, then 2 s, then 4 s: its own backoff. The RetryInfo in grpc-status-details-bin is ignored.
Additional context
A fix could decode grpc-status-details-bin as google.rpc.status_pb2.Status (or use grpc_status.rpc_status.from_call), take the RetryInfo from its details, and keep the google.rpc.retryinfo-bin lookup as a fallback. The test at exporter/opentelemetry-exporter-otlp-proto-grpc/tests/test_otlp_exporter_mixin.py mocks only the google.rpc.retryinfo-bin trailer.
- Vorherrschende Sprache
- Python
- Sterne
- 2.7k
- Forks
- 1.1k
- Ø Merge
- 4 T. 13 Min.
- Gemergte PRs (30 T.)
- 38
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus open-telemetry/opentelemetry-python
-
opentelemetry-configuration: OTLP HTTP exporter does not validate TLS files exist at startupEvtl. vergeben @Dotify71 hat das vor 5 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
open-telemetry/opentelemetry-python#5928 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
W3CBaggagePropagator drops a list-member over 4096 bytes that W3C Baggage requires it to propagateEvtl. vergeben @codedbyadiiii hat das vor 8 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 70/100
open-telemetry/opentelemetry-python#5913 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
otel.sdk.processor.{span,log}.queue.capacity uses synchronous UpDownCounter recorded once in __init__Evtl. wieder frei Ein Pull Request dazu wurde ohne Merge geschlossen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
open-telemetry/opentelemetry-python#5891 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
Prometheus map_unit incorrectly normalizes percent ratio units such as %/sEvtl. vergeben @knowprasad hat das vor 10 Tagen übernommen. Offenbug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
open-telemetry/opentelemetry-python#5875 · 1 Kommentar · 1 Reaktion ·
Maintainer antworten meist innerhalb von 2 Tagen
-
OTLP HTTP exporter reports a 3xx response as a successful export, so redirected batches are dropped without any logEvtl. vergeben @d4rshnn hat das vor 18 Tagen übernommen. Offenbug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
open-telemetry/opentelemetry-python#5865 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 2 Tagen
Alle Issues in open-telemetry/opentelemetry-python
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 65/100
Deltares/numba_celltree#100 · 1 Kommentar ·
-
auto-reported bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 63/100
Maintainer antworten meist innerhalb von 1 Tag
-
soup airgap-bundle --bundle-size-cap nan, inf or a cap above ~1.67e299 GiB stops with an internal ValueError/OverflowError (exit 1) instead of a usage errorEvtl. vergeben @Keshemir hat das heute übernommen. Offenbug claimed difficulty:2
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
MakazhanAlpamys/Soup#3045 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
dagster-io/skills#80 ·
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag