Closed CwjXFH closed 5 days ago
I can't reproduce that.
Note that request timeouts do not apply when you have a debugger attached. Are you seeing the same behavior without one?
Side note: "Methods"
as part of the destination config are not recognized by YARP and will be ignored.
Hi,
I changed Timeout from 00:00:01 to 00:00:1 and it works, strange.
But when the request timed out, it returned a 400 instead of a 504.
I changed Timeout from 00:00:01 to 00:00:1 and it works, strange.
Both are parsed to the same value when reading the configuration file and as such behave exactly the same way. Are you sure you did not make any other changes?
Are you able to create a minimal runnable repro for the issue?
But when the request timed out, it returned a 400 instead of a 504.
When a timeout is hit, you're effectively terminating the request from the client as far as YARP is concerned.
If you were seeing that in a browser, it's possible that you're seeing a manufactured error the browser came up with when the request failed.
Since the timeout can occur at any point during a request/response, it's also possible that YARP already responded with a status code, but the request was canceled while we were copying data back to the client. At that point, the status code has already been sent, so it can't change.
Triage: Closing as answered. Let us know if we missed anything.
Hi,
I configured the timeout as described in the documentation, but it didn't work.
My configuration and code are as follows:
The
Timeout
configuration is not working. I sent a request, and it takes about 15s to return 504 Gateway Timeout.