Re:Python Asyncio: The Complete Guide
by jerrygenser on Thursday November 10, 2022 @07:37PM
(#33555862)
Rest APIs and websites are IO bound. Your python program is there purely coordinating between disk io, database (network) io, calls to other services (io). You can be choreographing thousands of requests concurrently and still barely doing any cpu.
The overhead to do a similar service using threadpools is much higher and the reason asyncio exists.
The overhead to do a similar service using threadpools is much higher and the reason asyncio exists.