diff --git a/cinder/cmd/all.py b/cinder/cmd/all.py index 33ed5ac03..a5708f05b 100644 --- a/cinder/cmd/all.py +++ b/cinder/cmd/all.py @@ -43,7 +43,7 @@ i18n.enable_lazy() from cinder.cmd import volume as volume_cmd from cinder.common import config # noqa from cinder.db import api as session -from cinder.i18n import _LE, _ +from cinder.i18n import _LE, _, _LW from cinder import objects from cinder import rpc from cinder import service @@ -104,6 +104,10 @@ def main(): session.dispose_engine() launcher.launch_service(server) else: + LOG.warning(_LW('Configuration for cinder-volume does not specify ' + '"enabled_backends", using DEFAULT as backend. ' + 'Support for DEFAULT section to configure drivers ' + 'will be removed in the next release.')) server = service.Service.create(binary='cinder-volume', coordination=True) launcher.launch_service(server) diff --git a/cinder/cmd/volume.py b/cinder/cmd/volume.py index 66464f8dc..8ce6eb6e6 100644 --- a/cinder/cmd/volume.py +++ b/cinder/cmd/volume.py @@ -44,7 +44,7 @@ i18n.enable_lazy() # Need to register global_opts from cinder.common import config # noqa from cinder.db import api as session -from cinder.i18n import _ +from cinder.i18n import _, _LW from cinder import service from cinder import utils from cinder import version @@ -91,6 +91,10 @@ def main(): launcher.launch_service(server) service_started = True else: + LOG.warning(_LW('Configuration for cinder-volume does not specify ' + '"enabled_backends", using DEFAULT as backend. ' + 'Support for DEFAULT section to configure drivers ' + 'will be removed in the next release.')) server = service.Service.create(binary='cinder-volume', coordination=True) launcher.launch_service(server) diff --git a/releasenotes/notes/deprecate-backends-in-default-b9784a2333fe22f2.yaml b/releasenotes/notes/deprecate-backends-in-default-b9784a2333fe22f2.yaml new file mode 100644 index 000000000..a3952e1ee --- /dev/null +++ b/releasenotes/notes/deprecate-backends-in-default-b9784a2333fe22f2.yaml @@ -0,0 +1,10 @@ +--- +upgrade: + - Any Volume Drivers configured in the DEFAULT config stanza should be moved + to their own stanza and enabled via the enabled_backends config option. + The older style of config with DEFAULT is deprecated and will be + removed in future releases. +deprecations: + - Configuring Volume Drivers in the DEFAULT config stanza is not going to be + maintained and will be removed in the next release. All backends should use + the enabled_backends config option with separate stanza's for each.