Re: [w3ctag/design-reviews] Async local storage (#278)

For posterity:

> This API piggy-backs on IndexedDB. It uses a particular string name to register itself: we think it would be a good idea to reserve some kind of prefix/namespace to avoid author code stomping on potential future Layered APIs. It's not something that can be enforced by the API obviously, but we think coming up with something and making that an author note would be helpful and not hurtful. (There may also be optimizations possible in implementation if a known prefix is used, or so I'm told.)

I think this is done in the spec; the `kv-storage:` prefix is reserved.

When the spec graduates from incubation and is incorporated into the IndexedDB spec itself, we could add a note to the relevant IDB methods discouraging web developers from using the `kv-storage:` prefix directly. (Unless they are intentionally trying to build on top of KV-storage-created databases, as in [this spec example](https://wicg.github.io/kv-storage/#storagearea-backingstore).)

> Getting the list of keys, values, etc., could impact memory footprint in the case of many keys/values. For the future, it would be nice to extend the API to support async iterators (when they become available).

This was addressed in the spec; we now use async iterators for keys/values/entries.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3ctag/design-reviews/issues/278#issuecomment-511490173

Received on Monday, 15 July 2019 17:15:58 UTC