Closed
Bug 743635
Opened 13 years ago
Closed 13 years ago
B2G SMS database initialization accesses Directory Provider off the main thread
Categories
(Core :: DOM: Device Interfaces, defect)
Tracking
()
RESOLVED
FIXED
mozilla14
People
(Reporter: philikon, Assigned: philikon)
References
Details
Attachments
(1 file, 1 obsolete file)
(deleted),
patch
|
Details | Diff | Splinter Review |
On Gonk ICS we're seeing an interesting race condition in the emulator: the B2G SMS database service is initialized at startup and immediately initializes an IndexedDB instance. IndexedDB happens to query the Directory Service for ProfD *off the main thread*. This usually works out fine so long as the Directory Service's cache has been primed (e.g. something has already queried for ProfD). In this case, however, we're seeing that the IndexedDB thread is racing the main thread and fails to look up ProfD.
Assignee | ||
Comment 1•13 years ago
|
||
Assignee: nobody → philipp
Attachment #613261 -
Flags: review?(mwu)
Comment 2•13 years ago
|
||
E/GeckoConsole( 108): Attempt to use JS function on a different thread calling nsIDirectoryServiceProvider.getFile. JS objects may not be shared across threads
Updated•13 years ago
|
Attachment #613261 -
Flags: review?(mwu) → review+
Assignee | ||
Comment 3•13 years ago
|
||
Comment 4•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla14
Comment 5•13 years ago
|
||
Backout merged: https://hg.mozilla.org/mozilla-central/rev/a235528adace
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 6•13 years ago
|
||
Now with the proper Services.jsm import. The missing import was preventing the SmsDatabaseService from initializing the database, so it kind of fixed the freezing problem, but not in a very useful way.
mwu, would you mind testing this new patch with the missing import added, to see if it still fixes the problem?
Attachment #613261 -
Attachment is obsolete: true
Attachment #613832 -
Flags: feedback?(mwu)
Assignee | ||
Comment 7•13 years ago
|
||
Turns out, the provided patch doesn't fix the freeze, but it *does* fix the off-thread error. So I'm morphing this bug to just deal with that and filed the cloned bug 744300 to deal with the freeze.
Summary: B2G SMS database initialization freezes I/O thread → B2G SMS database initialization accesses Directory Provider off the main thread
Assignee | ||
Comment 8•13 years ago
|
||
Comment on attachment 613832 [details] [diff] [review]
v2
(Canceling feedback request, got feedback from mwu over IRC. Will commit this patch as it already has r+.)
Attachment #613832 -
Flags: feedback?(mwu)
Assignee | ||
Comment 9•13 years ago
|
||
Comment 10•13 years ago
|
||
Status: REOPENED → RESOLVED
Closed: 13 years ago → 13 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•