Increase Railway's default 5 minute timeout for POST requests
My project is a Typescript API that uploads videos to VIMEO.
I need to edit Nginx settings for:
client_max_body_size 25600m;
client_body_buffer_size 25600m;
client_body_timeout 3000s;
proxy_read_timeout 3000s;
proxy_connect_timeout 3000s;
proxy_send_timeout 3000s;
How to do this on Railway?
15 Replies
Project ID:
N/A
i fail to see what nginx has to do with typescript, please send a link to your repo so i can advice further
Railway closes the upload connection in 300s. Is it possible to increase?
no it doesnt
ive held connections open to railway for over 30 minutes to test this sort of thing
this limit you are hitting is coming from the framework you are using in your code
My project is currently hosted at Digital Ocean, using Caprover as the PaaS provider.
I want to bring him to Railway, but this is paramount. The upload connection time has to be longer.
okay, i will test and get back to you
I tested the upload through my project and the connection closed within 5 minutes.
^
The same problem happened in Caprover and the solution was to edit the limits in Nginx.
ok
thk
im very sorry for the incorrect information, when i spoke of holding a connection open on railway for over 30 minutes, it was a GET request, i had naively thought the same would be possible for POST request too, i was wrong.
i have just been able to confirm a limit of 5 minutes for POST requests.
i think this is a completely unreasonable limit and i will bring this up to the team, but unfortunately there is nothing you can configure to change this.
Thanks for back. I will wait for news for the increase for POST requests.
if i can convince the team to do it, it likely wont be anytime soon, sorry
and even then, i don’t think they would completely remove the limit
any reason you cant upload the videos to vimeo directly?
We're not gonna do this ATM
You'll need to batch your posts or return a signed upload link
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
that would be a limit you have imposed on yourself in this case