Previously, we were using the Server interface to start/refresh/shutdown services.
With this change, we will be using the stopper.Stopper context to manage
services lifetime, and allow graceful termination.
The scheduler has also moved out of the metrics server, so its lifecycle can be managed
at the same level at other services.
As part of this change, we are adding test cases for the metrics server.
The list of scheduled job has been protected by a mutex.
Previously, we were using the Server interface to start/refresh/shutdown services. With this change, we will be using the stopper.Stopper context to manage services lifetime, and allow graceful termination. The scheduler has also moved out of the metrics server, so its lifecycle can be managed at the same level at other services.
As part of this change, we are adding test cases for the metrics server. The list of scheduled job has been protected by a mutex.
This change is![Reviewable](https://reviewable.io/review_button.svg)