Bug 104310

Summary: IndexedDB: put() should index asynchronously
Product: WebKit Reporter: Alec Flett <alecflett>
Component: WebCore Misc.Assignee: Nobody <webkit-unassigned>
Status: RESOLVED CONFIGURATION CHANGED    
Severity: Normal CC: beidson, bfulgham, jsbell, sihui_liu
Priority: P3    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   

Description Alec Flett 2012-12-06 15:40:58 PST
As reported on chromium-html5@ - calling put() with lots of indexes can be a serious performance drag, probably partially because the frontend put() has to resolve all the values and send a giant blob of index data to the backend  - the value resolution happens synchronously, before the backend even sees it.

What we should probably be doing is sending the indexing data to the backend, and generating some kind of separate event in the frontend to generate the index data & send it to the backend using setIndexKeys()

This is kind of how createIndex() works, and it would probably have to have the same kind of semantics...
Comment 1 Sihui Liu 2022-02-01 14:06:20 PST
Not sure I completely understand the description since the bug is very old; but the index records are generated in the backend now, so calling put() should not block the web content process.