1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
|
Author: Thomas Goirand <zigo@debian.org>
Date: Thu, 13 Mar 2025 10:23:12 +0100
Description: Add a rabbit_transient_queues_ttl and amqp_auto_delete params
The amqp_auto_delete option needs this patch:
https://review.opendev.org/c/openstack/puppet-oslo/+/944132
.
Since transient_queues_ttl is also managed by oslo::messaging::rabbit,
there's no way to use keystone_config to set it, so this patch is
mandatory for one to set rabbit_transient_queues_ttl in barbican.conf.
Change-Id: Icccd8435e20bdf270c03da5614e0d58f172c9f75
Forwarded: https://review.opendev.org/c/openstack/puppet-barbican/+/944197
Last-Update: 2025-03-13
Index: puppet-module-barbican/manifests/api.pp
===================================================================
--- puppet-module-barbican.orig/manifests/api.pp
+++ puppet-module-barbican/manifests/api.pp
@@ -79,6 +79,14 @@
# (Optional) Use quorum queues for transients queues in RabbitMQ.
# Defaults to $facts['os_service_default']
#
+# [*rabbit_transient_queues_ttl*]
+# (Optional) Positive integer representing duration in seconds for
+# queue TTL (x-expires). Queues which are unused for the duration
+# of the TTL are automatically deleted.
+# The parameter affects only reply and fanout queues. (integer value)
+# Min to 1
+# Defaults to $facts['os_service_default']
+#
# [*rabbit_quorum_delivery_limit*]
# (Optional) Each time a message is rdelivered to a consumer, a counter is
# incremented. Once the redelivery count exceeds the delivery limit
@@ -127,6 +135,10 @@
# (Optional) Specifies the number of messages to prefetch.
# Defaults to $facts['os_service_default']
#
+# [*amqp_auto_delete*]
+# (Optional) Define if transient queues should be auto-deleted (boolean value)
+# Defaults to $facts['os_service_default']
+#
# [*amqp_durable_queues*]
# (optional) Define queues as "durable" to rabbitmq.
# Defaults to $facts['os_service_default']
@@ -279,11 +291,13 @@ class barbican::api (
$rabbit_ha_queues = $facts['os_service_default'],
$rabbit_quorum_queue = $facts['os_service_default'],
$rabbit_transient_quorum_queue = $facts['os_service_default'],
+ $rabbit_transient_queues_ttl = $facts['os_service_default'],
$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'],
$amqp_durable_queues = $facts['os_service_default'],
+ $amqp_auto_delete = $facts['os_service_default'],
$enable_queue = $facts['os_service_default'],
$queue_namespace = $facts['os_service_default'],
$queue_topic = $facts['os_service_default'],
@@ -343,6 +357,7 @@ class barbican::api (
kombu_reconnect_delay => $kombu_reconnect_delay,
kombu_failover_strategy => $kombu_failover_strategy,
amqp_durable_queues => $amqp_durable_queues,
+ amqp_auto_delete => $amqp_auto_delete,
kombu_compression => $kombu_compression,
kombu_ssl_ca_certs => $kombu_ssl_ca_certs,
kombu_ssl_certfile => $kombu_ssl_certfile,
@@ -351,6 +366,7 @@ class barbican::api (
rabbit_ha_queues => $rabbit_ha_queues,
rabbit_quorum_queue => $rabbit_quorum_queue,
rabbit_transient_quorum_queue => $rabbit_transient_quorum_queue,
+ rabbit_transient_queues_ttl => $rabbit_transient_queues_ttl,
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,
|