code: func InstrumentHandlerFunc(verb, group, version, resource, subresource, scope, component string, handler http.HandlerFunc) http.HandlerFunc {
  	return func(w http.ResponseWriter, req *http.Request) {
  		now := time.Now()
  
  		delegate := &ResponseWriterDelegator{ResponseWriter: w}
  
  		_, cn := w.(http.CloseNotifier)
  		_, fl := w.(http.Flusher)
  		_, hj := w.(http.Hijacker)
  		if cn && fl && hj {
  			w = &fancyResponseWriterDelegator{delegate}
  		} else {
  			w = delegate
  		}
  
  		handler(w, req)
  
  		MonitorRequest(req, verb, group, version, resource, subresource, scope, component, delegate.Header().Get("Content-Type"), delegate.Status(), delegate.ContentLength(), time.Since(now))
  	}
  }
docs: // InstrumentHandlerFunc works like Prometheus' InstrumentHandlerFunc but adds some Kubernetes endpoint specific information.