Module: Vx::ContainerConnector::Instrument
Instance Method Summary collapse
Instance Method Details
#instrument(name, payload, &block) ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/vx/container_connector/mixin/instrument.rb', line 5 def instrument(name, payload, &block) name = "#{name}.container_connector.vx" if ENV['VX_CONTAINER_CONNECTOR_DEBUG'] $stdout.puts " --> #{name}: #{payload}" end if inst = ContainerConnector.instrumenter inst.instrument(name, payload, &block) else yield if block_given? end end |