Jeffrey Yasskin
unread,Mar 13, 2013, 2:54:11 PM3/13/13Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Mihai Sardarescu, chromium-dev, Jeremy Moskovich, Scott Violet, William Chan, Susanna Leng, Stuart Morgan
If I were doing this, I'd write a new TaskRunner implementation just
for this purpose. Instantiate it once (per profile?), add one task for
each service, and have that task bounce over to the appropriate
TaskRunner for the service.
We're likely to want to play with different strategies for kicking off
tasks. Maybe we'll want a single method that's called N seconds after
startup, which then runs tasks every M seconds. Maybe we'll want a
method that's called when other TaskRunners are idle, and then waits N
seconds after all of them are idle before running the next task. Maybe
we'll want to give service loaders a completion callback, which tells
the "startup" TaskRunner that it can move on to the next service.
Maybe we'll want a way to eagerly start a service when, for example,
the user tries to open the bookmarks manager before it's loaded.
I'd do the simplest thing for now, but leave room for that kind of
experimentation.