Skip to content

Improve restart sequence of Puma

Kamil Trzciński requested to merge puma-signal-handling into master

This aligns Puma to use gitlab-ctl hup puma to perform something that resembles zero-downtime.

The hup internally is translated by runit to be a sequence of int+term+kill that ensures that process was restared.

This is a long outstanding problem of handling signals.

It seems that we kind of assume that gitlab-ctl hup performs something that ressembles graceful restart.

This MR changes our gitlab-ctl reconfigure and gitlab-ctl hup to behave as such, but also ensures that process is in fact rotated.

This approach (of full process restart) does not really have any downsides, as it makes us to clean metrics and reload all environment variables, in a fully graceful way: finish all current requests, and use blackout period.

Merge request reports