Class: Strumbar::Client

Inherits:
Statsd
  • Object
show all
Defined in:
lib/strumbar/client.rb

Instance Method Summary collapse

Constructor Details

#initialize(host, port) ⇒ Client

Returns a new instance of Client.



5
6
7
8
# File 'lib/strumbar/client.rb', line 5

def initialize host, port
  @host = host
  @port = port
end

Instance Method Details

#count(stat, value, sample_rate = Strumbar.default_rate) ⇒ Object



22
23
24
# File 'lib/strumbar/client.rb', line 22

def count stat, value, sample_rate = Strumbar.default_rate
  super "#{Strumbar.application}.#{stat}", value, sample_rate
end

#decrement(stat, sample_rate = Strumbar.default_rate) ⇒ Object



18
19
20
# File 'lib/strumbar/client.rb', line 18

def decrement stat, sample_rate = Strumbar.default_rate
  super stat, sample_rate
end

#gauge(stat, value, sample_rate = Strumbar.default_rate) ⇒ Object



26
27
28
# File 'lib/strumbar/client.rb', line 26

def gauge stat, value, sample_rate = Strumbar.default_rate
  super "#{Strumbar.application}.#{stat}", value, sample_rate
end

#increment(stat, sample_rate = Strumbar.default_rate) ⇒ Object



14
15
16
# File 'lib/strumbar/client.rb', line 14

def increment stat, sample_rate = Strumbar.default_rate
  super stat, sample_rate
end

#set(stat, value, sample_rate = Strumbar.default_rate) ⇒ Object



30
31
32
# File 'lib/strumbar/client.rb', line 30

def set stat, value, sample_rate = Strumbar.default_rate
  super "#{Strumbar.application}.#{stat}", value, sample_rate
end

#timing(stat, time, sample_rate = Strumbar.default_rate) ⇒ Object



10
11
12
# File 'lib/strumbar/client.rb', line 10

def timing stat, time, sample_rate = Strumbar.default_rate
  super "#{Strumbar.application}.#{stat}", time, sample_rate
end