Home / Companies / Orkes / Blog / Post Details
Content Deep Dive

How to Add Conditional Branching to Your Workflows in Orkes Conductor

Blog post from Orkes

Post Details
Company
Date Published
Author
Maria Shimkovska
Word Count
1,702
Company Posts That Month
6
Language
English
Hacker News Points
-
Summary

The Orkes Conductor SWITCH task is designed to streamline workflow branching logic by evaluating a value and routing execution to the appropriate branch based on that evaluation, thereby reducing the need to hard-code decision logic into applications. This task is particularly useful in scenarios requiring non-linear workflows, such as directing file uploads to the correct processing service, sending notifications through preferred user channels, or handling different sign-up methods based on user registration paths. By integrating the SWITCH task into workflows, developers can simplify their codebases, as the branching decisions are managed within the workflow itself. The SWITCH task does not return data directly but provides the selectedCase to indicate which branch was executed, ensuring seamless continuation of workflows even if no branch matches, by proceeding to the next task. The text also includes a practical example of a workflow using the SWITCH task to route actions based on weather conditions, demonstrating how easily the task can be implemented and executed in Orkes Conductor.

Trends Found in this Post

No tracked trend matches for this post yet.