rocketraman12/19/2019, 8:13 PM
I think the nginx request is timing out because
browser -> nginx rev proxy -> ktor server -> ktor client -> backend
is not set long enough. However, after the timeout, for some reason ktor client resubmits the same request to the backend again (??), and this time the backend responds with an error. This error is then received by the browser as a response to the original request, which somehow still seems to be active even though nginx timed out. Increasing proxy_read_timeout in the nginx rev proxy fixes the problem, but what is boggling my mind is what the heck is going on exactly when
is too small?