This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 10357 - [IndexedDB] Remove the SNAPSHOT_READ transaction mode
Summary: [IndexedDB] Remove the SNAPSHOT_READ transaction mode
Alias: None
Product: WebAppsWG
Classification: Unclassified
Component: Indexed Database API (show other bugs)
Version: unspecified
Hardware: All All
: P1 normal
Target Milestone: ---
Assignee: Eliot Graff
QA Contact: public-webapps-bugzilla
Depends on:
Reported: 2010-08-12 23:51 UTC by Pablo Castro
Modified: 2010-09-30 21:03 UTC (History)
3 users (show)

See Also:

Detailed changes made for this bug (486.12 KB, application/
2010-09-30 21:02 UTC, Eliot Graff

Description Pablo Castro 2010-08-12 23:51:26 UTC
We currently have two read-only transaction modes, READ_ONLY and SNAPSHOT_READ, that are identical in every aspect (point-in-time consistency for readers, allow multiple concurrent readers, etc.), except that they have different concurrency characteristics, with READ_ONLY blocking writers and SNAPSHOT_READ allowing concurrent writers come and go while readers are active. 

We agreed (see [1]) that we could remove the concept and only have READ_ONLY, leaving it up to the implementation whether writers block readers or readers are allowed and some mechanism is used to maintain point-in-time consistency semantics.

Comment 1 Pablo Castro 2010-09-29 06:17:58 UTC
I wanted to add the actual proposed text changes for this. 

Section 3.1.8:

Remove "3. SNAPSHOT_READ" and make VERSION_CHANGE be 3.

Any number of readers may concurrently access all object stores. A writer is not allowed if there is any reader concurrently accessing the object stores, unless the reader is detached, i.e., looking at a snapshot view of the data that does not change once created

Any number of readers may concurrently access all object stores. A writer must behave as if there were no readers concurrently accessing the store, such that writers either cannot access the store while readers are accessing it or their changes are not visible to readers that were active at the time the writer started. 

Section 3.2.8:

Remove the constant in IDBTransaction for SNAPSHOT_READ and shift the remaining value (VERSION_CHANGE) appropriately (to 3).
Remove the description lines for SNAPSHOT_READ.

Section 3.3.3:

Remove the constant in IDBObjectStoreSync for SNAPSHOT_READ.
Remove the description lines for SNAPSHOT_READ.

Side node: why do we have these constants in the sync store?

For the entire document, change all occurrences of "READ_ONLY or SNAPSHOT_READ" to "READ_ONLY".
Comment 2 Eliot Graff 2010-09-29 18:08:58 UTC
Assigning to me. I'll make these edits.
Comment 3 Eliot Graff 2010-09-30 21:02:48 UTC
Created attachment 920 [details]
Detailed changes made for this bug

Section numbers, prior content, and new content listed for all changes made as a result of this edit.
Comment 4 Eliot Graff 2010-09-30 21:03:28 UTC
Changes made. Changes are described in detail in the attachment.