tim-group / java-statsd-client

a java statsd client library
Other
275 stars 139 forks source link

additional gauge functionality -- deltas #6

Closed if6was9 closed 10 years ago

if6was9 commented 11 years ago

Three enhancements:

1) Added support for gauges with scalar deltas as described here:

https://github.com/etsy/statsd/blob/master/docs/metric_types.md#gauges

foo:+50|g ==> "add 50 to current value of foo" foo:-10|g ==> "subtract 10 from current value of foo"

2) Related to #1, fixed defect in existing code where recordGaugeValue("foo", -20) will be sent to statsd such that it will be interpreted as "subtract 20 from current value of foo", even though the the intent of the method is clearly "set the value of foo to -20"

3) Removed final modifier on classes to make it easier to extend functionality without modifying source

scarytom commented 10 years ago

Firstly, apologies for letting this go dormant for so long.

I'd like to enhance the java-statsd-client to support gauge deltas, but I'm not happy tying this to tangential changes like 92fe8c60fb771ab412578a8bb5a2e3e6f9acb11b, and, for that reason, I'm not going to merge this pull request.

If you re-submit your pull request with a focussed set of changes, I would pull it, but, as I'm working on this codebase today, and I plan on adding support for gauge deltas, I don't think it is worth you doing this.

I will close this pull request once I've pushed my changes to support gauge deltas.