Browse Source

Allow oslo rabbit heartbeat configuration

In order to allow components to better handle and respond to mq failures,
oslo has some heartbeat options that are useful.

Change-Id: I02faeba2c10d9c9b8035819156bfdc0759bafcc6
Partial-Bug: #1462438
tags/kilo-eol
Mark Vanderwiel 4 years ago
parent
commit
430f5f7466
2 changed files with 9 additions and 1 deletions
  1. 3
    1
      spec/common_spec.rb
  2. 6
    0
      templates/default/ceilometer.conf.erb

+ 3
- 1
spec/common_spec.rb View File

@@ -94,7 +94,9 @@ describe 'openstack-telemetry::common' do
94 94
 
95 95
         it 'has default RPC/AMQP options set' do
96 96
           [/^amqp_durable_queues=false$/,
97
-           /^amqp_auto_delete=false$/].each do |line|
97
+           /^amqp_auto_delete=false$/,
98
+           /^heartbeat_timeout_threshold=0$/,
99
+           /^heartbeat_rate=2$/].each do |line|
98 100
             expect(chef_run).to render_config_file(file.name).with_section_content('oslo_messaging_rabbit', line)
99 101
           end
100 102
         end

+ 6
- 0
templates/default/ceilometer.conf.erb View File

@@ -105,6 +105,12 @@ qpid_topology_version=<%= node["openstack"]["mq"]["telemetry"]["qpid"]["topology
105 105
 # From oslo.messaging
106 106
 #
107 107
 
108
+# Number of seconds after which the Rabbit broker is considered down if heartbeat's keep-alive fails (0 disable the heartbeat)
109
+heartbeat_timeout_threshold=<%= node['openstack']['mq']['telemetry']['rabbit']['heartbeat_timeout_threshold'] %>
110
+
111
+# How often times during the heartbeat_timeout_threshold we check the heartbeat
112
+heartbeat_rate=<%= node['openstack']['mq']['telemetry']['rabbit']['heartbeat_rate'] %>
113
+
108 114
 # Use durable queues in AMQP. (boolean value)
109 115
 amqp_durable_queues=<%= node["openstack"]["mq"]["telemetry"]["durable_queues"] %>
110 116
 

Loading…
Cancel
Save