Class EventDrivenUpdateGraph.Builder

java.lang.Object
io.deephaven.engine.updategraph.impl.EventDrivenUpdateGraph.Builder
Enclosing class:
EventDrivenUpdateGraph

public static class EventDrivenUpdateGraph.Builder extends Object
Builds or retrieves a new EventDrivenUpdateGraph.
  • Constructor Details

    • Builder

      public Builder(String name)
  • Method Details

    • minimumCycleDurationToLogNanos

      public EventDrivenUpdateGraph.Builder minimumCycleDurationToLogNanos(long minimumCycleDurationToLogNanos)
      Set the minimum duration of an update cycle that should be logged at the INFO level.
      Parameters:
      minimumCycleDurationToLogNanos - threshold to log a slow cycle
      Returns:
      this builder
    • build

      public EventDrivenUpdateGraph build()
      Constructs and returns an EventDrivenUpdateGraph. It is an error to do so if an UpdateGraph already exists with the name provided to this builder.
      Returns:
      the new EventDrivenUpdateGraph
      Throws:
      IllegalStateException - if an UpdateGraph with the provided name already exists
    • existingOrBuild

      public EventDrivenUpdateGraph existingOrBuild()
      Returns an existing EventDrivenUpdateGraph with the name provided to this Builder, if one exists, else returns a new EventDrivenUpdateGraph.

      If the options for the existing graph are different than the options specified in this Builder, this Builder's options are ignored.

      Returns:
      the EventDrivenUpdateGraph
      Throws:
      ClassCastException - if the existing graph is not an EventDrivenUpdateGraph