Merge "Merge panko tempest config into ceilometer repo"

This commit is contained in:
Zuul 2017-12-05 11:32:44 +00:00 committed by Gerrit Code Review
commit 6b8591c1ea
2 changed files with 38 additions and 12 deletions

View File

@ -16,14 +16,21 @@
from oslo_config import cfg
service_option = cfg.BoolOpt('ceilometer',
default=True,
help="Whether or not Ceilometer is expected to be"
"available")
service_option = [cfg.BoolOpt('ceilometer',
default=True,
help="Whether or not Ceilometer is expected to"
"be available"),
cfg.BoolOpt('panko',
default=True,
help="Whether or not Panko is expected to be"
"available")]
telemetry_group = cfg.OptGroup(name='telemetry',
title='Telemetry Service Options')
event_group = cfg.OptGroup(name='event',
title='Event Service Options')
TelemetryGroup = [
cfg.IntOpt('notification_wait',
default=120,
@ -39,3 +46,14 @@ TelemetryGroup = [
"configured Gnocchi archive policy")
]
event_opts = [
cfg.StrOpt('catalog_type',
default='event',
help="Catalog type of the Event service."),
cfg.StrOpt('endpoint_type',
default='publicURL',
choices=['public', 'admin', 'internal',
'publicURL', 'adminURL', 'internalURL'],
help="The endpoint type to use for the event service."),
]

View File

@ -15,6 +15,7 @@
import os
from tempest import config
from tempest.test_discover import plugins
import ceilometer
@ -31,13 +32,20 @@ class CeilometerTempestPlugin(plugins.TempestPlugin):
return full_test_dir, base_path
def register_opts(self, conf):
conf.register_group(tempest_config.telemetry_group)
conf.register_opts(tempest_config.TelemetryGroup, group='telemetry')
conf.register_opt(tempest_config.service_option,
group='service_available')
config.register_opt_group(
conf, config.service_available_group,
tempest_config.service_option)
config.register_opt_group(
conf, tempest_config.telemetry_group,
tempest_config.TelemetryGroup)
config.register_opt_group(
conf, tempest_config.event_group,
tempest_config.event_opts)
def get_opt_lists(self):
return [
(tempest_config.telemetry_group.name,
tempest_config.TelemetryGroup),
('service_available', [tempest_config.service_option])]
return [(tempest_config.telemetry_group.name,
tempest_config.TelemetryGroup),
(tempest_config.event_group.name,
tempest_config.event_opts),
(config.service_available_group.name,
tempest_config.service_option)]