fix(openviking): stop pending runtime start on shutdown

This commit is contained in:
Hao Zhe 2026-07-14 12:58:22 +08:00 committed by kshitij
parent c4d0f1c1d6
commit cf0bd5dd4c
2 changed files with 44 additions and 1 deletions

View file

@ -2201,7 +2201,8 @@ class OpenVikingMemoryProvider(MemoryProvider):
should_start_waiter = False
with self._runtime_start_lock:
if (
self._runtime_start_pending
self._shutting_down
or self._runtime_start_pending
or (self._runtime_start_thread and self._runtime_start_thread.is_alive())
):
self._client = None
@ -2234,6 +2235,8 @@ class OpenVikingMemoryProvider(MemoryProvider):
if should_start_waiter:
with self._runtime_start_lock:
self._runtime_start_pending = False
if self._shutting_down:
return
self._start_runtime_openviking_waiter(
status_callback=status_callback,
warning_callback=warning_callback,