Closed
Bug 595925
Opened 14 years ago
Closed 14 years ago
Use OpenUnsharedDatabase in cookies (should fix intermittent test_cookies_read.js | command timed out: 300 seconds without output)
Categories
(Core :: Networking: Cookies, defect)
Tracking
()
RESOLVED
FIXED
Tracking | Status | |
---|---|---|
blocking2.0 | --- | final+ |
People
(Reporter: dwitte, Assigned: dwitte)
References
()
Details
(Keywords: intermittent-failure, perf)
Attachments
(1 file)
(deleted),
patch
|
sdwilsh
:
review+
|
Details | Diff | Splinter Review |
OpenDatabase shares a cache, which apparently will cause contention between the sync read and the async read/write threads.
http://mxr.mozilla.org/mozilla-central/source/netwerk/cookie/nsCookieService.cpp#735
We should also update the interface doc (http://mxr.mozilla.org/mozilla-central/source/storage/public/mozIStorageService.idl#109) to state that using an unshared connection is a good idea when cache contention is expected.
(Side note: should we be using mozIStorageConnection::connectionReady before using the database?)
Comment 1•14 years ago
|
||
(In reply to comment #0)
> (Side note: should we be using mozIStorageConnection::connectionReady before
> using the database?)
No, the IDL appears to be wrong :(
Assignee | ||
Comment 2•14 years ago
|
||
Not sure if http://mxr.mozilla.org/mozilla-central/source/storage/public/mozIStorageService.idl#73 should also be removed (or rephrased, in both cases).
Comment 3•14 years ago
|
||
Comment on attachment 474751 [details] [diff] [review]
patch
r+a=sdwilsh
Attachment #474751 -
Flags: review?(sdwilsh)
Attachment #474751 -
Flags: review+
Attachment #474751 -
Flags: approval2.0+
Comment 4•14 years ago
|
||
Comment on attachment 474751 [details] [diff] [review]
patch
Actually, we need to get rid of exclusive locking too, which I thought we already did, but apparently did not do. r=sdwilsh with that change.
Attachment #474751 -
Flags: approval2.0+
Assignee | ||
Comment 6•14 years ago
|
||
This gives us a perf improvement from 16.6ms per async operation (!) to 284us per operation. Landing this will resolve the shutdown hangs some people have been seeing. We need this so bad.
Keywords: perf
Updated•14 years ago
|
blocking2.0: --- → final+
Assignee | ||
Comment 9•14 years ago
|
||
We need WAL for this, or we're going to run into sync connections failing to open because of writes occurring in the background. The alternative is to add sleep() calls to the sync connection code, which is really not cool.
Depends on: 598196
Updated•14 years ago
|
Blocks: 438871
Summary: Use OpenUnsharedDatabase in cookies → Use OpenUnsharedDatabase in cookies (should fix intermittent test_cookies_read.js | command timed out: 300 seconds without output)
Whiteboard: [orange]
Updated•14 years ago
|
Comment 10•14 years ago
|
||
Possible that this is causing cookie failure when restarting the browser and you find that your logged out of forums?
Assignee | ||
Comment 11•14 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Could this have caused bug 605835?
Updated•12 years ago
|
Keywords: intermittent-failure
Updated•12 years ago
|
Whiteboard: [orange]
You need to log in
before you can comment on or make changes to this bug.
Description
•