From 3eb8fab2f494a975ea5a1d4ffba22fba80d9da43 Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Wed, 25 Sep 2024 19:13:39 +0900 Subject: [PATCH] Add support for [oslo_messaging_rabbit] enable_cancel_on_failover Depends-on: https://review.opendev.org/928440 Change-Id: Ic938d83b5362645ff3dddbb924d00a23bd90295c --- manifests/init.pp | 7 +++++++ .../notes/enable_cancel_on_failover-5738fc935aad9a20.yaml | 5 +++++ spec/classes/neutron_init_spec.rb | 1 + 3 files changed, 13 insertions(+) create mode 100644 releasenotes/notes/enable_cancel_on_failover-5738fc935aad9a20.yaml diff --git a/manifests/init.pp b/manifests/init.pp index 37941be0d..e197e238d 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -159,6 +159,11 @@ # (Optional) Limit the number of memory bytes used by the quorum queue. # Defaults to $facts['os_service_default'] # +# [*rabbit_enable_cancel_on_failover*] +# (Optional) Enable x-cancel-on-ha-failover flag so that rabbitmq server will +# cancel and notify consumers when queue is down. +# Defaults to $facts['os_service_default'] +# # [*rabbit_use_ssl*] # (optional) Connect over SSL for RabbitMQ # Defaults to $facts['os_service_default'] @@ -304,6 +309,7 @@ class neutron ( $rabbit_quorum_delivery_limit = $facts['os_service_default'], $rabbit_quorum_max_memory_length = $facts['os_service_default'], $rabbit_quorum_max_memory_bytes = $facts['os_service_default'], + $rabbit_enable_cancel_on_failover = $facts['os_service_default'], $rabbit_use_ssl = $facts['os_service_default'], $rabbit_transient_queues_ttl = $facts['os_service_default'], $amqp_durable_queues = $facts['os_service_default'], @@ -420,6 +426,7 @@ class neutron ( rabbit_quorum_delivery_limit => $rabbit_quorum_delivery_limit, rabbit_quorum_max_memory_length => $rabbit_quorum_max_memory_length, rabbit_quorum_max_memory_bytes => $rabbit_quorum_max_memory_bytes, + enable_cancel_on_failover => $rabbit_enable_cancel_on_failover, } # SSL Options diff --git a/releasenotes/notes/enable_cancel_on_failover-5738fc935aad9a20.yaml b/releasenotes/notes/enable_cancel_on_failover-5738fc935aad9a20.yaml new file mode 100644 index 000000000..550544411 --- /dev/null +++ b/releasenotes/notes/enable_cancel_on_failover-5738fc935aad9a20.yaml @@ -0,0 +1,5 @@ +--- +features: + - | + The new ``neutron::rabbit_enable_cancel_on_failover`` parameter has been + added. diff --git a/spec/classes/neutron_init_spec.rb b/spec/classes/neutron_init_spec.rb index e6f96a7e3..64fe181c0 100644 --- a/spec/classes/neutron_init_spec.rb +++ b/spec/classes/neutron_init_spec.rb @@ -94,6 +94,7 @@ describe 'neutron' do :rabbit_quorum_delivery_limit => '', :rabbit_quorum_max_memory_length => '', :rabbit_quorum_max_memory_bytes => '', + :enable_cancel_on_failover => '', ) end