Skip to content

Commit e21624b

Browse files
committed
Merge branch 'master' into bugfix-tracing-exemplars
2 parents f45ebaa + a0d9481 commit e21624b

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

packages/service-library/src/servicelib/background_task_utils.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
from collections.abc import Callable, Coroutine
44
from typing import Any, ParamSpec, TypeVar
55

6+
from servicelib.exception_utils import silence_exceptions
7+
from servicelib.redis._errors import CouldNotAcquireLockError
8+
69
from .background_task import periodic
710
from .redis import RedisClientSDK, exclusive
811

@@ -36,6 +39,11 @@ def _decorator(
3639
coro: Callable[P, Coroutine[Any, Any, None]],
3740
) -> Callable[P, Coroutine[Any, Any, None]]:
3841
@periodic(interval=retry_after)
42+
@silence_exceptions(
43+
# Replicas will raise CouldNotAcquireLockError
44+
# SEE https://github.com/ITISFoundation/osparc-simcore/issues/7574
45+
(CouldNotAcquireLockError,)
46+
)
3947
@exclusive(
4048
redis_client,
4149
lock_key=f"lock:exclusive_periodic_task:{coro.__module__}.{coro.__name__}",

0 commit comments

Comments
 (0)