mosquito / aio-pika

AMQP 0.9 client designed for asyncio and humans.
https://aio-pika.readthedocs.org/
Apache License 2.0
1.18k stars 186 forks source link

Does no_ack default value False means messages are automatically acknowledged? #519

Open catherinejarvisanalytics opened 1 year ago

catherinejarvisanalytics commented 1 year ago

Getting confused with the documentations online for no_ack image

Does no_ack default value False means messages are automatically acknowledged? Or do we have to set it to True for auto ack?

Thanks for the clarification. @mosquito

mosquito commented 1 year ago

As far as I understand, you are not reading the documentation for this library, and of course, in the another implementation may be another default.

You can use queue.consume(..., no_ack=True) if you are using callbacks, or queue.iterator(no_ack=True) if you are using an iterator.

catherinejarvisanalytics commented 1 year ago

@mosquito Oh I thought this is the right documentation. https://buildmedia.readthedocs.org/media/pdf/aio-pika/latest/aio-pika.pdf

So you are saying no_ack=True means Message Acknowledged? Appreciate your response!

mosquito commented 1 year ago

"Message acknowledgments are turned on by default" - means you have to send acknowledgment by default.