You can invoke multiple interviews for an autolaunched flow simultaneously by:
- Uploading bulk records that start a process, which then executes a flow action
- Passing multiple input maps in the request for the Invocable Actions resource in the REST API
Because the interviews run in one transaction, your process or API call could hit limits that it wasn’t reaching before, such as Maximum number of duplicated updates in one batch. If more than 12 duplicate updates are tried, the entire transaction is rolled back. If your implementation hits a limit, the flow error email includes error messages for that limit.
Let’s say you have a process that starts when a case is created or edited. That process always invokes an autolaunched flow that updates the associated account’s description. You upload 20 new cases, which are all associated with the Acme Wireless account.
Previously, Salesforce started only one interview of the autolaunched flow. The description for Acme Wireless is updated once, and no errors occured.
With this critical update, an interview of the autolaunched flow for each case is started. Each interview updates the same Acme Wireless record, and a given transaction can execute duplicate updates 12 times. So the transaction fails in the 13th interview and rolls back.
Test This Critical Update
We recommend testing the critical update in a sandbox. If you must work in your production org, do so during off-peak hours.
- Identify all processes that include a flow action and all integrations that call an autolaunched flow through the Invocable Actions resource in the REST API.
- Review all the implementations for potential impact. If your implementation is optimized for one interview being executed per batch of records, revisit your implementation design.
- Update your implementations so that they don’t hit Salesforce limits. For example, if a flow is called from a process, make sure that it doesn’t update the same record as other interviews in the batch.
- From Setup, enter Critical Updates in the Quick Find box, and then select Critical Updates.
- For Execute All Autolaunched Flow Interviews When Invoked in Bulk, click Activate. Then test your implementations to make sure that they’re working as you expect.