Skip to content
Snippets Groups Projects
Commit e1e09f5e authored by Quentin MACHU's avatar Quentin MACHU
Browse files

Setup rabbitmq to use keepalives (https://bugs.launchpad.net/nova/+bug/856764)...

Setup rabbitmq to use keepalives (https://bugs.launchpad.net/nova/+bug/856764) & rewrote its ha-all policy
parent a2a64b71
Branches
Tags
No related merge requests found
......@@ -20,7 +20,7 @@ class iaas::profile::rabbitmq (
cluster_node_type => 'ram',
wipe_db_on_cookie_change => true,
cluster_partition_handling => 'pause_minority',
tcp_keepalive => true, #FIXME May cause connectivity issues with OpenStack in some configurations
config_variables => { 'tcp_listen_options' => "[binary, {packet, raw}, {reuseaddr, true}, {backlog, 128}, {nodelay, true}, {exit_on_close, false}, {keepalive, true}]" },
} ->
rabbitmq_user { $user:
admin => true,
......@@ -33,9 +33,14 @@ class iaas::profile::rabbitmq (
read_permission => '.*',
provider => 'rabbitmqctl',
} ->
exec { 'rabbitmq_ha_queues':
command => "rabbitmqctl set_policy ha-all \"^.*\" \'{\"ha-mode\":\"all\"}\'",
unless => "rabbitmqctl list_policies | grep ha-all"
rabbitmq_policy { 'ha-all@/':
pattern => '.*',
priority => 0,
applyto => 'all',
definition => {
'ha-mode' => 'all',
'ha-sync-mode' => 'automatic',
},
}
@@haproxy::balancermember { "rabbitmq_${::fqdn}":
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment