Module: HGAPI
- Defined in:
- lib/hg_api.rb,
lib/hg_api/client.rb,
lib/hg_api/version.rb
Overview
Usage example:
client = HGAPI.new
client.metric("signup", 1)
client.metric("load", 100, via: :tcp)
Default transport is udp, it can be changed by passing options hash while constructing client:
client = HGAPI.new(via: :http)
client.metric("this.metric.send.over.http", 5)
Supported transports: udp, tcp, http.
API KEY must be present as environmental variable HOSTED_GRAPHITE_API_KEY.
Defined Under Namespace
Classes: Client
Constant Summary collapse
- VERSION =
"0.0.3"
Class Method Summary collapse
Class Method Details
.new(options = {}) ⇒ Object
24 25 26 |
# File 'lib/hg_api.rb', line 24 def self.new = {} Client.new end |
.version ⇒ Object
20 21 22 |
# File 'lib/hg_api.rb', line 20 def self.version HGAPI::VERSION end |