Enable Puma on GitLab.com
We are nearing the completing initial set of Puma compatibility with GitLab.
You can follow the epic here: https://gitlab.com/groups/gitlab-org/-/epics/954.
This issue is to track the implementation of Puma for GitLab.com.
### Update
With the rollout of https://gitlab.com/gitlab-com/gl-infra/production/issues/1684 Puma has been deployed to .com
## Plan
- [x] Enable Puma on `staging.gitlab.com`,
- [x] Configure `Grafana` to gather metrics of Puma enabled servers to replicate `Unicorn` metrics
- [x] Switch to `/readiness` on separate endpoint for the application
- [x] Come up with and execute a test plan on staging that verifies no-downtime reloads with the new load balancer health check https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/8074
- [x] Increase traffic on canary so a single node as the same number of req/seconds as the main stage https://gitlab.com/gitlab-com/gl-infra/production/issues/1220
- [x] Run one node on canary with puma, the other node with unicorn https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/7455
- [x] Run puma on both canary nodes https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/7455
- [x] Use `web_exporter/metrics` for staging and production. https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/8342
- [x] Run puma on select nodes in production https://gitlab.com/gitlab-com/gl-infra/production/issues/1303
- [x] Enable puma on gitlab.com https://gitlab.com/gitlab-com/gl-infra/production/issues/1684
## Outstanding work from the development side
- [x] Refactor readiness and liveness checks https://gitlab.com/gitlab-org/gitlab/merge_requests/17960
- [x] Add readiness to include health check for blackout https://gitlab.com/gitlab-org/gitlab/merge_requests/17962
- [x] Add omnibus support for web exporter https://gitlab.com/gitlab-org/omnibus-gitlab/merge_requests/3650
- [x] Make Daemon thread-safe https://gitlab.com/gitlab-org/gitlab/merge_requests/18575
- [x] Add `on_before_phased_restart` lifecycle event https://gitlab.com/gitlab-org/gitlab/merge_requests/18582
- [x] Allow sidekiq_exporter to fail on address in use https://gitlab.com/gitlab-org/gitlab/merge_requests/18725
- [x] Missing timestamps in logs https://gitlab.com/gitlab-org/gitlab/issues/37920
- [ ] Puma process was deadlocked on web-cny-02 https://gitlab.com/gitlab-org/gitlab/issues/118839
- [x] Issue a restart instead of a reload on omnibus https://gitlab.com/gitlab-org/omnibus-gitlab/issues/4928
## Outstanding work for puma by default: https://gitlab.com/gitlab-org/gitlab-ce/issues/67284
- [ ] Defaults for Puma: https://gitlab.com/gitlab-org/omnibus-gitlab/issues/3896
- [ ] Revisit thread safety: https://gitlab.com/gitlab-org/gitlab/issues/26449
- [ ] Adjust number of db connections according to number of threads once Puma is deployed: https://gitlab.com/gitlab-org/omnibus-gitlab/issues/4631 https://gitlab.com/gitlab-org/omnibus-gitlab/issues/4631
epic