Closed
Bug 336833
Opened 19 years ago
Closed 18 years ago
microsummary service should delay caching generators until after bookmarks service inited
Categories
(Firefox Graveyard :: Microsummaries, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: myk, Assigned: myk)
Details
(Keywords: fixed1.8.1)
Attachments
(1 file, 7 obsolete files)
(deleted),
patch
|
myk
:
review+
bugs
:
superreview+
bugs
:
approval-branch-1.8.1+
|
Details | Diff | Splinter Review |
To reclaim the slight Ts regression on sparky and atlantia from the microsummaries landing, the microsummary service should delay caching generators until after the bookmarks service has been initialized.
Assignee | ||
Comment 1•19 years ago
|
||
This patch makes the bookmarks service notify observers of the "bookmarks-service-initialized" topic when it finishes initializing the bookmarks data source. The microsummary service then delays initialization until it receives that notification.
Assignee: nobody → myk
Status: NEW → ASSIGNED
Attachment #221034 -
Flags: review?
Attachment #221034 -
Flags: approval-branch-1.8.1?(bugs)
Comment 2•19 years ago
|
||
Comment on attachment 221034 [details] [diff] [review]
branch patch v1: makes microsummary service wait until it hears from bookmarks service
remove your profile-after-change observer too, since you don't seem to use it anymore
Attachment #221034 -
Flags: review? → review-
Assignee | ||
Comment 3•19 years ago
|
||
Now that the service is observing bookmarks-service-initialized it doesn't need to be observing profile-after-change at all.
Attachment #221034 -
Attachment is obsolete: true
Attachment #221034 -
Flags: approval-branch-1.8.1?(bugs)
Assignee | ||
Comment 4•19 years ago
|
||
Attachment #221035 -
Attachment is obsolete: true
Attachment #221036 -
Flags: review?
Comment 5•19 years ago
|
||
Comment on attachment 221036 [details] [diff] [review]
patch v3: and this one breaks appropriately
r+a=ben@mozilla.org
Attachment #221036 -
Flags: review?
Attachment #221036 -
Flags: review+
Attachment #221036 -
Flags: approval-branch-1.8.1+
Assignee | ||
Comment 6•19 years ago
|
||
Checked into the 1.8 branch. Leaving the bug open until we get a trunk fix.
Brett, Ben says that "the 'delayedStartup' step is the query that populates the bookmarks toolbar" but that you would know best where in the Places code it makes the most sense to notify observers of the "bookmarks-service-initialized" topic. What do you think?
Assignee | ||
Updated•19 years ago
|
Keywords: fixed1.8.1
Comment 7•19 years ago
|
||
I meant LoadBookmarks, not Init(). Oops.
Attachment #221036 -
Attachment is obsolete: true
Comment 8•19 years ago
|
||
Myk, I landed this patch on the branch since you weren't on IRC.
Assignee | ||
Comment 9•19 years ago
|
||
mconnor suggested on IRC that we actually wait until final-ui-startup "to prevent init before em restart", but it's not clear that doing so fixes the Ts regression.
Assignee | ||
Comment 10•19 years ago
|
||
So far I've had no luck getting a machine to give consistent Ts results. Besides the general suggestions on the wiki (http://wiki.mozilla.org/Performance:Tinderbox_Tests#Notes_before_starting) and shutting down all unnecessary services, are there other things I can do to get consistent numbers I can use as a basis for testing potential solutions to this regression?
Assignee | ||
Comment 11•19 years ago
|
||
Here's another possible approach that not only waits until the bookmarks service has been initialized, it waits another second after that. I considered waiting for final-ui-startup instead, but that happens before bookmarks service initialization, and since we can't do much without the bookmarks service, we might as wait for it.
It's unclear whether this patch helps fix this minor Ts regression, as my laptop lacks the resolution to make that determination, even after following the recommendations at http://wiki.mozilla.org/Performance:Tinderbox_Tests. Also, it would probably be better to define a topic that definitively represents a "reached post-Ts state" notification and then observe that instead. I'm just not sure where to fire off such a topic, and in the meantime this patch stands a reasonable chance of making a difference.
This patch also adds "bookmarks-service-initialized" notification to the Places version of the bookmarks service at the end of nsNavBookmarks::Init(), which is where Brett says it should go.
Attachment #221488 -
Flags: review?
Assignee | ||
Updated•19 years ago
|
Attachment #221488 -
Flags: review? → review?(bugs)
Assignee | ||
Comment 12•19 years ago
|
||
This is a version of patch v5 that applies cleanly to the trunk, which is now out of sync with the branch since we checked in earlier patches only to the branch.
Assignee | ||
Comment 13•19 years ago
|
||
Per more discussions with Ben, this patch now initializes the microsummary service when delayedStartup() is called.
Attachment #221488 -
Attachment is obsolete: true
Attachment #221490 -
Attachment is obsolete: true
Attachment #221513 -
Flags: review?(bugs)
Attachment #221488 -
Flags: review?(bugs)
Comment 14•19 years ago
|
||
Comment on attachment 221513 [details] [diff] [review]
patch v6: initialize on delayedStartup()
> case "xpcom-shutdown":
>+ this._obs.removeObserver(this, "xpcom-shutdown");
> this._destroy();
> break;
you don't need to explicitly remove this observer, since its holding a weak ref now it shouldn't leak (see bz's patch in bug 336922)
Attachment #221513 -
Flags: review?(bugs) → review+
Assignee | ||
Comment 15•19 years ago
|
||
mconnor says on IRC to carry forward his review. Note that when I check this in to the trunk I'll omit the change to nsBookmarksService.cpp, since that just reverts an earlier attempt to fix this bug that never made it to the trunk.
Attachment #221050 -
Attachment is obsolete: true
Attachment #221513 -
Attachment is obsolete: true
Attachment #221534 -
Flags: review+
Comment 16•19 years ago
|
||
Comment on attachment 221534 [details] [diff] [review]
patch v7: includes the change to browser.js
sr+a=ben@mozilla.org
Attachment #221534 -
Flags: superreview+
Attachment #221534 -
Flags: approval-branch-1.8.1+
Assignee | ||
Comment 17•18 years ago
|
||
This has been landed on trunk and branch.
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Assignee | ||
Updated•18 years ago
|
Component: Bookmarks → Microsummaries
Updated•9 years ago
|
Product: Firefox → Firefox Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•