Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 36aaa84

Browse files
authored
fix: timeout period when acquiring grpc exporter lock on shutdown (open-telemetry#3524)
1 parent 3d9de97 commit 36aaa84

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## Unreleased
99

10-
## Version 1.21.0/0.42b0 (2023-11-07)
10+
- Fix OTLPExporterMixin shutdown timeout period
11+
([#3524](https://github.com/open-telemetry/opentelemetry-python/pull/3524))
12+
13+
## Version 1.21.0/0.42b0 (2023-11-01)
1114

1215
- Fix `SumAggregation`
1316
 ([#3390](https://github.com/open-telemetry/opentelemetry-python/pull/3390))

exporter/opentelemetry-exporter-otlp-proto-grpc/src/opentelemetry/exporter/otlp/proto/grpc/exporter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ def shutdown(self, timeout_millis: float = 30_000, **kwargs) -> None:
322322
logger.warning("Exporter already shutdown, ignoring call")
323323
return
324324
# wait for the last export if any
325-
self._export_lock.acquire(timeout=timeout_millis)
325+
self._export_lock.acquire(timeout=timeout_millis / 1e3)
326326
self._shutdown = True
327327
self._export_lock.release()
328328

0 commit comments

Comments
 (0)