Class SubFlowOptions

java.lang.Object
io.superdurable.dex.SubFlowOptions

public final class SubFlowOptions extends Object
Configures one durable SubFlow condition.

The server generates the SubFlow Flow ID and request ID. The SubFlow inherits the parent's effective FlowConfig; SubFlowOptions.Builder.configOverride replaces only fields explicitly present in its argument. Other unset start settings use normal Flow start defaults. The default reuse policy is SubFlowReusePolicy.RESTART_IF_PREVIOUS_EXITS_ABNORMALLY.

SubFlowOptions options = SubFlowOptions.newBuilder()
        .timeout(Duration.ofMinutes(20))
        .reusePolicy(SubFlowReusePolicy.ATTACH)
        .conditionId("inventory")
        .build();
return Wait.until(SubFlow.run(InventoryFlow.class, input, options));
  • Method Details

    • newBuilder

      public static SubFlowOptions.Builder newBuilder()
      Returns a builder initialized with SubFlow defaults.
      Returns:
      a new mutable builder