aboutsummaryrefslogtreecommitdiff
path: root/vendor/github.com/docker/go-metrics/register.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/docker/go-metrics/register.go')
-rw-r--r--vendor/github.com/docker/go-metrics/register.go15
1 files changed, 15 insertions, 0 deletions
diff --git a/vendor/github.com/docker/go-metrics/register.go b/vendor/github.com/docker/go-metrics/register.go
new file mode 100644
index 000000000..708358df0
--- /dev/null
+++ b/vendor/github.com/docker/go-metrics/register.go
@@ -0,0 +1,15 @@
+package metrics
+
+import "github.com/prometheus/client_golang/prometheus"
+
+// Register adds all the metrics in the provided namespace to the global
+// metrics registry
+func Register(n *Namespace) {
+ prometheus.MustRegister(n)
+}
+
+// Deregister removes all the metrics in the provided namespace from the
+// global metrics registry
+func Deregister(n *Namespace) {
+ prometheus.Unregister(n)
+}