INNER CODE UNIT · Python
_ensure_web_asset_mime_types
Soju06/codex-lb · app/main.py:171
def _ensure_web_asset_mime_types() -> None:
for extension, mime_type in _WEB_ASSET_MIME_TYPES.items():
mimetypes.add_type(mime_type, extension)
_ensure_web_asset_mime_types()
async def run_http_bridge_heartbeat_maintenance(proxy_service: Any) -> None:
"""Per-replica bridge upkeep driven by the ring heartbeat.
All passes are request-independent by design: durable ownership must be
reconciled even on a replica nothing is routing to, and the idle sweep is
otherwise only reached from ``_get_or_create_http_bridge_session``, so a
replica that stops taking bridge requests would keep its idle sessions'
upstream WebSockets open until restart (issue #1354). Each pass is isolated
so one failing cannot skip the others or stop the heartbeat.
"""