Merge "Change section name for AMQP qpid parameters"
This commit is contained in:
commit
71052000a1
@ -500,19 +500,19 @@ class neutron (
|
|||||||
|
|
||||||
if $rpc_backend == 'qpid' or $rpc_backend == 'neutron.openstack.common.rpc.impl_qpid' {
|
if $rpc_backend == 'qpid' or $rpc_backend == 'neutron.openstack.common.rpc.impl_qpid' {
|
||||||
neutron_config {
|
neutron_config {
|
||||||
'DEFAULT/qpid_hostname': value => $qpid_hostname;
|
'oslo_messaging_qpid/qpid_hostname': value => $qpid_hostname;
|
||||||
'DEFAULT/qpid_port': value => $qpid_port;
|
'oslo_messaging_qpid/qpid_port': value => $qpid_port;
|
||||||
'DEFAULT/qpid_username': value => $qpid_username;
|
'oslo_messaging_qpid/qpid_username': value => $qpid_username;
|
||||||
'DEFAULT/qpid_password': value => $qpid_password, secret => true;
|
'oslo_messaging_qpid/qpid_password': value => $qpid_password, secret => true;
|
||||||
'DEFAULT/qpid_heartbeat': value => $qpid_heartbeat;
|
'oslo_messaging_qpid/qpid_heartbeat': value => $qpid_heartbeat;
|
||||||
'DEFAULT/qpid_protocol': value => $qpid_protocol;
|
'oslo_messaging_qpid/qpid_protocol': value => $qpid_protocol;
|
||||||
'DEFAULT/qpid_tcp_nodelay': value => $qpid_tcp_nodelay;
|
'oslo_messaging_qpid/qpid_tcp_nodelay': value => $qpid_tcp_nodelay;
|
||||||
'DEFAULT/qpid_reconnect': value => $qpid_reconnect;
|
'oslo_messaging_qpid/qpid_reconnect': value => $qpid_reconnect;
|
||||||
'DEFAULT/qpid_reconnect_timeout': value => $qpid_reconnect_timeout;
|
'oslo_messaging_qpid/qpid_reconnect_timeout': value => $qpid_reconnect_timeout;
|
||||||
'DEFAULT/qpid_reconnect_limit': value => $qpid_reconnect_limit;
|
'oslo_messaging_qpid/qpid_reconnect_limit': value => $qpid_reconnect_limit;
|
||||||
'DEFAULT/qpid_reconnect_interval_min': value => $qpid_reconnect_interval_min;
|
'oslo_messaging_qpid/qpid_reconnect_interval_min': value => $qpid_reconnect_interval_min;
|
||||||
'DEFAULT/qpid_reconnect_interval_max': value => $qpid_reconnect_interval_max;
|
'oslo_messaging_qpid/qpid_reconnect_interval_max': value => $qpid_reconnect_interval_max;
|
||||||
'DEFAULT/qpid_reconnect_interval': value => $qpid_reconnect_interval;
|
'oslo_messaging_qpid/qpid_reconnect_interval': value => $qpid_reconnect_interval;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -81,6 +81,7 @@ describe 'neutron' do
|
|||||||
it_configures 'with service_plugins'
|
it_configures 'with service_plugins'
|
||||||
it_configures 'without memcache_servers'
|
it_configures 'without memcache_servers'
|
||||||
it_configures 'with memcache_servers'
|
it_configures 'with memcache_servers'
|
||||||
|
it_configures 'with qpid rpc backend'
|
||||||
end
|
end
|
||||||
|
|
||||||
shared_examples_for 'a neutron base installation' do
|
shared_examples_for 'a neutron base installation' do
|
||||||
@ -157,6 +158,55 @@ describe 'neutron' do
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
shared_examples_for 'with qpid rpc backend' do
|
||||||
|
before do
|
||||||
|
params.merge!({ :rpc_backend => 'qpid' })
|
||||||
|
end
|
||||||
|
|
||||||
|
it { is_expected.to contain_neutron_config('DEFAULT/rpc_backend').with_value('qpid') }
|
||||||
|
|
||||||
|
context 'when default params' do
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_username').with_value('guest') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_password').with_value('guest').with_secret(true) }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_hostname').with_value('localhost') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_port').with_value('5672') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_protocol').with_value('tcp') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_heartbeat').with_value('60') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_tcp_nodelay').with_value('true') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_reconnect').with_value('true') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_reconnect_timeout').with_value('0') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_reconnect_limit').with_value('0') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_reconnect_interval_min').with_value('0') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_reconnect_interval_max').with_value('0') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_reconnect_interval').with_value('0') }
|
||||||
|
end
|
||||||
|
|
||||||
|
context 'when passing params' do
|
||||||
|
before do
|
||||||
|
params.merge!({
|
||||||
|
:qpid_password => 'pass',
|
||||||
|
:qpid_username => 'guest2',
|
||||||
|
:qpid_hostname => 'localhost2',
|
||||||
|
:qpid_port => '5673',
|
||||||
|
:qpid_protocol => 'udp',
|
||||||
|
:qpid_heartbeat => '89',
|
||||||
|
:qpid_tcp_nodelay => 'false',
|
||||||
|
:qpid_reconnect => 'false',
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_username').with_value('guest2') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_password').with_value('pass').with_secret(true) }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_hostname').with_value('localhost2') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_port').with_value('5673') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_protocol').with_value('udp') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_heartbeat').with_value('89') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_tcp_nodelay').with_value('false') }
|
||||||
|
it { is_expected.to contain_neutron_config('oslo_messaging_qpid/qpid_reconnect').with_value('false') }
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
shared_examples_for 'with SSL socket options set' do
|
shared_examples_for 'with SSL socket options set' do
|
||||||
before do
|
before do
|
||||||
params.merge!(
|
params.merge!(
|
||||||
|
Loading…
Reference in New Issue
Block a user