From 05cbdefa6b239d8ad515481ca5776cdeb4ba4561 Mon Sep 17 00:00:00 2001 From: Denis Egorenko Date: Thu, 3 Dec 2015 20:56:56 +0300 Subject: [PATCH] Remove qpid messaging support Qpid messaging driver is removed from Oslo.messaging [1] Therefore, we cannot support it anymore. [1] I4a9cba314c4a2f24307504fa7b5427424268b114 Change-Id: I4d4c200e733568d33116728e19377575b92331ca --- manifests/api.pp | 25 +------- manifests/conductor.pp | 15 +---- manifests/guestagent.pp | 15 +---- manifests/init.pp | 82 +++++++++++++------------- manifests/taskmanager.pp | 15 +---- spec/classes/trove_api_spec.rb | 37 ------------ spec/classes/trove_conductor_spec.rb | 37 ------------ spec/classes/trove_guestagent_spec.rb | 36 ----------- spec/classes/trove_taskmanager_spec.rb | 37 ------------ templates/trove-guestagent.conf.erb | 2 +- 10 files changed, 47 insertions(+), 254 deletions(-) diff --git a/manifests/api.pp b/manifests/api.pp index 9333283a..8387286e 100644 --- a/manifests/api.pp +++ b/manifests/api.pp @@ -370,30 +370,7 @@ class trove::api( } if $::trove::rpc_backend == 'trove.openstack.common.rpc.impl_qpid' or $::trove::rpc_backend == 'qpid'{ - trove_config { - 'oslo_messaging_qpid/qpid_hostname': value => $::trove::qpid_hostname; - 'oslo_messaging_qpid/qpid_port': value => $::trove::qpid_port; - 'oslo_messaging_qpid/qpid_username': value => $::trove::qpid_username; - 'oslo_messaging_qpid/qpid_password': value => $::trove::qpid_password, secret => true; - 'oslo_messaging_qpid/qpid_heartbeat': value => $::trove::qpid_heartbeat; - 'oslo_messaging_qpid/qpid_protocol': value => $::trove::qpid_protocol; - 'oslo_messaging_qpid/qpid_tcp_nodelay': value => $::trove::qpid_tcp_nodelay; - } - if is_array($::trove::qpid_sasl_mechanisms) { - trove_config { - 'oslo_messaging_qpid/qpid_sasl_mechanisms': value => join($::trove::qpid_sasl_mechanisms, ' '); - } - } - elsif $::trove::qpid_sasl_mechanisms { - trove_config { - 'oslo_messaging_qpid/qpid_sasl_mechanisms': value => $::trove::qpid_sasl_mechanisms; - } - } - else { - trove_config { - 'oslo_messaging_qpid/qpid_sasl_mechanisms': ensure => absent; - } - } + warning('Qpid driver is removed from Oslo.messaging in the Mitaka release') } trove::generic_service { 'api': diff --git a/manifests/conductor.pp b/manifests/conductor.pp index 0d3b5ade..fdeebc60 100644 --- a/manifests/conductor.pp +++ b/manifests/conductor.pp @@ -165,20 +165,7 @@ class trove::conductor( } if $::trove::rpc_backend == 'trove.openstack.common.rpc.impl_qpid' or $::trove::rpc_backend == 'qpid'{ - trove_conductor_config { - 'oslo_messaging_qpid/qpid_hostname': value => $::trove::qpid_hostname; - 'oslo_messaging_qpid/qpid_port': value => $::trove::qpid_port; - 'oslo_messaging_qpid/qpid_username': value => $::trove::qpid_username; - 'oslo_messaging_qpid/qpid_password': value => $::trove::qpid_password, secret => true; - 'oslo_messaging_qpid/qpid_heartbeat': value => $::trove::qpid_heartbeat; - 'oslo_messaging_qpid/qpid_protocol': value => $::trove::qpid_protocol; - 'oslo_messaging_qpid/qpid_tcp_nodelay': value => $::trove::qpid_tcp_nodelay; - } - if is_array($::trove::qpid_sasl_mechanisms) { - trove_conductor_config { - 'oslo_messaging_qpid/qpid_sasl_mechanisms': value => join($::trove::qpid_sasl_mechanisms, ' '); - } - } + warning('Qpid driver is removed from Oslo.messaging in the Mitaka release') } # Logging diff --git a/manifests/guestagent.pp b/manifests/guestagent.pp index 2d803a6a..35bb9523 100644 --- a/manifests/guestagent.pp +++ b/manifests/guestagent.pp @@ -162,20 +162,7 @@ class trove::guestagent( } if $::trove::rpc_backend == 'trove.openstack.common.rpc.impl_qpid' or $::trove::rpc_backend == 'qpid'{ - trove_guestagent_config { - 'oslo_messaging_qpid/qpid_hostname': value => $::trove::qpid_hostname; - 'oslo_messaging_qpid/qpid_port': value => $::trove::qpid_port; - 'oslo_messaging_qpid/qpid_username': value => $::trove::qpid_username; - 'oslo_messaging_qpid/qpid_password': value => $::trove::qpid_password, secret => true; - 'oslo_messaging_qpid/qpid_heartbeat': value => $::trove::qpid_heartbeat; - 'oslo_messaging_qpid/qpid_protocol': value => $::trove::qpid_protocol; - 'oslo_messaging_qpid/qpid_tcp_nodelay': value => $::trove::qpid_tcp_nodelay; - } - if is_array($::trove::qpid_sasl_mechanisms) { - trove_guestagent_config { - 'oslo_messaging_qpid/qpid_sasl_mechanisms': value => join($::trove::qpid_sasl_mechanisms, ' '); - } - } + warning('Qpid driver is removed from Oslo.messaging in the Mitaka release') } # Logging diff --git a/manifests/init.pp b/manifests/init.pp index 57bc4013..6af6fb46 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -81,38 +81,6 @@ # (optional) Define queues as "durable" to rabbitmq. # Defaults to false # -# [*qpid_hostname*] -# (optional) Location of qpid server -# Defaults to 'localhost' -# -# [*qpid_port*] -# (optional) Port for qpid server -# Defaults to '5672' -# -# [*qpid_username*] -# (optional) Username to use when connecting to qpid -# Defaults to 'guest' -# -# [*qpid_password*] -# (optional) Password to use when connecting to qpid -# Defaults to 'guest' -# -# [*qpid_heartbeat*] -# (optional) Seconds between connection keepalive heartbeats -# Defaults to 60 -# -# [*qpid_protocol*] -# (optional) Transport to use, either 'tcp' or 'ssl'' -# Defaults to 'tcp' -# -# [*qpid_sasl_mechanisms*] -# (optional) Enable one or more SASL mechanisms -# Defaults to false -# -# [*qpid_tcp_nodelay*] -# (optional) Disable Nagle algorithm -# Defaults to true -# # [*rpc_backend*] # (optional) The rpc backend implementation to use, can be: # rabbit (for rabbitmq) @@ -218,6 +186,40 @@ # (optional) The state of the package. # Defaults to 'present' # +# DEPRECATED PARAMETERS +# +# [*qpid_hostname*] +# (optional) Location of qpid server +# Defaults to undef +# +# [*qpid_port*] +# (optional) Port for qpid server +# Defaults to undef +# +# [*qpid_username*] +# (optional) Username to use when connecting to qpid +# Defaults to undef +# +# [*qpid_password*] +# (optional) Password to use when connecting to qpid +# Defaults to undef +# +# [*qpid_heartbeat*] +# (optional) Seconds between connection keepalive heartbeats +# Defaults to undef +# +# [*qpid_protocol*] +# (optional) Transport to use, either 'tcp' or 'ssl'' +# Defaults to undef +# +# [*qpid_sasl_mechanisms*] +# (optional) Enable one or more SASL mechanisms +# Defaults to undef +# +# [*qpid_tcp_nodelay*] +# (optional) Disable Nagle algorithm +# Defaults to undef +# class trove( $nova_proxy_admin_pass, $rabbit_host = 'localhost', @@ -233,14 +235,6 @@ class trove( $kombu_ssl_keyfile = undef, $kombu_ssl_version = 'TLSv1', $amqp_durable_queues = false, - $qpid_hostname = 'localhost', - $qpid_port = '5672', - $qpid_username = 'guest', - $qpid_password = 'guest', - $qpid_sasl_mechanisms = false, - $qpid_heartbeat = 60, - $qpid_protocol = 'tcp', - $qpid_tcp_nodelay = true, $database_connection = undef, $database_idle_timeout = undef, $database_max_retries = undef, @@ -266,6 +260,14 @@ class trove( $package_ensure = 'present', # DEPRECATED PARAMETERS $mysql_module = undef, + $qpid_hostname = undef, + $qpid_port = undef, + $qpid_username = undef, + $qpid_password = undef, + $qpid_sasl_mechanisms = undef, + $qpid_heartbeat = undef, + $qpid_protocol = undef, + $qpid_tcp_nodelay = undef, ) { include ::trove::params diff --git a/manifests/taskmanager.pp b/manifests/taskmanager.pp index cd4adedb..746222ce 100644 --- a/manifests/taskmanager.pp +++ b/manifests/taskmanager.pp @@ -215,20 +215,7 @@ class trove::taskmanager( } if $::trove::rpc_backend == 'trove.openstack.common.rpc.impl_qpid' or $::trove::rpc_backend == 'qpid'{ - trove_taskmanager_config { - 'oslo_messaging_qpid/qpid_hostname': value => $::trove::qpid_hostname; - 'oslo_messaging_qpid/qpid_port': value => $::trove::qpid_port; - 'oslo_messaging_qpid/qpid_username': value => $::trove::qpid_username; - 'oslo_messaging_qpid/qpid_password': value => $::trove::qpid_password, secret => true; - 'oslo_messaging_qpid/qpid_heartbeat': value => $::trove::qpid_heartbeat; - 'oslo_messaging_qpid/qpid_protocol': value => $::trove::qpid_protocol; - 'oslo_messaging_qpid/qpid_tcp_nodelay': value => $::trove::qpid_tcp_nodelay; - } - if is_array($::trove::qpid_sasl_mechanisms) { - trove_taskmanager_config { - 'oslo_messaging_qpid/qpid_sasl_mechanisms': value => join($::trove::qpid_sasl_mechanisms, ' '); - } - } + warning('Qpid driver is removed from Oslo.messaging in the Mitaka release') } if $::trove::use_neutron { diff --git a/spec/classes/trove_api_spec.rb b/spec/classes/trove_api_spec.rb index dbfe9e33..ca1ab089 100644 --- a/spec/classes/trove_api_spec.rb +++ b/spec/classes/trove_api_spec.rb @@ -134,43 +134,6 @@ describe 'trove::api' do end end - context 'when using qpid' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password'}" - end - it 'configures trove-api with qpid' do - is_expected.to contain_trove_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_protocol').with_value('tcp') - end - end - - context 'when using qpid with SSL enabled' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password', - qpid_protocol => 'ssl'}" - end - it 'configures trove-api with qpid' do - is_expected.to contain_trove_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_config('oslo_messaging_qpid/qpid_protocol').with_value('ssl') - end - end - end context 'with SSL enabled with kombu' do diff --git a/spec/classes/trove_conductor_spec.rb b/spec/classes/trove_conductor_spec.rb index 183b1e6d..1414e77d 100644 --- a/spec/classes/trove_conductor_spec.rb +++ b/spec/classes/trove_conductor_spec.rb @@ -55,43 +55,6 @@ describe 'trove::conductor' do end end - context 'when using qpid' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password'}" - end - it 'configures trove-conductor with qpid' do - is_expected.to contain_trove_conductor_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_protocol').with_value('tcp') - end - end - - context 'when using qpid with SSL enabled' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password', - qpid_protocol => 'ssl'}" - end - it 'configures trove-conductor with qpid' do - is_expected.to contain_trove_conductor_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_conductor_config('oslo_messaging_qpid/qpid_protocol').with_value('ssl') - end - end - context 'when using MySQL' do let :pre_condition do "class { 'trove': diff --git a/spec/classes/trove_guestagent_spec.rb b/spec/classes/trove_guestagent_spec.rb index 642016d9..317fe7ac 100644 --- a/spec/classes/trove_guestagent_spec.rb +++ b/spec/classes/trove_guestagent_spec.rb @@ -57,42 +57,6 @@ describe 'trove::guestagent' do end end - context 'when using qpid' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password'}" - end - it 'configures trove-guestagent with qpid' do - is_expected.to contain_trove_guestagent_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_protocol').with_value('tcp') - end - end - - context 'when using qpid with SSL enabled' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password', - qpid_protocol => 'ssl'}" - end - it 'configures trove-guestagent with qpid' do - is_expected.to contain_trove_guestagent_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_guestagent_config('oslo_messaging_qpid/qpid_protocol').with_value('ssl') - end - end end context 'with custom parameters' do diff --git a/spec/classes/trove_taskmanager_spec.rb b/spec/classes/trove_taskmanager_spec.rb index 68d25033..3eb49eef 100644 --- a/spec/classes/trove_taskmanager_spec.rb +++ b/spec/classes/trove_taskmanager_spec.rb @@ -105,43 +105,6 @@ describe 'trove::taskmanager' do end end - context 'when using qpid' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password'}" - end - it 'configures trove-taskmanager with qpid' do - is_expected.to contain_trove_taskmanager_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_protocol').with_value('tcp') - end - end - - context 'when using qpid with SSL enabled' do - let :pre_condition do - "class { 'trove': - nova_proxy_admin_pass => 'verysecrete', - rpc_backend => 'qpid', - qpid_hostname => '10.0.0.1', - qpid_username => 'guest', - qpid_password => 'password', - qpid_protocol => 'ssl'}" - end - it 'configures trove-taskmanager with qpid' do - is_expected.to contain_trove_taskmanager_config('DEFAULT/rpc_backend').with_value('qpid') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_hostname').with_value('10.0.0.1') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_username').with_value('guest') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_password').with_value('password') - is_expected.to contain_trove_taskmanager_config('oslo_messaging_qpid/qpid_protocol').with_value('ssl') - end - end - context 'when using MySQL' do let :pre_condition do "class { 'trove': diff --git a/templates/trove-guestagent.conf.erb b/templates/trove-guestagent.conf.erb index 5f388709..15c0d080 100644 --- a/templates/trove-guestagent.conf.erb +++ b/templates/trove-guestagent.conf.erb @@ -7,7 +7,7 @@ # configuration. #transport_url= -# The messaging driver to use. Options include rabbit, qpid and zmq. +# The messaging driver to use. Options include rabbit and zmq. # Default is rabbit. (string value) rpc_backend= <%= @rpc_backend %>