Change neutron backend's timeout in haproxy to 10 minutes
When client makes some heavy API requests to the Neutron API, like
e.g. some bulk request to create many ports at once it may happen that
Neutron will process the request for much longer than 2 minutes, which
is default server timeout in the haproxy's configuration for backends.
It happens e.g. with Kuryr.
Because of that, haproxy returns to the client HTTP 504 but Neutron API
is still processing API requests and finally it finishes properly.
But client may then try to retry to request which failed with 504 error
thus finally it may end up with duplicated resources created.
To avoid that, this patch increases server timeout for the neutron api
backend to 10 minutes.
Closes: rhbz#2083245
Change-Id: I0b59053618247d2a6d62d1c9e69173f3ff1d2922
(cherry picked from commit bb002c9d97
)
This commit is contained in:
parent
3bede6032b
commit
47e76e9d6e
@ -866,11 +866,13 @@ class tripleo::haproxy (
|
|||||||
|
|
||||||
if $neutron {
|
if $neutron {
|
||||||
$neutron_frontend_opts = {
|
$neutron_frontend_opts = {
|
||||||
'option' => [ 'httplog', 'forwardfor' ]
|
'timeout client' => '10m',
|
||||||
|
'option' => [ 'httplog', 'forwardfor' ]
|
||||||
}
|
}
|
||||||
$neutron_backend_opts = {
|
$neutron_backend_opts = {
|
||||||
'balance' => $haproxy_lb_mode_longrunning,
|
'timeout server' => '10m',
|
||||||
'option' => [ 'httpchk GET /healthcheck' ]
|
'balance' => $haproxy_lb_mode_longrunning,
|
||||||
|
'option' => [ 'httpchk GET /healthcheck' ]
|
||||||
}
|
}
|
||||||
$neutron_listen_opts = merge_hash_values($neutron_frontend_opts,
|
$neutron_listen_opts = merge_hash_values($neutron_frontend_opts,
|
||||||
$neutron_backend_opts)
|
$neutron_backend_opts)
|
||||||
|
Loading…
Reference in New Issue
Block a user