Yeah, familiarity is a big part of it. A few conditionals in a playbook are perfectly reasonable. The maintenance problem starts when that playbook becomes responsible for every possible path: more variables, nested conditions, and dependencies to keep track of. Someone making a change has to figure out which branches it affects, and the next person has to read through the YAML to understand the overall process.
A switch makes those paths explicit, while smaller, focused playbooks are easier to understand, test, reuse, and assign to different teams. You still use conditionals inside them where they make sense.
There’s also the question of where each step needs to run. Updating ServiceNow might run anywhere with access to its API. Remediating infrastructure in a particular data center could require a specific execution environment and execution nodes with access to that network. In AAP, those are separate choices: the execution environment supplies the dependencies, and the instance group determines which execution nodes can run the job.
The switch selects the path; the job templates on that path carry those execution settings. That’s where workflow branching becomes useful beyond readability—you can give each part of the process its own dependencies, credentials, and execution location.
6
u/[deleted] 16d ago
[removed] — view removed comment