Deprecate Ceilometer Datasource
Ceilometer Datasource has been deprecated since its API has been deprecated in Ocata cycle. Watcher has supported Ceilometer for some releases after Ocata to let users migrate to Gnocchi/Monasca datasources. Since U-release, Ceilometer support will be removed. Change-Id: I944a5a562ab09a36961eb9b75e9a5144ba0b9ca4
This commit is contained in:
parent
63e6fde8ff
commit
92894237f3
@ -0,0 +1,7 @@
|
||||
---
|
||||
deprecations:
|
||||
- |
|
||||
Ceilometer Datasource has been deprecated since its API has been
|
||||
deprecated in Ocata cycle. Watcher has supported Ceilometer for some
|
||||
releases after Ocata to let users migrate to Gnocchi/Monasca datasources.
|
||||
Since Train release, Ceilometer support will be removed.
|
@ -24,14 +24,32 @@ ceilometer_client = cfg.OptGroup(name='ceilometer_client',
|
||||
CEILOMETER_CLIENT_OPTS = [
|
||||
cfg.StrOpt('api_version',
|
||||
default='2',
|
||||
deprecated_for_removal=True,
|
||||
deprecated_since="1.13.0",
|
||||
deprecated_reason="""
|
||||
Ceilometer API is deprecated since Ocata release.
|
||||
Any related configuration options are deprecated too.
|
||||
""",
|
||||
help='Version of Ceilometer API to use in '
|
||||
'ceilometerclient.'),
|
||||
cfg.StrOpt('endpoint_type',
|
||||
default='internalURL',
|
||||
deprecated_for_removal=True,
|
||||
deprecated_since="1.13.0",
|
||||
deprecated_reason="""
|
||||
Ceilometer API is deprecated since Ocata release.
|
||||
Any related configuration options are deprecated too.
|
||||
""",
|
||||
help='Type of endpoint to use in ceilometerclient. '
|
||||
'Supported values: internalURL, publicURL, adminURL. '
|
||||
'The default is internalURL.'),
|
||||
cfg.StrOpt('region_name',
|
||||
deprecated_for_removal=True,
|
||||
deprecated_since="1.13.0",
|
||||
deprecated_reason="""
|
||||
Ceilometer API is deprecated since Ocata release.
|
||||
Any related configuration options are deprecated too.
|
||||
""",
|
||||
help='Region in Identity service catalog to use for '
|
||||
'communication with the OpenStack service.')]
|
||||
|
||||
|
@ -19,6 +19,7 @@
|
||||
import datetime
|
||||
|
||||
from ceilometerclient import exc
|
||||
from oslo_log import log
|
||||
from oslo_utils import timeutils
|
||||
|
||||
from watcher._i18n import _
|
||||
@ -27,6 +28,9 @@ from watcher.common import exception
|
||||
from watcher.datasource import base
|
||||
|
||||
|
||||
LOG = log.getLogger(__name__)
|
||||
|
||||
|
||||
class CeilometerHelper(base.DataSourceBase):
|
||||
|
||||
NAME = 'ceilometer'
|
||||
@ -36,6 +40,9 @@ class CeilometerHelper(base.DataSourceBase):
|
||||
""":param osc: an OpenStackClients instance"""
|
||||
self.osc = osc if osc else clients.OpenStackClients()
|
||||
self.ceilometer = self.osc.ceilometer()
|
||||
LOG.warning("Ceilometer API is deprecated and Ceilometer Datasource "
|
||||
"module is no longer maintained. We recommend to use "
|
||||
"Gnocchi instead.")
|
||||
|
||||
@staticmethod
|
||||
def format_query(user_id, tenant_id, resource_id,
|
||||
|
Loading…
Reference in New Issue
Block a user