Class NewOrchestrationInstanceOptions

java.lang.Object
io.dapr.durabletask.NewOrchestrationInstanceOptions

public final class NewOrchestrationInstanceOptions extends Object
Options for starting a new instance of an orchestration.
  • Constructor Details

  • Method Details

    • setVersion

      public NewOrchestrationInstanceOptions setVersion(String version)
      Sets the version of the orchestration to start.
      Parameters:
      version - the user-defined version of the orchestration
      Returns:
      this NewOrchestrationInstanceOptions object
    • setInstanceId

      public NewOrchestrationInstanceOptions setInstanceId(String instanceId)
      Sets the instance ID of the orchestration to start. If no instance ID is configured, the orchestration will be created with a randomly generated instance ID.
      Parameters:
      instanceId - the ID of the new orchestration instance
      Returns:
      this NewOrchestrationInstanceOptions object
    • setInput

      public NewOrchestrationInstanceOptions setInput(Object input)
      Sets the input of the orchestration to start. There are no restrictions on the type of inputs that can be used except that they must be serializable using the DataConverter that was configured for the DurableTaskClient at creation time.
      Parameters:
      input - the input of the new orchestration instance
      Returns:
      this NewOrchestrationInstanceOptions object
    • setStartTime

      public NewOrchestrationInstanceOptions setStartTime(Instant startTime)
      Sets the start time of the new orchestration instance. By default, new orchestration instances start executing immediately. This method can be used to start them at a specific time in the future.
      Parameters:
      startTime - the start time of the new orchestration instance
      Returns:
      this NewOrchestrationInstanceOptions object
    • setAppID

      public NewOrchestrationInstanceOptions setAppID(String appID)
      Sets the target app ID for cross-app workflow routing.
      Parameters:
      appID - the target app ID for cross-app routing
      Returns:
      this NewOrchestrationInstanceOptions object
    • getVersion

      public String getVersion()
      Gets the user-specified version of the new orchestration.
      Returns:
      the user-specified version of the new orchestration.
    • getInstanceId

      public String getInstanceId()
      Gets the instance ID of the new orchestration.
      Returns:
      the instance ID of the new orchestration.
    • getInput

      public Object getInput()
      Gets the input of the new orchestration.
      Returns:
      the input of the new orchestration.
    • getStartTime

      public Instant getStartTime()
      Gets the configured start time of the new orchestration instance.
      Returns:
      the configured start time of the new orchestration instance.
    • getAppID

      public String getAppID()
      Gets the configured target app ID for cross-app workflow routing.
      Returns:
      the configured target app ID
    • hasAppID

      public boolean hasAppID()
      Checks if an app ID is configured for cross-app routing.
      Returns:
      true if an app ID is configured, false otherwise