Skip to content

Allow daemon to receive a synchronous option that joins threads

Roy Zwambag requested to merge 346123-daemon-join-threads into master

What does this MR do and why?

This MR is a part of a larger plan to set up a separate Sidekiq metrics server to export metrics &6409 (closed).

We created a PoC where we found that we have to join the thread when running the sidekiq metrics server as a process. In this MR we give the option to give a synchronous key to daemon.rb (or any of its subclasses) that will join the thread when running start. Currently this feature is not yet used anywhere, but will be in a future MR, see this commit for the full implementation (including the use of synchronous): !73049 (67052df8)

How to set up and validate locally

Currently, this MR does not change any functionality. We can test if the current logic still works by:

  1. gdk start
  2. Ensure any child of Daemon runs fine. Example: SidekiqExporter still runs: curl localhost:3807/liveness (if using default port) and serves metrics: curl localhost:3807/metrics

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #346123 (closed)

Edited by Roy Zwambag

Merge request reports