Add kombu_reconnect_delay option
The kombu_reconnect_delay is used when configuring rabbitmq but we are missing the parameter from the base trove class. This change adds it in and adds test coverage for the rabbit user, password, host, ssl and reconnect delay. Change-Id: I8a5e7f0241a0f41e4f10b40d791f39e37ce82087 Closes-Bug: #1545168
This commit is contained in:
parent
140ade657e
commit
679c384e64
@ -89,6 +89,11 @@
|
||||
# (optional) Use HA queues in RabbitMQ (x-ha-policy: all).
|
||||
# Defaults to undef
|
||||
#
|
||||
# [*kombu_reconnect_delay*]
|
||||
# (optional) How long to wait before reconnecting in response to an AMQP
|
||||
# consumer cancel notification.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*amqp_durable_queues*]
|
||||
# (optional) Define queues as "durable" to rabbitmq.
|
||||
# Defaults to false
|
||||
@ -249,6 +254,7 @@ class trove(
|
||||
$kombu_ssl_certfile = undef,
|
||||
$kombu_ssl_keyfile = undef,
|
||||
$kombu_ssl_version = 'TLSv1',
|
||||
$kombu_reconnect_delay = $::os_service_default,
|
||||
$amqp_durable_queues = false,
|
||||
$database_connection = undef,
|
||||
$database_idle_timeout = undef,
|
||||
|
@ -86,6 +86,11 @@ describe 'trove::api' do
|
||||
is_expected.to contain_trove_config('DEFAULT/http_mgmt_post_rate').with_value('200')
|
||||
is_expected.to contain_trove_config('DEFAULT/notification_driver').with_value('noop,')
|
||||
is_expected.to contain_trove_config('DEFAULT/notification_topics').with_value('notifications')
|
||||
is_expected.to contain_trove_config('oslo_messaging_rabbit/rabbit_userid').with_value('guest')
|
||||
is_expected.to contain_trove_config('oslo_messaging_rabbit/rabbit_password').with_value('guest')
|
||||
is_expected.to contain_trove_config('oslo_messaging_rabbit/rabbit_use_ssl').with_value(false)
|
||||
is_expected.to contain_trove_config('oslo_messaging_rabbit/kombu_reconnect_delay').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_config('oslo_messaging_rabbit/amqp_durable_queues').with_value(false)
|
||||
end
|
||||
|
||||
context 'with deprecated parameters' do
|
||||
|
@ -31,6 +31,11 @@ describe 'trove::conductor' do
|
||||
is_expected.to contain_trove_conductor_config('DEFAULT/nova_proxy_admin_user').with_value('admin')
|
||||
is_expected.to contain_trove_conductor_config('DEFAULT/nova_proxy_admin_pass').with_value('verysecrete')
|
||||
is_expected.to contain_trove_conductor_config('DEFAULT/nova_proxy_admin_tenant_name').with_value('admin')
|
||||
is_expected.to contain_trove_conductor_config('oslo_messaging_rabbit/rabbit_userid').with_value('guest')
|
||||
is_expected.to contain_trove_conductor_config('oslo_messaging_rabbit/rabbit_password').with_value('guest')
|
||||
is_expected.to contain_trove_conductor_config('oslo_messaging_rabbit/rabbit_use_ssl').with_value(false)
|
||||
is_expected.to contain_trove_conductor_config('oslo_messaging_rabbit/kombu_reconnect_delay').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_conductor_config('oslo_messaging_rabbit/amqp_durable_queues').with_value(false)
|
||||
end
|
||||
|
||||
context 'when using a single RabbitMQ server' do
|
||||
|
@ -35,6 +35,11 @@ describe 'trove::guestagent' do
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/os_region_name').with_value('RegionOne')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/notification_driver').with_value('noop,')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/notification_topics').with_value('notifications')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/rabbit_userid').with_value('guest')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/rabbit_password').with_value('guest')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/rabbit_use_ssl').with_value(false)
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/kombu_reconnect_delay').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/amqp_durable_queues').with_value(false)
|
||||
end
|
||||
|
||||
context 'when using a single RabbitMQ server' do
|
||||
|
@ -68,6 +68,11 @@ describe 'trove::taskmanager' do
|
||||
is_expected.to contain_file('/etc/trove/trove-guestagent.conf')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/notification_driver').with_value('noop,')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/notification_topics').with_value('notifications')
|
||||
is_expected.to contain_trove_taskmanager_config('oslo_messaging_rabbit/rabbit_userid').with_value('guest')
|
||||
is_expected.to contain_trove_taskmanager_config('oslo_messaging_rabbit/rabbit_password').with_value('guest')
|
||||
is_expected.to contain_trove_taskmanager_config('oslo_messaging_rabbit/rabbit_use_ssl').with_value(false)
|
||||
is_expected.to contain_trove_taskmanager_config('oslo_messaging_rabbit/kombu_reconnect_delay').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_taskmanager_config('oslo_messaging_rabbit/amqp_durable_queues').with_value(false)
|
||||
end
|
||||
|
||||
context 'when set use_guestagent_template to false' do
|
||||
|
Loading…
Reference in New Issue
Block a user