INNER CODE UNIT · Python

_close_proxy_http_bridge_sessions_for_shutdown

Soju06/codex-lb · app/main.py:267

async def _close_proxy_http_bridge_sessions_for_shutdown(
    proxy_service: Any,
    *,
    mark_draining: bool,
) -> bool:
    """Close bridge resources and report whether that database-owning step completed.

    Bridge teardown owns durable leases and can enqueue persistence work.  A
    failed mark/close must therefore suppress the SQLite ``clean`` marker even
    when the later persistence drain and engine disposal happen to complete.
    ``None`` remains a successful result for older/test service doubles; the
    concrete service returns ``True`` or ``False`` explicitly.
    """
    if proxy_service is None:
        return True

    bridge_sessions_drained = True
    if mark_draining and hasattr(proxy_service, "mark_http_bridge_draining"):

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…