argoproj / argo-workflows

Workflow Engine for Kubernetes
https://argo-workflows.readthedocs.io/
Apache License 2.0
14.81k stars 3.17k forks source link

Add Header `X-Accel-Buffering: no` to server responses to improve buffering with clients #9286

Open sid8489 opened 2 years ago

sid8489 commented 2 years ago

# Summary We have been below facing workflows UI issues in production env, where ingress is enabled Note: our ingress controller -> KONG

Also we didn't see any error in network calls or web console. All of this was not happening when proxying the server over localhost.

After looking into github issues, we came across a bunch of issues where people reported same problem.

Solution: In some of these issues people mentioned that they got it fixed by disabling proxy_buffering on the ingress-controller side. We tried the same workaround and were able to resolve all above mentioned issues.
We weren't allowed to disabling proxy_buffering on ingress-controller side, so we set "X-Accel-Buffering: no" headers to argo SSE responses.

We propose the same, argo-server should add header "X-Accel-Buffering: no" to responses to improve buffering b/w server and client, either by default or optional via cli param

What change needs making? PR

Use Cases


Message from the maintainers:

Love this enhancement proposal? Give it a 👍. We prioritise the proposals with the most 👍.

DavidConnack commented 1 year ago

Im also experiencing this. I have my argo workflows deployed via helm behind a Kong ingress controller. Some calls are just pending. I cant set the disable the buffer as it will affect our other applications. image

DavidConnack commented 1 year ago

I manged to solve this with the following kong annotation