This site is in read only mode. Please continue to browse, but replying, likes, and other actions are disabled for now.

⚠️ We've moved!

Hi there!

To reduce project dependency on 3rd party paid services the StackStorm TSC has decided to move the Q/A from this forum to Github Discussions. This will make user experience better integrated with the native Github flow, as well as the questions closer to the community where they can provide answers.

Use 🔗 Github Discussions to ask your questions.

How should "if elif else" be implemented in Orquesta

Hello,
I want to write a workflow to collect alarm information and then treat them differently.
I can use when Conditionals to implement if elif:

-  when: <% succeeded() and result().result.alert_type = 'something 1' %>
    do: something 1
- when :<% succeeded() and result().result.alert_type = 'something 2' %>
    do: something 2

But how do I implement else logic?

maybe YAQL grammar can sovle this:

  • when: <% succeeded() and not result().result.alert_type in (‘something 1’,‘something2’) %>

Yep, that’s exactly how. :slight_smile:

1 Like