.Net Metrics Functionality

12 views
Skip to first unread message

Brett Skinner

unread,
Apr 19, 2017, 11:04:25 AM4/19/17
to metrics-user
Hi

I have used .Net Metrics which was meant to have been inspired by the Codahale project for a number of projects. There is functionality that is present in the .Net version that doesn't seem to be present in the Java version. I just wanted to double check that I haven't missed something and it is in fact present. For example, counters in the .Net version have an overload on the increment method which takes a string. For example

Counter counter = Metric.Counter("Colors", Unit.Custom("Colors"));
counter.Increment("Red");
counter.Increment("Red");
counter.Increment("Red");
counter.Increment("Blue");
counter.Increment("Green");

Then when you query the counter (via HTTP endpoint) it will say that the total count is 5, Red count is 3 and 60%, blue count is 1 and 20% and green count is 1 and also 20%.

Does something like the above exist in the Java version?

Regards,
Reply all
Reply to author
Forward
0 new messages