Interface BarrageSnapshotPerformanceSink

All Known Implementing Classes:
BarrageSnapshotPerformanceSink.Noop

public interface BarrageSnapshotPerformanceSink
Receives barrage snapshot performance statistics so that an integrator may record them, for example into binary logs. Deephaven Community Core only publishes these statistics to the in-memory table exposed by BarragePerformanceLog.getSnapshotTable(); install a BarrageTableLoggers.Factory to additionally record them elsewhere.

One entry is logged per snapshot request, such as an Arrow Flight DoGet, at the time that request finishes writing.

All durations are nanoseconds and bytesWritten is a count of bytes, matching UpdatePerformanceLog and the rest of the engine's performance streams. The in-memory table publishes these same values unscaled, so it and this sink report identical numbers.

ImplNote:
implementations need not be thread safe; all calls to a given instance are serialized.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static enum 
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static String
     
    void
    log(String tableId, String tableKey, long requestTimeEpochNanos, long queueNanos, long snapshotNanos, long writeNanos, long bytesWritten)
    Record the cost of serving a single snapshot request.
  • Method Details

    • getDefaultTableName

      static String getDefaultTableName()
      Returns:
      the default name of the table that these entries describe
    • log

      void log(String tableId, String tableKey, long requestTimeEpochNanos, long queueNanos, long snapshotNanos, long writeNanos, long bytesWritten) throws IOException
      Record the cost of serving a single snapshot request.
      Parameters:
      tableId - the identity of the snapshotted table
      tableKey - the barrage performance key of the snapshotted table
      requestTimeEpochNanos - the time at which the request was received, as nanoseconds since the epoch
      queueNanos - the time the request spent queued before being serviced
      snapshotNanos - the time spent constructing the snapshot
      writeNanos - the time spent writing the snapshot
      bytesWritten - the number of bytes written
      Throws:
      IOException