Package com.uber.cadence.workflow
Annotation Type WorkflowMethod
-
@Retention(RUNTIME) @Target(METHOD) public @interface WorkflowMethod
Indicates that the method is a workflow method. Workflow method is executed when workflow is started. Workflow completes when workflow method returns. This annotation applies only to workflow interface methods.
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description int
executionStartToCloseTimeoutSeconds
Maximum workflow execution time.java.lang.String
name
Name of the workflow type.java.lang.String
taskList
Task list to use when delivering workflow tasks.int
taskStartToCloseTimeoutSeconds
Maximum execution time of a single workflow task.java.lang.String
workflowId
Workflow ID to use.WorkflowIdReusePolicy
workflowIdReusePolicy
How to react if there is completed workflow with the same ID.
-
-
-
-
workflowId
java.lang.String workflowId
Workflow ID to use. Default is random UUID. Specifying workflow in the annotation makes sense only for singleton workflows that would ever have one instance per type running. Make sure thatWorkflowIdReusePolicy
is AllowDuplicate in this case.- Default:
- ""
-
-
-
workflowIdReusePolicy
WorkflowIdReusePolicy workflowIdReusePolicy
How to react if there is completed workflow with the same ID.-
AllowDuplicate - Always start a new run
-
RejectDuplicate - Never allow a second run
-
AllowDuplicateFailedOnly - Allow only if workflow didn't complete successfully.
- Default:
- com.uber.cadence.WorkflowIdReusePolicy.AllowDuplicateFailedOnly
-
-
-
executionStartToCloseTimeoutSeconds
int executionStartToCloseTimeoutSeconds
Maximum workflow execution time. Must be specified either throughexecutionStartToCloseTimeoutSeconds()
orWorkflowOptions.getExecutionStartToCloseTimeout()
.- Default:
- 0
-
-