Sha256: 9d1316e6bec91ca7c1193ccc33357027a1dddd2134fe12182ef6919f1fbb102f

Contents?: true

Size: 439 Bytes

Versions: 24

Compression:

Stored size: 439 Bytes

Contents

require "cabin/namespace"
require "cabin/publisher"
require "cabin/inspectable"

module Cabin::Metric
  include Cabin::Inspectable
  include Cabin::Publisher

  def instance=(instance)
    @instance = instance
  end # def instance=

  def instance
    return @instance
  end # def instance

  def emit
    if !@channel.nil?
      @channel.publish({ :metric => instance }.merge(to_hash))
    end
  end # def emit
end # module Cabin::Metric

Version data entries

24 entries across 22 versions & 6 rubygems

Version Path
logstash-filter-zabbix-0.1.2 vendor/bundle/jruby/1.9/gems/cabin-0.8.1/lib/cabin/metric.rb
logstash-filter-zabbix-0.1.1 vendor/bundle/jruby/1.9/gems/cabin-0.8.1/lib/cabin/metric.rb
ivanvc-logstash-input-s3-3.1.1.4 vendor/local/gems/cabin-0.8.1/lib/cabin/metric.rb
ivanvc-logstash-input-s3-3.1.1.3 vendor/local/gems/cabin-0.8.1/lib/cabin/metric.rb
ivanvc-logstash-input-s3-3.1.1.2 vendor/local/gems/cabin-0.8.1/lib/cabin/metric.rb
cabin-0.9.0 lib/cabin/metric.rb
able-neo4j-1.0.0 vendor/bundle/jruby/1.9/gems/cabin-0.7.1/lib/cabin/metric.rb
cabin-0.8.1 lib/cabin/metric.rb
cabin-0.8.0 lib/cabin/metric.rb
logstash-input-beats-2.0.2 vendor/jruby/1.9/gems/logstash-codec-json-2.0.3/vendor/gems/cabin-0.7.2/lib/cabin/metric.rb
logstash-input-beats-2.0.2 vendor/jruby/1.9/gems/cabin-0.7.1/lib/cabin/metric.rb
logstash-input-beats-2.0.2 vendor/jruby/1.9/gems/cabin-0.7.2/lib/cabin/metric.rb
logstash-codec-json-2.0.3 vendor/gems/cabin-0.7.2/lib/cabin/metric.rb
cabin-0.7.2 lib/cabin/metric.rb
logstash-input-beats-0.9.2 vendor/jruby/1.9/gems/cabin-0.7.1/lib/cabin/metric.rb
logstash-input-beats-0.9.1 vendor/jruby/1.9/gems/cabin-0.7.1/lib/cabin/metric.rb
cabin-0.7.1 lib/cabin/metric.rb
cabin-0.6.1 lib/cabin/metric.rb
cabin-0.6.0 lib/cabin/metric.rb
cabin-0.5.0 lib/cabin/metric.rb