Switch to skv instead of rkv for kvstore usage in the extensions framework
Categories
(WebExtensions :: General, task, P3)
Tracking
(Not tracked)
People
(Reporter: robwu, Unassigned)
References
(Depends on 3 open bugs, Blocks 1 open bug)
Details
skv is the successor of rkv (bug 1909407) as the backend for the kvstore API.
We currently have 4 possible rkv databases in extension code:
ProfD/extension-store-menus/menus(source)ProfD/extension-store/scripting-contentScripts(source)ProfD/extension-store-permissions/permissions(source) (Nightly-only, bug 1646182)ProfD/extension-store/permissions(old before bug 1807010) (source) (Nightly-only, bug 1646182)
Although the documentation states that the directory can be reused by databases, this turned out to be not possible because of race conditions (bug 1807010). According to Lina, the issue is no longer present in skv, and it is possible and even encouraged to use the same directory where possible.
Since we have some freedom in choosing the database location for the new skv files, we may as well choose one single location, e.g. extension-store/ and delete the old rkv files and directories upon migration. Transparent data migration is possible through the migrator added in bug 1913826.
| Reporter | ||
Comment 1•1 year ago
|
||
For feature parity, skv corruption handling should be implemented before we migrate (bug 1913238).
Note that I am already starting to use skv as the storage backend of the userScripts API (bug 1911833).
| Reporter | ||
Comment 2•1 year ago
|
||
As part of migrating to skv, we can also use the more efficient deleteRange method instead of the current practice of querying all keys before deletion. This is implemented for skv only at bug 1919674. This is a nice-to-have.
Updated•1 year ago
|
Updated•1 year ago
|
Description
•