Race condition
A race condition is a situation where a system's result depends on the order in which multiple processes run concurrently, or on events that do not occur at the expected time.
On this page
Source content checked . English translation published 2026-10-27.
In business automation
Two processes running on the same customer record can overwrite each other if there is no agreed order. A race condition is a situation where the result depends on the order of concurrent execution or on an event that does not arrive when expected. In this guide, the term appears alongside concurrency and idempotency.
Examples
These examples illustrate a possible workflow. Adapt the connections and rules to your own systems.
A payment and cancellation arriving almost simultaneously
A payment webhook and a cancellation webhook arrive almost simultaneously. Without a lock or a check of the latest status, the process may mark an order as paid after it has been canceled. Store an event ID and check the current state before updating.
Relevant tools
- n8n
- Two processes can run at the same time on the same record. A race condition is a property of scheduling, not of the tool. Plan a status check or lock before writing.
What to check
- Assuming events arrive in the order they were sent does not hold when there is a retry or network delay.