troubleshooting Frontend & browsers
IndexedDB transaction lifetime and quota failures
Trace a missing IndexedDB edit from transaction activity to the write result and the final commit or abort. A quota error is not the same as an inactive transaction, and a commit is not a promise of permanent storage.
What it means
An open IndexedDB connection does not mean an earlier transaction can still accept writes. The transaction must be active when you submit the request. If it accepts the request, the write can still fail because of quota. And if the request succeeds, you still need to know whether the transaction committed or aborted before you call the change saved.
Try it
Simulation. Start with Transaction phase set to inactive and Required scenario evidence set to provided. The result is inactive: the transaction cannot accept a new request. Although Storage write outcome says room and Error handling says abort, neither setting was used. No write reached the point where space or error handling mattered.
IndexedDB transaction lifetime and quota failures
Explain transaction abort versus persistent storage and quota behavior
New request not allowed in inactive or finished transaction.
Request conditions
- Transaction phaseinactive
- Quota evidenceNot evaluated / established
- Error handlingNot evaluated / established
Result
- Request queuedNo
- Outcomeinactive
- Commit/durabilityNot established
Queued does not mean committed or durable. The quota input is a categorical premise, not a measured number of free bytes.
Evaluated inputs
- Required scenario evidence
- provided
- Transaction phase
- inactive
Not evaluated: Storage write outcome · Error handling
Symbolic active/inactive/finished states and stipulated error handling, not browser quota measurement or actual storage; no storage side effects.
About this model
The controls set only a local, bounded scenario. The computed branch is not a verdict about a live system. Inputs listed as not evaluated did not participate in this branch after validation.
Reset restores the original inputs. It does not change the open or closed state of help or FAQ answers.
- Change only Transaction phase to
active. The result changes toqueued: with room stipulated, the request is eligible. This is not a report that the write succeeded or the transaction committed. - Keep the phase active and change Storage write outcome to
quota-error. Now theabortsetting matters: the write fails and the modeled transaction aborts. - Change only Error handling to
handled. The result ishandled-error. Handling the request error changes the abort behavior, not the failed write. The model does not say that the transaction subsequently committed.
With an active transaction, choose unknown for the write outcome to see what you can conclude without a storage result: the phase allowed a request, but there is no basis for saying the write succeeded or failed. Setting Required scenario evidence to missing stops the evaluation even earlier, before the phase is considered. Reset restores the original inactive example. None of these choices reads or changes browser storage.
A request has a result; a transaction has an outcome
Suppose a note editor opens a transaction, then waits for an unrelated asynchronous operation before submitting a write. The connection may still be open when the editor resumes, but the transaction might no longer be active. What matters is its phase when the editor tries to add the request, not its phase when the editor started waiting. If the request was refused at that point, free space would not have helped.
Now suppose the editor submits two writes in one active transaction: one for the note text and one for its entry in a list. The text request succeeds; the list request encounters a quota error. If that error causes the transaction to abort, neither change is committed. That is transaction atomicity: an abort undoes the transaction's changes together, including the change whose request reported success.
If the request error's default abort action is prevented, the list write still failed. Even if the transaction later completes, completion does not turn that failed request into a successful one. To decide whether the editor saved the pair, you need the result of each required write as well as the outcome of their transaction.
Two false request results can represent different stages. An inactive transaction refuses a new request before the quota premise is evaluated. An active transaction with a stipulated quota error reaches the request-error path; if its default abort is prevented, the failed request still has not succeeded. An eventual commit or durable write remains a separate observation, especially when an error happens during commit itself.
In practice
If an edit appears not to have been saved, start with the earliest point for which you lack evidence:
- Was a request accepted? Check whether the attempt produced a request or was refused because the transaction was no longer active. If it was refused after an asynchronous wait, inspect where the editor started the transaction relative to that wait. Do not diagnose a quota failure from this symptom.
- What happened to the request? If it was accepted, look for its success or its specific error. A later transaction abort, by itself, does not identify quota as the cause. Handling an error is not evidence that the edit was retried or saved.
- How did that same transaction end? Look for its
completeorabortevent. If your observations stop at request success, leave the commit outcome unknown. Do not clear stored data or change permissions to test a guess.
Commit, durability, and retention answer different questions. Commit concerns whether the transaction's changes took effect together. Durability concerns how securely those changes were written to storage. Retention concerns whether the browser keeps the stored data later: the Storage Standard distinguishes best-effort storage from persistent storage under pressure. A commit does not grant persistent storage or reserve unlimited space for the next edit.
The simulation does not measure quota, disk durability, or eviction in any browser version. For a missing edit, match the evidence to the claim: request success describes one operation; transaction completion establishes commit; neither promises that the edit will remain available indefinitely.
Frequently asked questions
Editorial questions based on the listed sources and explicitly labeled local examples.
Can a transaction become inactive between tasks?
Yes. IndexedDB transaction activity is tied to its lifecycle and tasks handling requests. Do not assume an unrelated asynchronous continuation can always enqueue another request.
Does request success prove transaction commit?
No. One request may succeed and the enclosing transaction may later abort. Distinguish request success from the transaction’s terminal completion evidence.
Does handling an error make failed write succeed?
No. Handling a request error may affect transaction abort behavior, but it does not make the failed request successful. Inspect the subsequent transaction outcome.
Is quota fixed across browsers?
No. The Storage Standard leaves quota decisions to the user agent and distinguishes best-effort from persistent storage under pressure. The lab takes a categorical room, error or unknown premise; it neither calculates a numeric capacity nor predicts eviction.
Sources & model boundaries
Primary references used for this explanation. The interactive example is an educational model, not a live check.
- Indexed Database API 3.0
§2.7.1, §5.4–5.5, §5.10. Transaction activity constrains new requests. A request error can trigger abort; abort rolls back transaction changes. Request success and a transaction completion event are separate observations.
Checked .
- Storage Standard
Sections 6 and 7.1 (quota and storage pressure). The Storage Standard leaves quota decisions to user agents and distinguishes best-effort and persistent storage under pressure.
Checked .