Class: OneApm::Agent::Instrumentation::MongoCommandSubscriber
- Inherits:
-
Object
- Object
- OneApm::Agent::Instrumentation::MongoCommandSubscriber
- Defined in:
- lib/one_apm/inst/nosql/mongo2.rb
Constant Summary collapse
- OA_MONGODB =
'MongoDB'.freeze
- OA_STARTED =
'STARTED'.freeze
- OA_SUCCEEDED =
'SUCCEEDED'.freeze
- OA_FAILED =
'FAILED'.freeze
Instance Method Summary collapse
Instance Method Details
#failed(event) ⇒ Object
26 27 28 |
# File 'lib/one_apm/inst/nosql/mongo2.rb', line 26 def failed(event) operator OA_FAILED, event end |
#started(event) ⇒ Object
13 14 15 16 17 18 19 20 |
# File 'lib/one_apm/inst/nosql/mongo2.rb', line 13 def started(event) begin return unless OneApm::Manager.tl_is_execution_traced? operations[event.operation_id] = event rescue Exception => e log_operations_error(OA_STARTED, e) end end |
#succeeded(event) ⇒ Object
22 23 24 |
# File 'lib/one_apm/inst/nosql/mongo2.rb', line 22 def succeeded(event) operator OA_SUCCEEDED, event end |