The CreatorCon Call for Content is officially open! Get started here.

Workflow wait for an external event?

ILYA STEIN
Tera Guru

Hi All,

We are developing an automation via SNOW that triggers an external automation engine to perform an action. When the action is performed depends on a number of conditions and may be days away. The action is triggered in a workflow. What would the best practice be to have the workflow wait for the action to complete? We use timer and turnstile for shorter actions (to perform within 24 hours), but I would prefer to avoid polling and do wait for condition or event instead.

1 ACCEPTED SOLUTION

When you "wait", you keep that workflow hanging, consuming system resources, which can degrade the performance of your instance. This is not the case when you just end the workflow at a certain point, and get another one kicked off when it is needed.

View solution in original post

3 REPLIES 3

Laszlo Balla
ServiceNow Employee
ServiceNow Employee

You should branch off whatever you have after the "wait" condition into a separate flow or workflow or other business logic, with it's own trigger, whereas the trigger could be an inbound REST call (or webhook) for instance from the 3rd party system. So in a nutshell, 2 (or more) workflows instead of doing it in one.

How does having two separate workflows help here as opposed to just having a 'Wait for event" or "Wait for condition", and continuing after the event or condition occur?

When you "wait", you keep that workflow hanging, consuming system resources, which can degrade the performance of your instance. This is not the case when you just end the workflow at a certain point, and get another one kicked off when it is needed.