summaryrefslogtreecommitdiff
path: root/ceilometer
diff options
context:
space:
mode:
authorTakashi Kajinami <tkajinam@redhat.com>2022-09-05 20:19:54 +0900
committerTakashi Kajinami <tkajinam@redhat.com>2022-09-05 20:19:54 +0900
commit26d569dee5d9943dd12c1b54f7a9256159f22225 (patch)
treeca3797d851dfba5d1b5849dd57be2d0c95d5b679 /ceilometer
parentce52d50c845fbf098a2a22ca6649dcb00a90d7e3 (diff)
downloadceilometer-26d569dee5d9943dd12c1b54f7a9256159f22225.tar.gz
Remove unnecessary logic for missing oslo.cache
The oslo.cache library is now included in the requirements thus should be always installed. This change removes the logic to handle missing oslo.cache. Change-Id: I1cc09aa0db5f19e913030b528c51052fd4ef331d
Diffstat (limited to 'ceilometer')
-rw-r--r--ceilometer/publisher/gnocchi.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/ceilometer/publisher/gnocchi.py b/ceilometer/publisher/gnocchi.py
index 19d7d54b..27e499f5 100644
--- a/ceilometer/publisher/gnocchi.py
+++ b/ceilometer/publisher/gnocchi.py
@@ -24,6 +24,7 @@ import uuid
from gnocchiclient import exceptions as gnocchi_exc
from keystoneauth1 import exceptions as ka_exceptions
+import oslo_cache
from oslo_log import log
from oslo_utils import timeutils
from stevedore import extension
@@ -214,7 +215,6 @@ class GnocchiPublisher(publisher.ConfigPublisherBase):
self.cache = None
try:
- import oslo_cache
oslo_cache.configure(conf)
# NOTE(cdent): The default cache backend is a real but
# noop backend. We don't want to use that here because
@@ -225,8 +225,6 @@ class GnocchiPublisher(publisher.ConfigPublisherBase):
self.cache = oslo_cache.configure_cache_region(
conf, cache_region)
self.cache.key_mangler = cache_key_mangler
- except ImportError:
- pass
except oslo_cache.exception.ConfigurationError as exc:
LOG.warning('unable to configure oslo_cache: %s', exc)