Class: GraphQL::Tracing::PrometheusTrace::PrometheusMonitor::Event
Instance Attribute Summary
#keyword, #object
Instance Method Summary
collapse
#initialize
Instance Method Details
#finish ⇒ Object
83
84
85
86
87
88
|
# File 'lib/graphql/tracing/prometheus_trace.rb', line 83
def finish
if @monitor.active?(keyword)
duration = @monitor.gettime - @start_time
@monitor.send_json(duration, keyword, object)
end
end
|
#start ⇒ Object
79
80
81
|
# File 'lib/graphql/tracing/prometheus_trace.rb', line 79
def start
@start_time = @monitor.gettime
end
|