Module: HostedGraphite

Extended by:
Forwardable, HostedGraphite
Included in:
HostedGraphite
Defined in:
lib/hosted_graphite/protocols/http.rb,
lib/hosted_graphite.rb,
lib/hosted_graphite/testing.rb,
lib/hosted_graphite/version.rb,
lib/hosted_graphite/protocol.rb,
lib/hosted_graphite/ext/sidekiq.rb,
lib/hosted_graphite/protocols/tcp.rb,
lib/hosted_graphite/protocols/udp.rb,
lib/hosted_graphite/protocols/statsd.rb

Overview

ANALYSE, is this implementation thread safe ?

Defined Under Namespace

Modules: Ext Classes: HTTP, MissingAPIKey, Protocol, STATSD, TCP, UDP

Constant Summary collapse

VERSION =
'0.1.1'

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#api_keyObject



21
22
23
# File 'lib/hosted_graphite.rb', line 21

def api_key
  @api_key ||= ENV['HOSTEDGRAPHITE_APIKEY']
end

#namespaceObject

Returns the value of attribute namespace.



9
10
11
# File 'lib/hosted_graphite.rb', line 9

def namespace
  @namespace
end

#protocolObject

Returns the value of attribute protocol.



9
10
11
# File 'lib/hosted_graphite.rb', line 9

def protocol
  @protocol
end

Class Method Details

.send_metricObject

.testingObject Also known as: increment, decrement, count, gauge, set, timing, time



20
21
22
# File 'lib/hosted_graphite/testing.rb', line 20

def testing(*)
  yield if block_given?
end

Instance Method Details

#statsdObject



19
20
21
# File 'lib/hosted_graphite/protocols/statsd.rb', line 19

def statsd
  @statsd ||= STATSD.new
end