/** * This is a hack to work around limitations in Jmxutils. */ @Deprecated public void resetTo(CounterStat counterStat) { oneMinute.resetTo(counterStat.getOneMinute()); fiveMinute.resetTo(counterStat.getFiveMinute()); fifteenMinute.resetTo(counterStat.getFifteenMinute()); count.set(counterStat.getTotalCount()); }
public void merge(CounterStat counterStat) { requireNonNull(counterStat, "counterStat is null"); oneMinute.merge(counterStat.getOneMinute()); fiveMinute.merge(counterStat.getFiveMinute()); fifteenMinute.merge(counterStat.getFifteenMinute()); count.addAndGet(counterStat.getTotalCount()); }
/** * This is a hack to work around limitations in Jmxutils. */ @Deprecated public void resetTo(CounterStat counterStat) { oneMinute.resetTo(counterStat.getOneMinute()); fiveMinute.resetTo(counterStat.getFiveMinute()); fifteenMinute.resetTo(counterStat.getFifteenMinute()); count.set(counterStat.getTotalCount()); }
public void merge(CounterStat counterStat) { requireNonNull(counterStat, "counterStat is null"); oneMinute.merge(counterStat.getOneMinute()); fiveMinute.merge(counterStat.getFiveMinute()); fifteenMinute.merge(counterStat.getFifteenMinute()); count.addAndGet(counterStat.getTotalCount()); }
public CounterStatSnapshot snapshot() { return new CounterStatSnapshot(getTotalCount(), getOneMinute().snapshot(), getFiveMinute().snapshot(), getFifteenMinute().snapshot()); }
public CounterStatSnapshot snapshot() { return new CounterStatSnapshot(getTotalCount(), getOneMinute().snapshot(), getFiveMinute().snapshot(), getFifteenMinute().snapshot()); }