Skip to content
This repository has been archived by the owner on May 31, 2021. It is now read-only.

Latest commit

 

History

History
26 lines (17 loc) · 716 Bytes

producer_consumer.rst

File metadata and controls

26 lines (17 loc) · 716 Bytes

Producer/consumer

Simple example

A simple producer/consumer example, using an asyncio.Queue:

.. literalinclude:: examples/producer_consumer.py


Using task_done()

A simple producer/consumer example, using Queue.task_done and Queue.join:

.. literalinclude:: examples/producer_consumer_join.py

For more information, see the asyncio queue documentation.