com.datastax.driver.core.policies
Class LatencyAwarePolicy.Snapshot.Stats

java.lang.Object
  extended by com.datastax.driver.core.policies.LatencyAwarePolicy.Snapshot.Stats
Enclosing class:
LatencyAwarePolicy.Snapshot

public static class LatencyAwarePolicy.Snapshot.Stats
extends Object

A snapshot of the statistics on a given host kept by LatencyAwarePolicy.


Method Summary
 long getLatencyScore()
          The latency score for the host this is the stats of at the time of the snapshot.
 long getMeasurementsCount()
          The number of recorded latency measurements for the host this is the stats of.
 long lastUpdatedSince()
          The number of nanoseconds since the last latency update was recorded (at the time of the snapshot).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

lastUpdatedSince

public long lastUpdatedSince()
The number of nanoseconds since the last latency update was recorded (at the time of the snapshot).

Returns:
The number of nanoseconds since the last latency update was recorded (at the time of the snapshot).

getLatencyScore

public long getLatencyScore()
The latency score for the host this is the stats of at the time of the snapshot.

Returns:
the latency score for the host this is the stats of at the time of the snapshot, or -1L if not enough measurements have been taken to assign a score.

getMeasurementsCount

public long getMeasurementsCount()
The number of recorded latency measurements for the host this is the stats of.

Returns:
the number of recorded latency measurements for the host this is the stats of.


Copyright © 2014. All rights reserved.