Add monitoring and healthz based on tunnel health.
This commit is contained in:
@@ -131,9 +131,9 @@ func (g *APIGroupVersion) InstallREST(container *restful.Container) error {
|
||||
|
||||
// TODO: document all handlers
|
||||
// InstallSupport registers the APIServer support functions
|
||||
func InstallSupport(mux Mux, ws *restful.WebService, enableResettingMetrics bool) {
|
||||
func InstallSupport(mux Mux, ws *restful.WebService, enableResettingMetrics bool, checks ...healthz.HealthzChecker) {
|
||||
// TODO: convert healthz and metrics to restful and remove container arg
|
||||
healthz.InstallHandler(mux)
|
||||
healthz.InstallHandler(mux, checks...)
|
||||
mux.Handle("/metrics", prometheus.Handler())
|
||||
if enableResettingMetrics {
|
||||
mux.HandleFunc("/resetMetrics", metrics.Reset)
|
||||
|
Reference in New Issue
Block a user