Bug 32716: larger proxy_buffer_size in NGINX example config
authorGalen Charlton <gmc@equinoxOLI.org>
Tue, 24 Jan 2023 19:10:32 +0000 (14:10 -0500)
committerArthur Suzuki <arthur.suzuki@biblibre.com>
Tue, 23 May 2023 18:43:31 +0000 (20:43 +0200)
commit617eab9d39b8e4dbdcf495b81de2f8601b1b7a5c
tree6256885c980e9b395d872c0a2cc58532c971958d
parentabd52f343dd01b3560644a7ed073e6dd685c03c9
Bug 32716: larger proxy_buffer_size in NGINX example config

This patch updates the example NGINX config to increase the
proxy_buffer_size to 16k. The default value of 4k (on some platforms)
has empirically been shown to be a bit too small for the Link
headers emitted by the REST API when pagination is requested.

To test
-------
[1] Set up a Koha system with NGINX as a reverse proxy in
    front of it (either in front of Apache or in front of
    of Starman).
[2] Perform a patron search that returns at least two pages
    of results and navigate to the second page.
[3] Note that the navigation can fail with a 502 HTTP error
    and an "upstream sent too big header while reading response
    header from upstream" error in the NGINX log.

    The problem is most likely when the pagesize of the server
    running NGINX is 4096 bytes.
[4] Update the NGINX configuration per this patch and restart
    NGINX.
[5] This time, repeating step 2 should work.

Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a29964778a44ef6f7f4a8400df4ef12ab80f5ed6)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
(cherry picked from commit 18c75b9bf9b0ea206f159ed1f94fa8b1eada4c12)
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 078324588251cdfe6d10bb1970079d60d5d070b6)
Signed-off-by: Arthur Suzuki <arthur.suzuki@biblibre.com>
etc/nginx.conf