mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-06-23 15:30:34 -04:00
Process 20 messages at the same time
This commit is contained in:
parent
52380bcb29
commit
8da6085df0
@ -49,4 +49,7 @@ class Subscriber:
|
||||
else:
|
||||
await message.nack(requeue=False)
|
||||
|
||||
await self._queue.consume(on_message, no_ack=True)
|
||||
# Allow up to 20 scan requests to run in parallel on the same listener.
|
||||
# Since most work is calling API not doing that is a waste.
|
||||
await self._channel.set_qos(prefetch_count=20)
|
||||
await self._queue.consume(on_message)
|
||||
|
Loading…
x
Reference in New Issue
Block a user