Class: EventTracer::PrometheusLogger
- Inherits:
-
MetricLogger
- Object
- Delegator
- BasicDecorator
- MetricLogger
- EventTracer::PrometheusLogger
- Defined in:
- lib/event_tracer/prometheus_logger.rb
Constant Summary collapse
- SUPPORTED_METRIC_TYPES =
{ counter: :increment_count, gauge: :set_gauge }.freeze
- DEFAULT_METRIC_TYPE =
:increment_count
- DEFAULT_COUNTER =
1
Instance Attribute Summary
Attributes inherited from MetricLogger
Instance Method Summary collapse
-
#initialize(prometheus, allowed_tags: [], default_tags: {}, raise_if_missing: true) ⇒ PrometheusLogger
constructor
A new instance of PrometheusLogger.
Methods inherited from BasicDecorator
#__getobj__, #__setobj__, #fail_result, #success_result
Constructor Details
#initialize(prometheus, allowed_tags: [], default_tags: {}, raise_if_missing: true) ⇒ PrometheusLogger
Returns a new instance of PrometheusLogger.
13 14 15 16 17 18 |
# File 'lib/event_tracer/prometheus_logger.rb', line 13 def initialize(prometheus, allowed_tags: [], default_tags: {}, raise_if_missing: true) super(prometheus) @allowed_tags = .freeze @default_tags = .freeze @raise_if_missing = raise_if_missing end |