Class Latency

java.lang.Object
org.nuxeo.lib.stream.log.Latency

public class Latency extends Object
Extends LogLag with lower and upper timestamps to express lag as a latency.
Since:
10.1
  • Field Details

    • lag

      protected final LogLag lag
    • lower

      protected final long lower
    • upper

      protected final long upper
    • key

      protected final String key
  • Constructor Details

    • Latency

      public Latency(long lower, long upper, LogLag lag, String key)
  • Method Details

    • noLatency

      public static Latency noLatency(long upper, LogLag lag)
    • fromJson

      public static Latency fromJson(String json)
    • of

      public static Latency of(List<Latency> latencies)
    • latency

      public long latency()
      Returns the latency expressed in millisecond.
    • lower

      public long lower()
      Returns the lower timestamp.
    • upper

      public long upper()
      Returns the upper timestamp.
    • lag

      public LogLag lag()
    • key

      public String key()
      Returns the key associated with the lower timestamp.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • asJson

      public String asJson()