Skip to content

Commit 96a86da

Browse files
Change lock type to RLock in metric_reader_storage
Replaced Lock with RLock for better handling of nested locks.
1 parent ad480b8 commit 96a86da

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

opentelemetry-sdk/src/opentelemetry/sdk/metrics/_internal/metric_reader_storage.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ def __init__(
7777

7878
def _at_fork_reinit(self) -> None:
7979
"""Reinitialize locks and clear state in the child process after fork."""
80-
self._lock = Lock()
80+
self._lock = RLock()
8181
self._instrument_view_instrument_matches.clear()
8282

8383
def _get_or_init_view_instrument_match(

0 commit comments

Comments
 (0)