Database transaction
A database transaction groups related changes so they are committed together or rolled back together.
A database transaction combines several steps into one unit. If the changes are committed, the database applies them together; if the transaction is aborted, they are discarded together. An error therefore does not leave only part of the intended change in place.
Change the assignment and its history together
In a fictional device management application, device-4 moves from project P-1 to P-2. The new assignment and a change history entry reside in the same database and must be saved together. The application starts a transaction with BEGIN. If both steps succeed, it confirms them with COMMIT; if a step fails, it discards this transaction’s changes with ROLLBACK.
What concurrent transactions can see and which conflicts can occur also depend on isolation and the accesses performed. Business rules still need to be implemented; the transaction boundary alone cannot prevent every incorrect assignment.
This local rollback cannot recall an email already sent. Coordination with other systems requires a separate solution. A Transactional Inbox specifically uses a shared database transaction to combine message processing with recording its deduplication identifier.
Sources
Related terms
- Transactional inboxA transactional inbox uses durable message records to protect local processing against duplicate deliveries.
- Message acknowledgementA message acknowledgement tells the broker that a delivery has been received or processed according to the agreed rule.
- Retry jitterRetry jitter varies waiting times randomly to spread retries and reduce simultaneous requests from many clients.
- Test tenantA logically bounded customer context of a multitenant application, configured for testing.
- Webhook replayWebhook replay means sending a webhook notification again. Deliberate recovery and replay attacks require different checks.
- Idempotency keyAn idempotency key identifies retries of the same intended request. Scope, retention and API rules determine its effect.
Articles on this topic








APIs & Integration with ASES
ERP, CRM and shop cleanly connected

