From dc7303a1357ca2cfbcd34575d1051642ab1f2e78 Mon Sep 17 00:00:00 2001 From: Marcin Piwowarczyk Date: Fri, 12 Oct 2018 11:20:17 +0200 Subject: [PATCH] Be compilance with latest oslo.messaging Support for the [oslo_messaging_rabbit] section has been removed in oslo.messaging==9.0.0 package [1]. That's why integration tests failures on build devstack step. This is the moment where we need to use the transport_url directive in the [DEFAULT] section instead. Moreover rpc_backend property (which was used in trove to enable fake RPC backend) has been removed from DEFAULT section and API tests fails on TIME_OUT as they starts on rabbit RPC backend. Fake RPC can be now configured as described here [2]: transport_url = 'fake:/' [1] https://docs.openstack.org/releasenotes/oslo.messaging/unreleased.html [2] https://docs.openstack.org/oslo.messaging/latest/configuration/conffixture.html Change-Id: Id6c5a9198d5a213cb085407a1d8b534e7c755f69 Signed-off-by: Marcin Piwowarczyk --- devstack/plugin.sh | 16 ++++---------- doc/source/install/common_configure.txt | 7 +----- etc/trove/trove-conductor.conf.sample | 29 ------------------------- etc/trove/trove-guestagent.conf.sample | 29 ------------------------- etc/trove/trove-taskmanager.conf.sample | 29 ------------------------- etc/trove/trove.conf.sample | 29 ------------------------- etc/trove/trove.conf.test | 8 +------ integration/scripts/trovestack | 1 - 8 files changed, 6 insertions(+), 142 deletions(-) diff --git a/devstack/plugin.sh b/devstack/plugin.sh index 0b3b215895..c03c073248 100644 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -206,9 +206,7 @@ function configure_trove { iniset $TROVE_CONF DEFAULT rpc_backend "rabbit" iniset $TROVE_CONF DEFAULT control_exchange trove - iniset $TROVE_CONF oslo_messaging_rabbit rabbit_hosts $RABBIT_HOST - iniset $TROVE_CONF oslo_messaging_rabbit rabbit_password $RABBIT_PASSWORD - iniset $TROVE_CONF oslo_messaging_rabbit rabbit_userid $RABBIT_USERID + iniset $TROVE_CONF DEFAULT transport_url rabbit://$RABBIT_USERID:$RABBIT_PASSWORD@$RABBIT_HOST:5672/ iniset $TROVE_CONF database connection `database_connection_url trove` @@ -237,9 +235,7 @@ function configure_trove { iniset $TROVE_TASKMANAGER_CONF DEFAULT rpc_backend "rabbit" iniset $TROVE_TASKMANAGER_CONF DEFAULT control_exchange trove - iniset $TROVE_TASKMANAGER_CONF oslo_messaging_rabbit rabbit_hosts $RABBIT_HOST - iniset $TROVE_TASKMANAGER_CONF oslo_messaging_rabbit rabbit_password $RABBIT_PASSWORD - iniset $TROVE_TASKMANAGER_CONF oslo_messaging_rabbit rabbit_userid $RABBIT_USERID + iniset $TROVE_TASKMANAGER_CONF DEFAULT transport_url rabbit://$RABBIT_USERID:$RABBIT_PASSWORD@$RABBIT_HOST:5672/ iniset $TROVE_TASKMANAGER_CONF database connection `database_connection_url trove` iniset $TROVE_TASKMANAGER_CONF DEFAULT taskmanager_manager trove.taskmanager.manager.Manager @@ -267,9 +263,7 @@ function configure_trove { # (Re)create trove conductor conf file if needed if is_service_enabled tr-cond; then iniset $TROVE_CONDUCTOR_CONF DEFAULT rpc_backend "rabbit" - iniset $TROVE_CONDUCTOR_CONF oslo_messaging_rabbit rabbit_hosts $RABBIT_HOST - iniset $TROVE_CONDUCTOR_CONF oslo_messaging_rabbit rabbit_password $RABBIT_PASSWORD - iniset $TROVE_CONDUCTOR_CONF oslo_messaging_rabbit rabbit_userid $RABBIT_USERID + iniset $TROVE_CONDUCTOR_CONF DEFAULT transport_url rabbit://$RABBIT_USERID:$RABBIT_PASSWORD@$RABBIT_HOST:5672/ iniset $TROVE_CONDUCTOR_CONF database connection `database_connection_url trove` iniset $TROVE_CONDUCTOR_CONF DEFAULT trove_auth_url $TROVE_AUTH_ENDPOINT @@ -284,9 +278,7 @@ function configure_trove { # Set up Guest Agent conf iniset $TROVE_GUESTAGENT_CONF DEFAULT rpc_backend "rabbit" - iniset $TROVE_GUESTAGENT_CONF oslo_messaging_rabbit rabbit_password $RABBIT_PASSWORD - iniset $TROVE_GUESTAGENT_CONF oslo_messaging_rabbit rabbit_userid $RABBIT_USERID - iniset $TROVE_GUESTAGENT_CONF oslo_messaging_rabbit rabbit_hosts $TROVE_HOST_GATEWAY + iniset $TROVE_GUESTAGENT_CONF DEFAULT transport_url rabbit://$RABBIT_USERID:$RABBIT_PASSWORD@$TROVE_HOST_GATEWAY:5672/ iniset $TROVE_GUESTAGENT_CONF DEFAULT trove_auth_url $TROVE_AUTH_ENDPOINT iniset $TROVE_GUESTAGENT_CONF DEFAULT control_exchange trove diff --git a/doc/source/install/common_configure.txt b/doc/source/install/common_configure.txt index 0aa5ffbcff..ab03fda596 100644 --- a/doc/source/install/common_configure.txt +++ b/doc/source/install/common_configure.txt @@ -24,12 +24,7 @@ [DEFAULT] ... rpc_backend = rabbit - - [oslo_messaging_rabbit] - ... - rabbit_host = controller - rabbit_userid = openstack - rabbit_password = RABBIT_PASS + transport_url = rabbit://:@:5672 3. Verify that the ``api-paste.ini`` file is present in ``/etc/trove``. diff --git a/etc/trove/trove-conductor.conf.sample b/etc/trove/trove-conductor.conf.sample index d858bf254b..8f63456763 100644 --- a/etc/trove/trove-conductor.conf.sample +++ b/etc/trove/trove-conductor.conf.sample @@ -56,32 +56,3 @@ connection = mysql+pymysql://root:e1a2c042c828d3566d0a@localhost/trove # message which failed to be delivered due to a recoverable # error. 0 - No retry, -1 - indefinite (integer value) #retry = -1 - -[oslo_messaging_rabbit] -# The RabbitMQ broker address where a single node is used. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_host -#rabbit_host=localhost - -# The RabbitMQ broker port where a single node is used. (integer value) -# Deprecated group/name - [DEFAULT]/rabbit_port -#rabbit_port=5672 - -# RabbitMQ HA cluster host:port pairs. (list value) -# Deprecated group/name - [DEFAULT]/rabbit_hosts -#rabbit_hosts=$rabbit_host:$rabbit_port - -# Connect over SSL for RabbitMQ. (boolean value) -# Deprecated group/name - [DEFAULT]/rabbit_use_ssl -#rabbit_use_ssl=false - -# The RabbitMQ userid. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_userid -#rabbit_userid=guest - -# The RabbitMQ password. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_password -#rabbit_password=f7999d1955c5014aa32c - -# The RabbitMQ virtual host. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_virtual_host -#rabbit_virtual_host=/ diff --git a/etc/trove/trove-guestagent.conf.sample b/etc/trove/trove-guestagent.conf.sample index 756e9ef2c4..8e49d4bbbb 100644 --- a/etc/trove/trove-guestagent.conf.sample +++ b/etc/trove/trove-guestagent.conf.sample @@ -110,35 +110,6 @@ log_config_append = /etc/trove/trove-logging-guestagent.conf # error. 0 - No retry, -1 - indefinite (integer value) #retry = -1 -[oslo_messaging_rabbit] -# The RabbitMQ broker address where a single node is used. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_host -rabbit_host=10.0.0.1 - -# The RabbitMQ broker port where a single node is used. (integer value) -# Deprecated group/name - [DEFAULT]/rabbit_port -#rabbit_port=5672 - -# RabbitMQ HA cluster host:port pairs. (list value) -# Deprecated group/name - [DEFAULT]/rabbit_hosts -#rabbit_hosts=$rabbit_host:$rabbit_port - -# Connect over SSL for RabbitMQ. (boolean value) -# Deprecated group/name - [DEFAULT]/rabbit_use_ssl -#rabbit_use_ssl=false - -# The RabbitMQ userid. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_userid -#rabbit_userid=guest - -# The RabbitMQ password. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_password -#rabbit_password=f7999d1955c5014aa32c - -# The RabbitMQ virtual host. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_virtual_host -#rabbit_virtual_host=/ - # ========== Datastore Specific Configuration Options ========== [mysql] diff --git a/etc/trove/trove-taskmanager.conf.sample b/etc/trove/trove-taskmanager.conf.sample index b48b374854..6821768c4a 100644 --- a/etc/trove/trove-taskmanager.conf.sample +++ b/etc/trove/trove-taskmanager.conf.sample @@ -208,35 +208,6 @@ idle_timeout = 3600 # error. 0 - No retry, -1 - indefinite (integer value) #retry = -1 -[oslo_messaging_rabbit] -# The RabbitMQ broker address where a single node is used. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_host -#rabbit_host=localhost - -# The RabbitMQ broker port where a single node is used. (integer value) -# Deprecated group/name - [DEFAULT]/rabbit_port -#rabbit_port=5672 - -# RabbitMQ HA cluster host:port pairs. (list value) -# Deprecated group/name - [DEFAULT]/rabbit_hosts -#rabbit_hosts=$rabbit_host:$rabbit_port - -# Connect over SSL for RabbitMQ. (boolean value) -# Deprecated group/name - [DEFAULT]/rabbit_use_ssl -#rabbit_use_ssl=false - -# The RabbitMQ userid. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_userid -#rabbit_userid=guest - -# The RabbitMQ password. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_password -#rabbit_password=f7999d1955c5014aa32c - -# The RabbitMQ virtual host. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_virtual_host -#rabbit_virtual_host=/ - [mysql] # Whether to permit ICMP. default is False. icmp = True diff --git a/etc/trove/trove.conf.sample b/etc/trove/trove.conf.sample index 011f5a6b12..f6597b8a63 100644 --- a/etc/trove/trove.conf.sample +++ b/etc/trove/trove.conf.sample @@ -205,35 +205,6 @@ idle_timeout = 3600 # error. 0 - No retry, -1 - indefinite (integer value) #retry = -1 -[oslo_messaging_rabbit] -# The RabbitMQ broker address where a single node is used. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_host -#rabbit_host=localhost - -# The RabbitMQ broker port where a single node is used. (integer value) -# Deprecated group/name - [DEFAULT]/rabbit_port -#rabbit_port=5672 - -# RabbitMQ HA cluster host:port pairs. (list value) -# Deprecated group/name - [DEFAULT]/rabbit_hosts -#rabbit_hosts=$rabbit_host:$rabbit_port - -# Connect over SSL for RabbitMQ. (boolean value) -# Deprecated group/name - [DEFAULT]/rabbit_use_ssl -#rabbit_use_ssl=false - -# The RabbitMQ userid. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_userid -#rabbit_userid=guest - -# The RabbitMQ password. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_password -#rabbit_password=f7999d1955c5014aa32c - -# The RabbitMQ virtual host. (string value) -# Deprecated group/name - [DEFAULT]/rabbit_virtual_host -#rabbit_virtual_host=/ - [mysql] root_on_create = False # Format (single port or port range): A, B-C diff --git a/etc/trove/trove.conf.test b/etc/trove/trove.conf.test index 1694eb97b7..588a37427d 100644 --- a/etc/trove/trove.conf.test +++ b/etc/trove/trove.conf.test @@ -7,7 +7,7 @@ remote_swift_client = trove.tests.fakes.swift.fake_create_swift_client remote_cinder_client = trove.tests.fakes.nova.fake_create_cinder_client # Fake out the RPC implementation -rpc_backend = fake +transport_url = 'fake:/' # Skip running periodic tasks report_interval = 0 @@ -104,12 +104,6 @@ control_exchange = trove paste_config_file=api-paste.ini.test -[oslo_messaging_rabbit] -# AMQP Connection info -# Deprecated group/name - [DEFAULT]/rabbit_password -#rabbit_password=f7999d1955c5014aa32c - - [mysql] volume_support = True device_path = /dev/vdb diff --git a/integration/scripts/trovestack b/integration/scripts/trovestack index 1ae8782dc7..7495b2099a 100755 --- a/integration/scripts/trovestack +++ b/integration/scripts/trovestack @@ -1348,7 +1348,6 @@ function cmd_gate_tests() { sudo chown -R $(whoami) /etc/trove iniset $TROVE_GUESTAGENT_CONF DEFAULT rabbit_host $CONTROLLER_IP - iniset $TROVE_GUESTAGENT_CONF oslo_messaging_rabbit rabbit_hosts $CONTROLLER_IP cd $TROVESTACK_SCRIPTS sudo -H $HTTP_PROXY pip install --upgrade pip dib-utils