diff --git a/releasenotes/notes/deprecate-eventlet-df4a34a7d56acc47.yaml b/releasenotes/notes/deprecate-eventlet-df4a34a7d56acc47.yaml new file mode 100644 index 000000000..6598a390e --- /dev/null +++ b/releasenotes/notes/deprecate-eventlet-df4a34a7d56acc47.yaml @@ -0,0 +1,10 @@ +--- +deprecations: + - | + Eventlet usages are deprecated and the removal of Eventlet from + OpenStack `is planned `_, + for this reason the eventlet_utils module is now deprecated. + The support of Eventlet will be soon removed from taskflow. + + Please start considering removing your internal Eventlet usages and + start migrating your stack. diff --git a/requirements.txt b/requirements.txt index 784bc45cf..7a916f7db 100644 --- a/requirements.txt +++ b/requirements.txt @@ -7,6 +7,9 @@ pbr>=2.0.0 # Apache-2.0 # Packages needed for using this library. +# For deprecation warning +debtcollector>=1.2.0 # Apache-2.0 + # For async and/or periodic work futurist>=1.2.0 # Apache-2.0 diff --git a/taskflow/utils/eventlet_utils.py b/taskflow/utils/eventlet_utils.py index 5af34d3a3..0649b3c0e 100644 --- a/taskflow/utils/eventlet_utils.py +++ b/taskflow/utils/eventlet_utils.py @@ -14,6 +14,7 @@ # License for the specific language governing permissions and limitations # under the License. +import debtcollector.removals from oslo_utils import importutils _eventlet = importutils.try_import('eventlet') @@ -21,6 +22,7 @@ _eventlet = importutils.try_import('eventlet') EVENTLET_AVAILABLE = bool(_eventlet) +@debtcollector.removals.remove(message='Eventlet support is deprecated.') def check_for_eventlet(exc=None): """Check if eventlet is available and if not raise a runtime error.