Execute other workflows in parallel

Run a workflow that executes other workflows in parallel.

Explore further

For detailed documentation that includes this code sample, see the following:

Code sample

YAML

main:
  params: [args]
  steps:
    - init:
        assign:
          - iteration : ${args.iteration}
    - wait:
        call: sys.sleep
        args:
            seconds: 10
    - check_iteration_even_or_odd:
        switch:
          - condition: ${iteration % 2 == 0}
            next: raise_error
    - return_message:
        return: ${"Hello world"+iteration}
    - raise_error:
        raise: ${"Error with iteration "+iteration}

What's next

To search and filter code samples for other Google Cloud products, see the Google Cloud sample browser.