Open mcfunley opened 9 years ago
The issue with the tests is that ThreadLocalRandom
is new in Java 7, and this is targeting Java 6 apparently. The documentation warns about contention with Math.Random
, which is why I switched it. I think the best thing to do is upgrade to Java 7, but lmk if you'd rather go the other way with this and I'll fix it.
Upgrade to Java 7 sounds good. Java 6 is really kinda dated nowadays.
Is this PR in a release?
Is this repo dead?
https://github.com/DataDog/java-dogstatsd-client appears to be a more actively maintained version of this project, I recommend submitting your patch there if you have not already done so.
Sampling is intended to be implemented by statsd clients. If the
sampleRate
provided is 0.5, for example, that implies that the client is only sending 50% of the packets and that the server should scale up the number of counts received by a factor of two. See for example the PHP client.The existing implementation of the java client sends along a sample rate, but it doesn't actually sample. This PR fixes that issue.