RESOLVED FIXED 205413
IndexedDB: delete index records with ID and IndexKey instead of value in SQLiteIDBackingStore
https://bugs.webkit.org/show_bug.cgi?id=205413
Summary IndexedDB: delete index records with ID and IndexKey instead of value in SQLi...
Sihui Liu
Reported 2019-12-18 14:19:04 PST
...
Attachments
Patch (3.38 KB, patch)
2019-12-18 15:27 PST, Sihui Liu
no flags
Patch (8.04 KB, patch)
2019-12-19 15:19 PST, Sihui Liu
no flags
Patch (8.13 KB, patch)
2019-12-20 14:47 PST, Sihui Liu
no flags
Sihui Liu
Comment 1 2019-12-18 15:27:59 PST
Geoffrey Garen
Comment 2 2019-12-19 13:23:37 PST
Comment on attachment 386020 [details] Patch r=me It sounds like we can do even better if we delete by key -- but this patch is an improvement too.
Sihui Liu
Comment 3 2019-12-19 15:19:17 PST
Alex Christensen
Comment 4 2019-12-20 14:08:02 PST
Comment on attachment 386153 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=386153&action=review > Source/WebCore/Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:1546 > + sql->getColumnBlobAsVector(1, valueBuffer); Could you make getColumnBlobAsVector return a Vector<uint8_t> and make a getColumnBlobAsCharVector that returns a Vector<char>? > Source/WebCore/Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:1601 > + indexKeys.append(indexKey.asOneKey()); Could you write this so that if there's one key, we don't need to allocate a Vector? That would probably just move the isValid() check into deleteOneIndexRecord
Sihui Liu
Comment 5 2019-12-20 14:30:50 PST
Comment on attachment 386153 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=386153&action=review >> Source/WebCore/Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:1546 >> + sql->getColumnBlobAsVector(1, valueBuffer); > > Could you make getColumnBlobAsVector return a Vector<uint8_t> and make a getColumnBlobAsCharVector that returns a Vector<char>? Yes. I could make that change but prefer doing it in a different bug as it's not relevant to what the patch is for. >> Source/WebCore/Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:1601 >> + indexKeys.append(indexKey.asOneKey()); > > Could you write this so that if there's one key, we don't need to allocate a Vector? That would probably just move the isValid() check into deleteOneIndexRecord Sure.
Sihui Liu
Comment 6 2019-12-20 14:47:43 PST
WebKit Commit Bot
Comment 7 2020-01-03 23:28:41 PST
Comment on attachment 386261 [details] Patch Clearing flags on attachment: 386261 Committed r254030: <https://trac.webkit.org/changeset/254030>
WebKit Commit Bot
Comment 8 2020-01-03 23:28:42 PST
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 9 2020-01-03 23:29:21 PST
Note You need to log in before you can comment on or make changes to this bug.