[Doc] Correct the SessionClosed admission-slot guarantee (#7636 Issue 22) (#7869)

Signed-off-by: yanbao1217 <yanliuwebsite493@gmail.com>
Co-authored-by: yanbao1217 <yanliuwebsite493@gmail.com>
This commit is contained in:
yanbao1217andyanbao1217 authored and GitHub committed 2026-09-22 14:57:50 +00:00
1 parent d278aa8057
commit ca14e635f5
2 files changed
+11 -5

No files matched your search

+6 -3
View File
@@ -604,9 +604,12 @@ class DuplexSessionManager:
The session keeps its admission slot (``_closing``) until stage cleanup
succeeded; a failed cleanup is retried by the reaper. For an explicit
close the ``session.closed`` event is emitted only after the cleanup
attempt, so a client that sees it can open a replacement session at
once (the runner used to emit it before the stage requests were
aborted, which let a prompt reopen hit ``resource_exhausted``).
attempt, in a ``finally``, including when the cleanup failed (the
runner used to emit it before the stage requests were aborted). A
client that sees the event can normally open a replacement session
right away, but after a failed cleanup the slot is still held until
the reaper succeeds, so a prompt reopen can be refused with
``resource_exhausted``.
"""
session = runner.session
submitted = tuple(session.resource_request_ids(submitted=True))