How does Fly handle in-flight-requests to old instances when shutting them down during deployment? Is there a wait time allowing in-flight-requests to be finished by these instances? Does setting kill_timeout affect this?
I thought this might be of interest for the community, so asking here not via support mail.
You also need to make sure the app no longer accepts new requests, so the app needs to handle kill_signal and close the listening socket.
Our proxy won’t send new requests to machines that are cordoned (blue/green deployment) or being updated to a new version (rolling/immediate deployment), but it still takes some time for this info to propagate to proxies in all regions, so it’s best for the app to stop accepting new requests if it knows it’s being shut down.