Class UpdatePerformanceTracker

java.lang.Object
io.deephaven.engine.table.impl.perf.UpdatePerformanceTracker

public class UpdatePerformanceTracker extends Object

This tool is meant to track periodic update events that take place in an UpdateGraph. This generally includes:

  1. Update source run() invocations
  2. Table ShiftObliviousListener notifications (see ShiftObliviousInstrumentedListener)
  3. Table TableUpdateListener notifications (see InstrumentedTableUpdateListener)
(1)
ApiNote:
Regarding thread safety, this class interacts with a singleton PeriodicUpdateGraph and expects all calls to getEntry(String), PerformanceEntry.onUpdateStart(), and PerformanceEntry.onUpdateEnd() to be performed while protected by the UGP's lock.
  • Field Details

    • REPORT_INTERVAL_MILLIS

      public static final long REPORT_INTERVAL_MILLIS
  • Constructor Details

    • UpdatePerformanceTracker

      public UpdatePerformanceTracker(UpdateGraph updateGraph)
  • Method Details

    • start

      public void start()
      Start this UpdatePerformanceTracker, by beginning its first interval.
    • flush

      public void flush()
      Flush this UpdatePerformanceTracker to the downstream publisher and logger, and begin its next interval.
    • enableUnitTestMode

      public void enableUnitTestMode()
    • getEntry

      public final PerformanceEntry getEntry(String description)
      Get a new entry to track the performance characteristics of a single recurring update event.
      Parameters:
      description - log entry description
      Returns:
      UpdatePerformanceTracker.Entry
    • getQueryTable

      @NotNull public static @NotNull QueryTable getQueryTable()
    • resetForUnitTests

      @TestUseOnly public static void resetForUnitTests()