Class UpdateGraphJobScheduler

java.lang.Object
io.deephaven.engine.table.impl.util.UpdateGraphJobScheduler
All Implemented Interfaces:
JobScheduler

public class UpdateGraphJobScheduler extends Object implements JobScheduler
  • Constructor Details

    • UpdateGraphJobScheduler

      public UpdateGraphJobScheduler(@NotNull @NotNull UpdateGraph updateGraph)
    • UpdateGraphJobScheduler

      public UpdateGraphJobScheduler()
  • Method Details

    • submit

      public void submit(ExecutionContext executionContext, Runnable runnable, LogOutputAppendable description, Consumer<Exception> onError)
      Description copied from interface: JobScheduler
      Cause runnable to be executed.
      Specified by:
      submit in interface JobScheduler
      Parameters:
      executionContext - the execution context to run it under
      runnable - the runnable to execute
      description - a description for logging
      onError - a routine to call if an exception occurs while running runnable
    • getAccumulatedPerformance

      public BasePerformanceEntry getAccumulatedPerformance()
      Description copied from interface: JobScheduler
      The performance statistics of all runnables that have been completed off-thread, or null if all were executed in the current thread.

      When initializing an operation, the OperationInitializerJobScheduler executes the completion callback as part of another task. Therefore, you must not read the accumulated performance from the completion callback when initializing an operation; as it could miss data from some of the tasks. Furthermore, even though the completion callback identifies the result as ready does not mean that the completion callback has actually completed. To guard against this the OperationInitializerJobScheduler waits for all jobs to be complete before returning the BasePerformanceEntry. Therefore, if you call this from a completion callback, then the operation will hang.

      Specified by:
      getAccumulatedPerformance in interface JobScheduler
    • threadCount

      public int threadCount()
      Description copied from interface: JobScheduler
      How many threads exist in the job scheduler? The job submitters can use this value to determine how many sub-jobs to split work into.
      Specified by:
      threadCount in interface JobScheduler