New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 887407 link

Starred by 2 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Feature

Blocking:
issue 872372



Sign in to add a comment

Move AfterStartupTasks to PostTaskWithTraits

Project Member Reported by eseckler@chromium.org, Sep 20

Issue description

We should deprecate/remove BrowserThread::PostAfterStartupTask and make callsites post to the UI thread scheduler with appropriately prioritizing traits instead.
 
Blocking: 872372
Well, they're not all being posted to BrowserThread::UI today AFAIK. So it's really about using the new post_task.h which *also* supports BEST_EFFORT work on BrowserThread::UI and thus fully deprecates AfterStartupTasks.
Summary: Move AfterStartupTasks to PostTaskWithTraits (was: Move AfterStartupTasks to UI thread scheduler)
sgtm :)
Project Member

Comment 4 by bugdroid1@chromium.org, Oct 12

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/36bf5fece1a539ce254e55a51a0be56718c743d3

commit 36bf5fece1a539ce254e55a51a0be56718c743d3
Author: Eric Robinson <ericrobinson@chromium.org>
Date: Fri Oct 12 15:11:09 2018

Replace IsAfterStartupTask in RulesetService with PostTaskWithTraits.

This replaces the specialized AfterStartupTask paradigm with a BEST_EFFORT
task on the UI thread for the RulesetService, adjusting tests as
necessary.

Bug: 887407
Change-Id: Id93a5b77e1433281b5cdd49a3599463a61b41703
Reviewed-on: https://chromium-review.googlesource.com/c/1255343
Reviewed-by: Nico Weber <thakis@chromium.org>
Reviewed-by: Charlie Harrison <csharrison@chromium.org>
Commit-Queue: Eric Robinson <ericrobinson@chromium.org>
Cr-Commit-Position: refs/heads/master@{#599217}
[modify] https://crrev.com/36bf5fece1a539ce254e55a51a0be56718c743d3/chrome/browser/android/subresource_filter/test_subresource_filter_publisher.cc
[modify] https://crrev.com/36bf5fece1a539ce254e55a51a0be56718c743d3/chrome/browser/page_load_metrics/observers/ads_page_load_metrics_observer_browsertest.cc
[modify] https://crrev.com/36bf5fece1a539ce254e55a51a0be56718c743d3/chrome/browser/subresource_filter/subresource_filter_browser_test_harness.cc
[modify] https://crrev.com/36bf5fece1a539ce254e55a51a0be56718c743d3/components/subresource_filter/content/browser/ruleset_service.cc
[modify] https://crrev.com/36bf5fece1a539ce254e55a51a0be56718c743d3/components/subresource_filter/content/browser/ruleset_service.h
[modify] https://crrev.com/36bf5fece1a539ce254e55a51a0be56718c743d3/components/subresource_filter/content/browser/ruleset_service_unittest.cc
[modify] https://crrev.com/36bf5fece1a539ce254e55a51a0be56718c743d3/components/subresource_filter/core/browser/ruleset_service_delegate.h

Project Member

Comment 5 by bugdroid1@chromium.org, Oct 29

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/0618f40726db75dd1db66c6b438fb74343392303

commit 0618f40726db75dd1db66c6b438fb74343392303
Author: Eric Seckler <eseckler@chromium.org>
Date: Mon Oct 29 12:08:52 2018

content: Make BEST_EFFORT tasks run after startup where possible.

Folks have started to replace PostAfterStartupTask with posting
BEST_EFFORT tasks instead, e.g.: https://crrev.com/c/1255343.

This preserves the behavior of AfterStartupTasks for tasks posted to a
BrowserThread via base::PostTask with BEST_EFFORT priority, while we
wait for the BrowserUIThreadScheduler.

Bug: 887407
Change-Id: Id98e4714435c801342002c710657b0f0784e55e0
Reviewed-on: https://chromium-review.googlesource.com/c/1283093
Reviewed-by: Xiyuan Xia <xiyuan@chromium.org>
Reviewed-by: Jochen Eisinger <jochen@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Commit-Queue: Eric Seckler <eseckler@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603463}
[modify] https://crrev.com/0618f40726db75dd1db66c6b438fb74343392303/chrome/browser/after_startup_task_utils.cc
[modify] https://crrev.com/0618f40726db75dd1db66c6b438fb74343392303/chrome/browser/chromeos/app_mode/kiosk_app_manager.cc
[modify] https://crrev.com/0618f40726db75dd1db66c6b438fb74343392303/chrome/browser/chromeos/ownership/owner_settings_service_chromeos.cc
[modify] https://crrev.com/0618f40726db75dd1db66c6b438fb74343392303/content/browser/scheduler/browser_task_executor.cc
[modify] https://crrev.com/0618f40726db75dd1db66c6b438fb74343392303/content/browser/scheduler/browser_task_executor.h
[modify] https://crrev.com/0618f40726db75dd1db66c6b438fb74343392303/content/browser/scheduler/browser_task_executor_unittest.cc

Sign in to add a comment