more fixes, plug shutdown handlers

still, FastAPIs sigint handler is not calling ours
This commit is contained in:
Ashwin Bharambe 2024-10-05 23:48:18 -07:00 committed by Ashwin Bharambe
parent 60dead6196
commit e45a417543
4 changed files with 32 additions and 12 deletions

View file

@ -42,7 +42,8 @@ class CommonRoutingTableImpl(RoutingTable):
await self.register_object(obj, p)
async def shutdown(self) -> None:
pass
for p in self.impls_by_provider_id.values():
await p.shutdown()
def get_provider_impl(self, routing_key: str) -> Any:
if routing_key not in self.routing_key_to_object: