Email Notifications Not being Fired (no Events[sysevent] or Emails[sys_email] generated) due to setWorkflow(false) or setUseEngines(false)


It's sometimes been seen that custom Business Rules (BRs) deployed on customer instances use one or both of these GlideRecord functions to supress Workflows or other internal 'engines' from running during an update or insert operation:



A call to setWorkflow(false) or setUseEngines(false) (both part of the GlideRecord API) will completely disable not just Workflows but the whole Notification Engine as well as Auditing, and so stop any Notifications (email or SMS) from being generated.

Release or Environment

All ServiceNow versions


Disabling the Notification Engine with either of these functions prevents Notification emails from being generated.


If the customer has a BR that uses setWorkflow(false) or setUseEngines(false) they can still run it, but it *must* be run as an after BR with an Order of 1001 or greater, see Execution order of scripts and engines.

NOTE: Remember to set back to 'true' after a current.update() in a business rule:  setWorkflow(true), in a line after setWorkflow(false); current.update(), in order for business rules and other engines to run again. 

Additional Information