set channel queue maxsize to 32

This commit is contained in:
Timothy Pogue 2022-10-09 15:11:58 -06:00
parent 3e8d8fd1b0
commit 2f64a08623

View File

@ -35,7 +35,7 @@ class WebSocketChannel:
self._serializer_cls = serializer_cls self._serializer_cls = serializer_cls
self._subscriptions: List[str] = [] self._subscriptions: List[str] = []
self.queue: asyncio.Queue[Dict[str, Any]] = asyncio.Queue() self.queue: asyncio.Queue[Dict[str, Any]] = asyncio.Queue(maxsize=32)
self._relay_task = asyncio.create_task(self.relay()) self._relay_task = asyncio.create_task(self.relay())
# Internal event to signify a closed websocket # Internal event to signify a closed websocket