Unhardcode rpc_response_timeout parameter

The patch un-hardcodes rpc_response_timeout paramter in
order to have a chance to modify this via pillar. However
if the parameter is not defined then default value will be used.

Change-Id: Iacb32526950eedd9410655a330249fa10dd1396e
diff --git a/nova/files/juno/nova-compute.conf.Debian b/nova/files/juno/nova-compute.conf.Debian
index de61288..b5693e7 100644
--- a/nova/files/juno/nova-compute.conf.Debian
+++ b/nova/files/juno/nova-compute.conf.Debian
@@ -94,7 +94,9 @@
 
 rpc_cast_timeout = 30
 rpc_conn_pool_size = 300
-rpc_response_timeout = 3600
+{%- if compute.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ compute.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = 5
 
diff --git a/nova/files/juno/nova-controller.conf.Debian b/nova/files/juno/nova-controller.conf.Debian
index 633cace..0cdffdc 100644
--- a/nova/files/juno/nova-controller.conf.Debian
+++ b/nova/files/juno/nova-controller.conf.Debian
@@ -121,7 +121,9 @@
 
 rpc_cast_timeout = 30
 rpc_conn_pool_size = 300
-rpc_response_timeout = 3600
+{%- if controller.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ controller.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = 5
 
diff --git a/nova/files/kilo/nova-compute.conf.Debian b/nova/files/kilo/nova-compute.conf.Debian
index 059ae78..d76e9a1 100644
--- a/nova/files/kilo/nova-compute.conf.Debian
+++ b/nova/files/kilo/nova-compute.conf.Debian
@@ -83,7 +83,9 @@
 
 rpc_cast_timeout = 30
 rpc_conn_pool_size = 300
-rpc_response_timeout = 3600
+{%- if compute.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ compute.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = {{ compute.get('report_interval', '60') }}
 
diff --git a/nova/files/kilo/nova-controller.conf.Debian b/nova/files/kilo/nova-controller.conf.Debian
index c460bb0..64a40d8 100644
--- a/nova/files/kilo/nova-controller.conf.Debian
+++ b/nova/files/kilo/nova-controller.conf.Debian
@@ -110,7 +110,9 @@
 
 rpc_cast_timeout = 30
 rpc_conn_pool_size = 300
-rpc_response_timeout = 3600
+{%- if controller.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ controller.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = 5
 
diff --git a/nova/files/liberty/nova-compute.conf.Debian b/nova/files/liberty/nova-compute.conf.Debian
index 90e56ee..de611f7 100644
--- a/nova/files/liberty/nova-compute.conf.Debian
+++ b/nova/files/liberty/nova-compute.conf.Debian
@@ -91,7 +91,9 @@
 
 rpc_cast_timeout = 30
 rpc_conn_pool_size = 300
-rpc_response_timeout = 3600
+{%- if compute.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ compute.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = {{ compute.get('report_interval', '60') }}
 
diff --git a/nova/files/liberty/nova-controller.conf.Debian b/nova/files/liberty/nova-controller.conf.Debian
index 4ceb955..64d8c85 100644
--- a/nova/files/liberty/nova-controller.conf.Debian
+++ b/nova/files/liberty/nova-controller.conf.Debian
@@ -105,7 +105,9 @@
 
 rpc_cast_timeout = 30
 rpc_conn_pool_size = 300
-rpc_response_timeout = 3600
+{%- if controller.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ controller.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = 5
 
diff --git a/nova/files/mitaka/nova-compute.conf.Debian b/nova/files/mitaka/nova-compute.conf.Debian
index cc052e2..4b22b31 100644
--- a/nova/files/mitaka/nova-compute.conf.Debian
+++ b/nova/files/mitaka/nova-compute.conf.Debian
@@ -68,7 +68,9 @@
 firewall_driver = nova.virt.firewall.NoopFirewallDriver
 
 rpc_cast_timeout = 30
-rpc_response_timeout = 3600
+{%- if compute.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ compute.message_queue.rpc_response_timeout }}
+{%- endif %}
 executor_thread_pool_size = 70
 report_interval = {{ compute.get('report_interval', '60') }}
 
diff --git a/nova/files/mitaka/nova-controller.conf.Debian b/nova/files/mitaka/nova-controller.conf.Debian
index e0e9e38..5f568da 100644
--- a/nova/files/mitaka/nova-controller.conf.Debian
+++ b/nova/files/mitaka/nova-controller.conf.Debian
@@ -67,7 +67,9 @@
 allow_resize_to_same_host=True
 
 rpc_cast_timeout = 30
-rpc_response_timeout = 3600
+{%- if controller.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ controller.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = 5
 
diff --git a/nova/files/newton/nova-compute.conf.Debian b/nova/files/newton/nova-compute.conf.Debian
index d1e34b1..b0d8f9c 100644
--- a/nova/files/newton/nova-compute.conf.Debian
+++ b/nova/files/newton/nova-compute.conf.Debian
@@ -87,7 +87,9 @@
 firewall_driver = nova.virt.firewall.NoopFirewallDriver
 
 rpc_cast_timeout = 30
-rpc_response_timeout = 3600
+{%- if compute.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ compute.message_queue.rpc_response_timeout }}
+{%- endif %}
 executor_thread_pool_size = 70
 report_interval = {{ compute.get('report_interval', '60') }}
 
diff --git a/nova/files/newton/nova-controller.conf.Debian b/nova/files/newton/nova-controller.conf.Debian
index 1cf2bfa..26c38a1 100644
--- a/nova/files/newton/nova-controller.conf.Debian
+++ b/nova/files/newton/nova-controller.conf.Debian
@@ -74,7 +74,9 @@
 allow_resize_to_same_host=True
 
 rpc_cast_timeout = 30
-rpc_response_timeout = 3600
+{%- if controller.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ controller.message_queue.rpc_response_timeout }}
+{%- endif %}
 rpc_thread_pool_size = 70
 report_interval = 5
 
diff --git a/nova/files/ocata/nova-compute.conf.Debian b/nova/files/ocata/nova-compute.conf.Debian
index aafb8d3..60e9cd6 100644
--- a/nova/files/ocata/nova-compute.conf.Debian
+++ b/nova/files/ocata/nova-compute.conf.Debian
@@ -3090,7 +3090,9 @@
 
 # Seconds to wait for a response from a call. (integer value)
 #rpc_response_timeout=60
-rpc_response_timeout = 3600
+{%- if compute.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ compute.message_queue.rpc_response_timeout }}
+{%- endif %}
 
 {%- set rabbit_port = compute.message_queue.get('port', 5671 if compute.message_queue.get('ssl',{}).get('enabled', False) else 5672) %}
 
diff --git a/nova/files/ocata/nova-controller.conf.Debian b/nova/files/ocata/nova-controller.conf.Debian
index 42a7a0e..efafbc7 100644
--- a/nova/files/ocata/nova-controller.conf.Debian
+++ b/nova/files/ocata/nova-controller.conf.Debian
@@ -3045,7 +3045,9 @@
 
 # Seconds to wait for a response from a call. (integer value)
 #rpc_response_timeout=60
-rpc_response_timeout=3600
+{%- if controller.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ controller.message_queue.rpc_response_timeout }}
+{%- endif %}
 
 {%- set rabbit_port = controller.message_queue.get('port', 5671 if controller.message_queue.get('ssl',{}).get('enabled', False) else 5672) %}
 
diff --git a/nova/files/pike/nova-compute.conf.Debian b/nova/files/pike/nova-compute.conf.Debian
index d3aa8db..7588003 100644
--- a/nova/files/pike/nova-compute.conf.Debian
+++ b/nova/files/pike/nova-compute.conf.Debian
@@ -3094,7 +3094,9 @@
 
 # Seconds to wait for a response from a call. (integer value)
 #rpc_response_timeout=60
-rpc_response_timeout = 3600
+{%- if compute.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ compute.message_queue.rpc_response_timeout }}
+{%- endif %}
 
 {%- set rabbit_port = compute.message_queue.get('port', 5671 if compute.message_queue.get('ssl',{}).get('enabled', False) else 5672) %}
 
diff --git a/nova/files/pike/nova-controller.conf.Debian b/nova/files/pike/nova-controller.conf.Debian
index c2bdc87..ed95d88 100644
--- a/nova/files/pike/nova-controller.conf.Debian
+++ b/nova/files/pike/nova-controller.conf.Debian
@@ -3062,7 +3062,9 @@
 
 # Seconds to wait for a response from a call. (integer value)
 #rpc_response_timeout=60
-rpc_response_timeout=3600
+{%- if controller.message_queue.rpc_response_timeout is defined %}
+rpc_response_timeout = {{ controller.message_queue.rpc_response_timeout }}
+{%- endif %}
 
 {%- set rabbit_port = controller.message_queue.get('port', 5671 if controller.message_queue.get('ssl',{}).get('enabled', False) else 5672) %}
 
diff --git a/nova/map.jinja b/nova/map.jinja
index b84dc2e..651293a 100644
--- a/nova/map.jinja
+++ b/nova/map.jinja
@@ -192,7 +192,6 @@
   heal_instance_info_cache_interval: '60'
   message_queue:
     zmq_linger: 30
-    rpc_response_timeout: 3600
   logging:
     app_name: 'nova'
     log_appender: false
@@ -242,7 +241,6 @@
   heal_instance_info_cache_interval: '60'
   message_queue:
     zmq_linger: 30
-    rpc_response_timeout: 3600
   logging:
     app_name: 'nova'
     log_appender: false