Port weighted sample from JavaMetrics ( https://github.com/dropwizard/metrics/pull/421 )