stan.py
stan.py copied to clipboard
Drain mode
Is there a way to figure out if a subscriber has drained all the messages in a given channel and is caught up? I would still want to process all the messages, but change behavior once have seen all the messages in the channel.
In this PR I’m adding a ‘pending_queue_size’ method to the subscription so that it is possible to check how far behind is the consumer https://github.com/nats-io/asyncio-nats-streaming/pull/21