Skip to content

Commit

Permalink
Update docs and examples to use count instead of deprecated `counte…
Browse files Browse the repository at this point in the history
…r` (#177)
  • Loading branch information
lukeasrodgers authored and gzussa committed Jan 16, 2020
1 parent 754758b commit bf4cfc4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion examples/custom_metric.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@
# Emit differents metrics in a single request to be more efficient
dog.batch_metrics do
dog.emit_point('test.api.test_metric',10)
dog.emit_point('test.api.this_other_metric', 1, :type => 'counter')
dog.emit_point('test.api.this_other_metric', 1, :type => 'count')
end
4 changes: 2 additions & 2 deletions lib/dogapi/facade.rb
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def initialize(api_key, application_key=nil, host=nil, device=nil, silent=true,
# :device => String
# :options => Map
#
# options[:type] = "counter" to specify a counter metric
# options[:type] = "count" to specify a counter metric
# options[:tags] = ["tag1", "tag2"] to tag the point
def emit_point(metric, value, options= {})
defaults = { :timestamp => Time.now }
Expand All @@ -143,7 +143,7 @@ def emit_point(metric, value, options= {})
# :device => String
# :options => Map
#
# options[:type] = "counter" to specify a counter metric
# options[:type] = "count" to specify a counter metric
# options[:tags] = ["tag1", "tag2"] to tag the point
def emit_points(metric, points, options= {})
scope = override_scope options
Expand Down

0 comments on commit bf4cfc4

Please sign in to comment.