W3C home > Mailing lists > Public > public-webapps@w3.org > April to June 2012

Non-persistent in-memory storage accessible by same domain tabs

From: Joran Greef <joran@ronomon.com>
Date: Thu, 24 May 2012 15:42:23 +0200
Message-ID: <CAMz1zmP90PcLWmtQ9xeUSdc2oJ154s7T__F01+SXrKK-Z1E3bQ@mail.gmail.com>
To: public-webapps@w3.org
Web applications need a way to communicate between two same domain
tabs without polling LocalStorage and without hitting the disk.

It would be useful to have an in-memory get/set/compare_and_set hash
table exposed to scripts running same domain tabs, that is discarded
by the browser when those tabs are closed.

Use cases:

1. Coordinate replication between tabs for an offline app, i.e. one
tab takes responsibility for syncing a user's data to and from
2. Sign out from one tab triggers sign out from all other tabs.
3. If something like LevelDB were exposed directly to JS, one could
implement MVCC on top using the shared hash.
4. Library authors would be able to implement their own cross-tab postMessage.

It's difficult to implement these use cases with LocalStorage, without
a coarse resolution, and risky at that, due to the lack of compare and
set primitive in LocalStorage.
Received on Thursday, 24 May 2012 13:42:55 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 18:13:34 UTC