Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use statsd #count instead of #increment #12

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions lib/resque/metrics/backends/statsd.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def increment_metric(metric, by = 1)
when 'time'
statsd.timing key, by
when 'count'
statsd.increment key, by
statsd.count key, by
else
raise "Not sure how to increment_metric for a #{time_or_count} metric (#{metric})"
end
Expand All @@ -42,7 +42,7 @@ def increment_metric(metric, by = 1)
else
"#{metric_prefix}.payload_size.#{time_or_count}"
end
statsd.increment key, by
statsd.count key, by
else
raise "Not sure how to increment_metric #{metric}"
end
Expand All @@ -56,7 +56,7 @@ def set_metric(metric, val)
raise "Not sure how to set_metric #{metric}"
end
end

# set_avg: let statsd & graphite handle that
# get_metric: would have to talk to graphite. but man, complicated
end
Expand Down