gitlab-org--gitlab-foss/lib/gitlab/metrics/dummy_metric.rb
Pawel Chojnacki 5bc099c2de Prometheus metrics first pass
metrics wip
2017-06-02 19:45:57 +02:00

29 lines
479 B
Ruby

module Gitlab
module Metrics
# Mocks ::Prometheus::Client::Metric and all derived metrics
class DummyMetric
def get(*args)
raise NotImplementedError
end
def values(*args)
raise NotImplementedError
end
# counter
def increment(*args)
# noop
end
# gauge
def set(*args)
# noop
end
# histogram / summary
def observe(*args)
# noop
end
end
end
end