Remove Eventlet from OpenStack

OpenStack is built on the top of asynchronous mechanisms. Many Openstack deliverables use the Eventlet library to obtain asynchronous those asynchronous mechanisms. The problem is that Eventlet lacks of active maintainers and that has led the library to a point where Eventlet is broken with each new CPython version.

Asyncio based solutions (awaitlet, aiohttp, etc) offer flexible, perennial, and modern alteratives to Eventlet. Since the Eventlet Asyncio hub was released, allowing Eventlet and Asyncio to be run within the same process, the Eventlet community has encouraged the usage of those alternatives and the deprecation of any existing code still using Eventlet.

Champion

Gerrit Topic

To facilitate tracking, commits related to this goal should use the gerrit topic:

eventlet-removal

An etherpad has been created to track milestone and any related advancement by deliverable:

Completion Criteria

  1. (2025.1 or 2025.2) (if applicable) Get the oslo deliverables doing networkIO providing drivers and backends that do not require Eventlet. Indeed many oslo libraries provides alternative executors like threading, if one library is only based on Eventlet executor, then this library should provide alternative executor. The following libraries might be impacted by that: - oslo.cache; - oslo.messaging; - oslo.db; - etcd3gw; - oslo.metrics;

  2. (2025.1) Get libraries like OpenStackSDK migrated;

  3. (2025.2) Get an OpenStack deliverable as reference user project selected to test Oslo changes related to new Asyncio based drivers;

  4. (2025.2) Get non actively maintained OpenStack deliverables retired;

  5. (2026.2) Get all other OpenStack deliverables relying on Eventlet migrated;

  6. (2027.1) Get usage of Eventlet in oslo deliverables removed;

  7. (2027.2) Get Eventlet retired from OpenStack;

References

The main reference guide could be found in [1]. This guide provides information about how to migrate from Eventlet to the available alternatives.

From this same link, there is also a reference to identify alternatives for an existing snippet of code. This identification is based on table of correspondences [2] which aim to put solution in the front of the main Eventlet patterns [3].

This guide will be updated in the coming weeks to provide some migration examples for those patterns:

  • the server pattern;

  • the client pattern;

  • the dispatch pattern.

Replacing Eventlet usage requires more than just a drop-in replacement. The available alternatives are different and will require rethinking the way each module is designed in a way that precludes a blind or programmatic substitution.

As commented in the OpenStack mailing list [4], the migration is based on the freedom of decision-making. Some Openstack deliverables represent thousand of line code. Asyncio is by nature invasive. Using Asyncio everywhere would require to rewrite the deliverables entirely. For this reason we created Awaitlet [5] which could be used to introduce usage of Asyncio while limiting its impact on the existing code.

Current State / Anticipated Impact

History of this goal can be found here [6].

Official wiki page can be found here [7].

A dedicated IRC channel (#openstack-eventlet-removal) has been created. IRC meetings are scheduled every two weeks (on odd weeks). Schedule details are available in the official wiki page [7].