MongrelDB::Transaction
Transaction stages operations locally and commits them atomically in a
single /kit/txn request. The engine enforces unique, foreign-key,
check, and trigger constraints at commit time; on any violation all
operations roll back and #commit raises a ConflictError.
A Transaction is single-use -- call #commit or #rollback once, then
create a new one with Client#begin_transaction.
Constructors
new(client : Client)
Initialize a new Transaction. Normally created via
Client#begin_transaction.
Instance methods
Commit all staged operations atomically.
idempotency_key- optional idempotency key for safe retries -- the daemon returns the original response on duplicate commits, even after a crash.
Stage a delete by primary-key value.
Stage a put (insert) operation.