Commit Graph

11 Commits

Author SHA1 Message Date
GitLab Bot c59765a50a Add latest changes from gitlab-org/gitlab@master 2020-06-24 18:09:03 +00:00
GitLab Bot 25989ab7ef Add latest changes from gitlab-org/gitlab@master 2019-10-18 11:11:44 +00:00
Thong Kuah 8c42a0eac0 Add frozen_string_literal to lib part 2
Using the sed script from
https://gitlab.com/gitlab-org/gitlab-ce/issues/59758
2019-08-23 00:15:24 +12:00
Shinya Maeda 8f14d3c140 Fix sidekiq memory killer warning message 2019-07-30 13:47:13 +07:00
Shinya Maeda ad7acfaad0 Logging sidekiq worker class name in SidekiqMemoryKiller
Currently, SidekiqMemoryKiller does not feed worker class name in the
json structured logging. This commit extends the json parameter.
2019-07-25 17:49:10 +07:00
Nick Thomas 452f508143
Fix the last-ditch memory killer pgroup SIGKILL 2019-03-09 13:34:06 +00:00
Nick Thomas f0c52df5e5 sidekiq: terminate child processes at shutdown
Sidekiq jobs frequently spawn long-lived child processes to do work.
In some circumstances, these can be reparented to init when sidekiq is
terminated, leading to duplication of work and strange concurrency
problems.

This commit changes sidekiq so that, if run as a process group leader,
it will forward `INT` and `TERM` signals to the whole process group. If
the memory killer is active, it will also use the process group when
resorting to `kill -9` to shut down.

These changes mean that a naive `kill <pid-of-sidekiq>` will now do the
right thing, killing any child processes spawned by sidekiq, as long as
the process supervisor placed it in its own process group.

If sidekiq isn't a process group leader, this new code is skipped.
2019-03-04 09:06:41 -08:00
Nick Thomas adddbf437d
SIGSTP should be SIGTSTP 2019-03-01 10:38:38 +00:00
Nick Thomas ff431fe076
Revert "Restart Unicorn and Sidekiq when GRPC throws 14:Endpoint read failed"
This reverts commit 006753110a.
2019-02-28 14:45:20 +00:00
Jacob Vosmaer (GitLab) 006753110a Restart Unicorn and Sidekiq when GRPC throws 14:Endpoint read failed 2018-02-26 09:54:20 +00:00
Douwe Maan ccb5bad6b8 Send SIGSTP before SIGTERM to actually give Sidekiq jobs 30s to finish when the memory killer kicks in 2017-11-02 15:33:19 +01:00