This topic describes wait steps and related examples.
A wait step pauses a flow execution for a period of time before proceeding. You can select a relative time or use a timestamp to specify an absolute end time.
A wait step contains the following attributes:
- type: Required. The step type. The value wait indicates that the step is a wait step.
- name: Required. The step name.
- duration: Optional. The relative time to wait in seconds. It can be a constant or
a parameter in the input. For example,
10indicates waiting for 10 seconds, and
$.sleepindicates that the wait time is obtained from the input
sleepkey. You must specify either
- timestamp: Optional. The absolute time to wait in RFC3339 format. It can be a constant or a parameter in the input. For example,
2019-05-02T15:04:05Zindicates waiting until 15:04:05 on May 2, 2019 UTC. If the time is earlier than the current time, the wait step ends.
- end: Optional. Specifies whether to proceed with the subsequent steps after the current step ends.
- inputMappings: Optional. The input mappings.
- outputMappings: Optional. The output mappings. A wait step does not generate data,
- Wait time of 20 seconds
version: v1 type: flow steps: - type: wait name: wait20s duration: 20
- Wait time determined by the input
version: v1 type: flow steps: - type: wait name: custom_wait duration: $.wait
- Absolute wait time
version: v1 type: flow steps: - type: wait name: wait20s timestamp: 2019-05-02T15:04:05Z
- Absolute wait time determined by the input
version: v1 type: flow steps: - type: wait name: custom_wait timestamp: $.wait_timestamp