Class OperationInitializerJobScheduler

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

public class OperationInitializerJobScheduler extends ExecutorJobScheduler
An ExecutorJobScheduler over an OperationInitializer, whose pool is shared and has a fixed number of threads, and whose parallelism is the scheduler's thread count.

Each job runs once, on whichever thread claims it first: a pool thread, or a thread waiting in ExecutorJobScheduler.awaitCompletion(java.util.concurrent.CompletableFuture<T>), which runs the jobs no pool thread has started rather than waiting for one to. A waiting thread therefore blocks only while every job it has not finished is running on another thread, and never on a job queued behind pool threads that may themselves be waiting, perhaps for a lock the waiting thread holds. An initializer that runs a job inside submit, as OperationInitializer.NON_PARALLELIZABLE does, makes it the submitting thread's own work.

  • Constructor Details

    • OperationInitializerJobScheduler

      public OperationInitializerJobScheduler(@NotNull @NotNull OperationInitializer operationInitializer)
    • OperationInitializerJobScheduler

      public OperationInitializerJobScheduler()