Skip to content
Which draining configuration applies to an existing deployment on its first replacement?
regisnobel
OP

a month ago

Hi Railway team, if a running deployment started without explicit shutdown grace, and I now set service draining time to 60 seconds and overlap to 10 seconds before replacing it, will the existing deployment get 60 seconds between SIGTERM and SIGKILL? Which settings snapshot governs the old process's teardown: its original deployment configuration, current service settings, or the replacement deployment's configuration? Is there metadata to verify the effective grace before replacement? If the updated settings do not apply to the existing deployment, is there a supported in-place override without restarting it? I have read the deployment teardown and config-as-code documentation but could not resolve this first-replacement detail. Thanks.

Solved

1 Reply

Railway
BOT

a month ago

No. Draining and overlap settings are captured into each deployment when it's created, so the existing deployment's teardown uses its own original snapshot (no draining configured, so the default of 0), not your current service settings or the replacement's. The 10 second overlap does apply on this first replacement, because overlap is read from the new deployment's configuration. Your 60 second draining window takes effect for the replacement and later deployments, the next time each one is torn down.

To check the effective values before replacing, query the deployment's meta field in the public GraphQL API. The deploy section of that snapshot includes drainingSeconds and overlapSeconds when they were set. There's no supported way to change those values on a running deployment. They only change through a new deployment.


Status changed to Awaiting User Response Railway • about 1 month ago


Railway
BOT

24 days ago

This thread has been marked as solved automatically due to a lack of recent activity. Please re-open this thread or create a new one if you require further assistance. Thank you!

Status changed to Solved Railway • 24 days ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...