示例#1
0
文件: standard.go 项目: Rozandas/etcd
func (smb standardBucket) Dump(w io.Writer) {
	gometrics.WriteOnce(smb.registry, w)
	return
}
示例#2
0
// printMetrics will print all metrics from the default registry in the response
func (c *healthController) printMetrics(w http.ResponseWriter, r *http.Request, ps httprouter.Params) error {
	buffer := new(bytes.Buffer)
	metrics.WriteOnce(metrics.DefaultRegistry, buffer)
	c.Text(w, http.StatusOK, buffer.String())
	return nil
}