[PD][PushConnector] Record last activity of remotes to allow clean up of stale ones (#50234)
Signed-off-by: NickLucche <nicolo.lucchesi@mistral.ai>
This commit is contained in:
@@ -2560,8 +2560,7 @@ class NixlBaseConnectorWorker:
|
||||
|
||||
# Drop the cached clock offset; it is re-measured on the next handshake.
|
||||
self._engine_clock_offset.pop(engine_id, None)
|
||||
# Push P-side engines are tracked in _remote_agents but not in
|
||||
# _engine_last_active (they don't participate in stale eviction), so
|
||||
# A just-completed handshake may not have recorded activity yet, so
|
||||
# tolerate a missing entry.
|
||||
last_active = self._engine_last_active.pop(engine_id, None)
|
||||
if log_eviction and last_active is not None:
|
||||
|
||||
@@ -450,6 +450,9 @@ class NixlPushConnectorWorker(NixlBaseConnectorWorker):
|
||||
|
||||
fut.add_done_callback(_on_handshake)
|
||||
return
|
||||
# Keep the engine alive while it is actively receiving pushes, mirroring
|
||||
# how pull-mode transfers touch _engine_last_active in start_load_kv.
|
||||
self._engine_last_active[decode_engine_id] = time.perf_counter()
|
||||
|
||||
# Both sides stay logical here; ``_xfer_blocks_for_req`` converts each
|
||||
# to physical with its own physical-blocks-per-logical ratio -- P uses
|
||||
|
||||
Reference in New Issue
Block a user