Audience
Developers searching for a library to write concurrent code using the async/await syntax
About asyncio
asyncio is used as a foundation for multiple Python asynchronous frameworks that provide high-performance network and web-servers, database connection libraries, distributed task queues, etc. asyncio is often a perfect fit for IO-bound and high-level structured network code.
Other Popular Alternatives & Related Software
Tornado Web Server
Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed. By using non-blocking network I/O, Tornado can scale to tens of thousands of open connections, making it ideal for long polling, WebSockets, and other applications that require a long-lived connection to each user. Tornado is different from most Python web frameworks. It is not based on WSGI, and it is typically run with only one thread per process. While some support of WSGI is available in the tornado.wsgi module, it is not a focus of development and most applications should be written to use Tornadoโs own interfaces (such as tornado.web) directly instead of using WSGI. In general, Tornado code is not thread-safe. Tornado is integrated with the standard library asyncio module and shares the same event loop (by default since Tornado 5.0). In general, libraries designed for use with asyncio can be mixed freely with Tornado.
Learn more
websockets
An implementation of the WebSocket Protocol (RFC 6455 & 7692). websockets is a library for building WebSocket servers and clients in Python with a focus on correctness, simplicity, robustness, and performance. Built on top of asyncio, Pythonโs standard asynchronous I/O framework, it provides an elegant coroutine-based API. websockets is heavily tested for compliance with RFC 6455. Continuous integration fails under 100% branch coverage. websockets is built for production. For example, it was the only library to handle backpressure correctly before the issue became widely known in the Python community. Memory usage is optimized and configurable. A C extension accelerates expensive operations. Itโs pre-compiled for Linux, macOS, and Windows and packaged in the wheel format for each system and Python version. websockets takes care of everything under the hood so you can focus on your application!
Learn more
Falcon
Falcon is a blazing fast, minimalist Python web API framework for building robust app backends and microservices. The framework works great with both asyncio (ASGI) and gevent/meinheld (WSGI). The Falcon web framework encourages the REST architectural style. Resource classes implement HTTP method handlers that resolve requests and perform state transitions. Falcon complements more general Python web frameworks by providing extra reliability, flexibility, and performance wherever you need it. A number of Falcon add-ons, templates, and complementary packages are available for use in your projects. We've listed several of these on the Falcon wiki as a starting point, but you may also wish to search PyPI for additional resources.
Learn more
Growler
Growler is a web framework built atop asyncio, the asynchronous library described in PEP 3156 and added to the standard library in python 3.4. It takes a cue from the Connect & Express frameworks in the nodejs ecosystem, using a single application object and series of middleware to process HTTP requests. The custom chain of middleware provides an easy way to implement complex applications. The pip utility allows packages to provide optional requirements, so features may be installed only upon request. This meshes well with the minimal nature of the Growler project: don't install anything the user doesn't need. That being said, there are (will be) community packages that are blessed by the growler developers (after ensuring they work as expected and are well tested with each version of growler) that will be available as extras directly from the growler package.
Learn more
Integrations
Company Information
asyncio
docs.python.org/3/library/asyncio.html
Other Useful Business Software
MongoDB Atlas runs apps anywhere
MongoDB Atlas gives you the freedom to build and run modern applications anywhereโacross AWS, Azure, and Google Cloud. With global availability in over 115 regions, Atlas lets you deploy close to your users, meet compliance needs, and scale with confidence across any geography.
Product Details
Platforms Supported
Cloud
Training
Documentation
Support
Online