Closed thatsnoi closed 1 year ago
I see that I can set the timeout like this: createSomething.useMutation({ callOptions: { timeoutMs: 20000 } }) but this results in a CORS error: Access to fetch at 'http://localhost:8080/api.v1....' from origin 'http://localhost:3000' has been blocked by CORS policy: Request header field grpc-timeout is not allowed by Access-Control-Allow-Headers in preflight response.
Hey Noah, I recommend to investigate what exactly is timing out first. A HTTP 504 response is not a typical response for a gRPC-web service. You can take a look at the response in the network inspector in the browser.
It seems most likely that the server or an intermediary is timing out, and responding with a HTTP 504 response, possibly with a HTML body with more details.
Thanks Timo! You were right, the issue was related to envoy proxy and not to the client :)
Currently, I'm getting a 504 timeout error because the request takes too long. I haven't found any documentation on how to configure it. Im using createGrpcWebTransport to init the transport but AFAIK it doens't have an option to set a timeout (related https://github.com/connectrpc/connect-es/issues/799) How do I increase the deadline/timeout of my RPC Call while using tanstack?