Skip to content
Latchkey

Deadlock (Database) - CI/CD Glossary Definition

A deadlock is when transactions each hold a lock the other needs, so the database aborts one to break the cycle.

A deadlock occurs when two or more transactions each hold a lock the other needs, so none can proceed; the database detects it and aborts one transaction.

Deadlocks are a classic source of flaky CI failures; running migrations while application traffic holds locks makes them more likely.

Related guides

Run this faster and cheaper on Latchkey managed runners. Start free →