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

Issue 846846 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Jan 10
Cc:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug

Blocking:
issue 729596



Sign in to add a comment

Create ServiceManagerContext early.

Project Member Reported by hanxi@chromium.org, May 25 2018

Issue description

There are several dependencies in ServiceManagerContext need to be resolved before creating the ServiceManagerContext when content starts. For example, moving ChromeNetLog, DiscarsableSharedMemoryManager etc. from BrowserProcessImpl. File this bug to track the progress.

 

Comment 1 by hanxi@chromium.org, Jun 20 2018

Cc: ranj@chromium.org roc...@chromium.org yfried...@chromium.org jam@chromium.org qin...@chromium.org
Project Member

Comment 2 by bugdroid1@chromium.org, Jun 22 2018

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

commit 57b856f8e551d4c7b2d02000e581650acbc5b31b
Author: Xi Han <hanxi@google.com>
Date: Fri Jun 22 18:10:10 2018

Refactor of ServiceManagerContext.

In this CL, we refactor the ServiceManagerContext to make sure all of the
services can be registered without any dependency of BrowserMainLoop.
It includes the following changes:
1) Add API StartBrowserConnection() in ServiceManagerContext to start the
   browser connection to the ServiceManager. This API must be called after the
   BrowserMainLoop starts.
2) Make OutOfProcessServiceInfo takes a RepeatingCallbacks to get the process
   name.
3) ServiceMangerContext owns the DeferredSequencedTaskRunner for audio service.
   It was owned by BrowserMainloop before this CL.

BUG= 846846 ,729596

Change-Id: I29725a383e2662fccd8a2fba5fedddc52a8c565c
Reviewed-on: https://chromium-review.googlesource.com/1093021
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Ken Rockot <rockot@chromium.org>
Cr-Commit-Position: refs/heads/master@{#569694}
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/android_webview/browser/aw_content_browser_client.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/ash/shell/content/client/shell_content_browser_client.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/chrome/browser/ash_service_registry.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/chrome/browser/chrome_content_browser_client.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/browser/browser_main_loop.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/browser/browser_main_loop.h
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/browser/service_manager/service_manager_context.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/browser/service_manager/service_manager_context.h
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/public/browser/content_browser_client.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/public/browser/content_browser_client.h
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/public/test/test_service_manager_context.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/content/shell/browser/shell_content_browser_client.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/headless/lib/browser/headless_content_browser_client.cc
[modify] https://crrev.com/57b856f8e551d4c7b2d02000e581650acbc5b31b/services/service_manager/embedder/embedded_service_runner.cc

Project Member

Comment 3 by bugdroid1@chromium.org, Jul 10

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

commit 4fbe7c352ce0ef0550831d66fe0377a0bf018f04
Author: Xi Han <hanxi@google.com>
Date: Tue Jul 10 22:09:12 2018

Introduce StartupData Interface.

Introduce StartupData in /content/public/browser, and
StartupDataImpl in /content/browser.

This is a precursor CL for: https://crrev.com/c/1108178. In the
follow up CL, StartupData* will be plumbed via
MainFunctionParams to create the browser main loop.

Bug:  846846 ,  853308 
Change-Id: Ic192cfa696439996dec07435f1980d78282f15db
Reviewed-on: https://chromium-review.googlesource.com/1117471
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#573943}
[modify] https://crrev.com/4fbe7c352ce0ef0550831d66fe0377a0bf018f04/content/browser/BUILD.gn
[add] https://crrev.com/4fbe7c352ce0ef0550831d66fe0377a0bf018f04/content/browser/startup_data_impl.cc
[add] https://crrev.com/4fbe7c352ce0ef0550831d66fe0377a0bf018f04/content/browser/startup_data_impl.h
[modify] https://crrev.com/4fbe7c352ce0ef0550831d66fe0377a0bf018f04/content/public/browser/BUILD.gn
[add] https://crrev.com/4fbe7c352ce0ef0550831d66fe0377a0bf018f04/content/public/browser/startup_data.h

Project Member

Comment 4 by bugdroid1@chromium.org, Jul 11

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

commit 4090dccedd829fec4832c4c35546501ca6dc6108
Author: Xi Han <hanxi@google.com>
Date: Wed Jul 11 03:15:20 2018

Plumb pre-created service manager thread when creating BrowserMainLoop.

The service manager thread and (TODO) ServiceManager might be created
before the full browser starts, and we want to reuse them when starting
the full browser. Therefore, we add a pointer of BrowserStartupData in
MainFunctionParams.

Particularly, in this CL, ContentMainRunnerImpl creates and owns a
BrowserStartupData object. It passes a pointer of the BrowserStartupData
through the main function parameter to BrowserMainLoop.

The BrowserStartupData interface was introduced in:
https://crrev.com/c/1117471.

Bug:  846846 ,  853308 
Change-Id: Ie11063227a670cd8d72935131e854ee2b5c46e4e
Reviewed-on: https://chromium-review.googlesource.com/1108178
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Cr-Commit-Position: refs/heads/master@{#574054}
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/app/content_main_runner_impl.h
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/app/content_service_manager_main_delegate.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/app/content_service_manager_main_delegate.h
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/browser/browser_main.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/browser/browser_main.h
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/browser/browser_main_loop.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/browser/browser_main_loop.h
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/browser/browser_main_loop_unittest.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/browser/browser_main_runner_impl.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/browser/browser_main_runner_impl.h
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/public/common/main_function_params.h
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/content/public/test/browser_test_base.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/services/service_manager/embedder/main.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/services/service_manager/embedder/main_delegate.cc
[modify] https://crrev.com/4090dccedd829fec4832c4c35546501ca6dc6108/services/service_manager/embedder/main_delegate.h

Project Member

Comment 5 by bugdroid1@chromium.org, Jul 11

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

commit a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b
Author: Xi Han <hanxi@google.com>
Date: Wed Jul 11 15:25:01 2018

Split ContentMain start and ServiceManager Start.

With "allow-start-service-manager-only" flag, we can start the service
manager without starting the remaining parts of the browser,
particularly the browser main loop. Later, we could start the full
browser with the service manager running. Currently, both code path go
through service_manager::main(). Therefore, we need to avoid calling the
initialization in service_manager::main() multiple times.

In this CL:
1. service_manager::main() checks its static bool flag to decide
   whether initialization should be called.
2. Plumbs the start-service-manager-only flag to the ContentMainRunner
   who starts the browser main loop.

This CL impacts Android only for now. It follows up CL:
 https://crrev.com/c/1093303.

BUG=854209,  846846 

Change-Id: I7fcfb804ce7f3065da7df12947674344fe2f56d6
Reviewed-on: https://chromium-review.googlesource.com/1114077
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Ken Rockot <rockot@chromium.org>
Cr-Commit-Position: refs/heads/master@{#574169}
[modify] https://crrev.com/a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b/content/app/android/content_main.cc
[modify] https://crrev.com/a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b/content/app/content_main_runner_impl.h
[modify] https://crrev.com/a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b/content/app/content_service_manager_main_delegate.cc
[modify] https://crrev.com/a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b/content/app/content_service_manager_main_delegate.h
[modify] https://crrev.com/a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b/content/public/app/content_main_runner.h
[modify] https://crrev.com/a1105c68d4ac769d98f7dfd1e6303ea778fe1a6b/services/service_manager/embedder/main.cc

Project Member

Comment 6 by bugdroid1@chromium.org, Sep 18

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

commit 9b36fa5817ae866541e47742644edb84ce46c950
Author: Xi Han <hanxi@google.com>
Date: Tue Sep 18 13:47:22 2018

Cleanup in ContentMainRunnerImpl.

TBR=jam@chromium.org

Bug:  846846 
Change-Id: I296abce1c525b642010268d48a50fd4b57573211
Reviewed-on: https://chromium-review.googlesource.com/1228475
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592024}
[modify] https://crrev.com/9b36fa5817ae866541e47742644edb84ce46c950/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/9b36fa5817ae866541e47742644edb84ce46c950/content/app/content_main_runner_impl.h

Project Member

Comment 7 by bugdroid1@chromium.org, Oct 5

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

commit 8012e46931ce0dc90376b43990009899396ffd2f
Author: Xi Han <hanxi@google.com>
Date: Fri Oct 05 19:52:30 2018

Start TaskScheduler before creating BrowserMainLoop.

This is a follow up CL for: https://crrev.com/c/1115783.

In this CL, we use ScopedExecutionFence to prevents tasks running between the
peorid from BrowserMainRunner is instantiated to
BrowserMainLoop::CreateThreads() is called.

Bug:  846846 
Change-Id: I9dec8415e45f901c5883c196ab867c0ea4928594
Reviewed-on: https://chromium-review.googlesource.com/c/1174955
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Cr-Commit-Position: refs/heads/master@{#597255}
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/browser/browser_main_loop.cc
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/browser/browser_main_loop.h
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/browser/browser_main_loop_unittest.cc
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/browser/browser_main_runner_impl.cc
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/browser/browser_main_runner_impl.h
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/browser/startup_helper.cc
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/browser/startup_helper.h
[modify] https://crrev.com/8012e46931ce0dc90376b43990009899396ffd2f/content/public/test/browser_test_base.cc

Cc: -roc...@chromium.org rockot@google.com
Project Member

Comment 9 by bugdroid1@chromium.org, Oct 26

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

commit 349162b29094cd482cd2f90467b128b55057a804
Author: Xi Han <hanxi@google.com>
Date: Fri Oct 26 12:44:23 2018

Initialize ResouceBundle in ChromeFeatureListCreator.

In this CL, the entire ResouceBundle is initialized in the
ChromeFeatureListCreator. This prevents loading parts of the data pack
earlier and then add it to the ResouceBundle when the full browser
starts.

Bug:  846846 ,729596
Change-Id: Ia254252288ead936bde8cb65b12cf2fecbfc106f
Reviewed-on: https://chromium-review.googlesource.com/c/1292516
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603067}
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/android_webview/browser/aw_browser_main_parts.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/android_webview/lib/aw_main_delegate.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/android_webview/lib/aw_main_delegate.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/app/chrome_main_delegate.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/app/chrome_main_delegate.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/BUILD.gn
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/browser_process.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/browser_process_impl.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/browser_process_impl.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/chrome_browser_main.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/chrome_browser_main.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/chrome_browser_main_android.cc
[add] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/chrome_resource_bundle_helper.cc
[add] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/chrome_resource_bundle_helper.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/chromeos/base/locale_util.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/metrics/chrome_feature_list_creator.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/speech/tts_controller_unittest.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/translate/translate_manager_render_view_host_unittest.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/browser/ui/search/local_ntp_test_utils.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/test/base/scoped_browser_locale.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/test/base/testing_browser_process.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/chrome/test/base/testing_browser_process.h
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/349162b29094cd482cd2f90467b128b55057a804/content/public/app/content_main_delegate.h

Project Member

Comment 10 by bugdroid1@chromium.org, Oct 26

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

commit aa60c219407f1158214858e83e5456e42dcfe891
Author: Xi Han <hanxi@google.com>
Date: Fri Oct 26 15:02:30 2018

Start ServiceManger before creating BrowserMainLoop.

This CL instantiates the ServiceManagerContext before creating
the BrowserMainRunner. It splits the startup path into two,
with/without starting the full browser. The changes are implemented
behind a flag "allow-start-service-manager-only".

Bug:  846846 ,729596
Change-Id: I3584db0d89a10e59d6041e0f4412aaffdc840568
Reviewed-on: https://chromium-review.googlesource.com/c/1113802
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603092}
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/app/DEPS
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/app/content_main_runner_impl.h
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/browser/browser_main_loop.cc
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/browser/browser_main_loop.h
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/browser/browser_main_loop_unittest.cc
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/browser/service_manager/service_manager_context.cc
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/browser/service_manager/service_manager_context.h
[modify] https://crrev.com/aa60c219407f1158214858e83e5456e42dcfe891/content/browser/startup_data_impl.h

Project Member

Comment 11 by bugdroid1@chromium.org, Oct 26

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

commit 4339da08a99855adc47716ff95f62b5f60ebe66c
Author: Xi Han <hanxi@chromium.org>
Date: Fri Oct 26 21:24:08 2018

Revert "Start ServiceManger before creating BrowserMainLoop."

This reverts commit aa60c219407f1158214858e83e5456e42dcfe891.

Reason for revert: it breaks  network_service_webview_instrumentation_test_apk on Mojo Android Build:
https://bugs.chromium.org/p/chromium/issues/detail?id=899376

Bug:899376

Original change's description:
> Start ServiceManger before creating BrowserMainLoop.
> 
> This CL instantiates the ServiceManagerContext before creating
> the BrowserMainRunner. It splits the startup path into two,
> with/without starting the full browser. The changes are implemented
> behind a flag "allow-start-service-manager-only".
> 
> Bug:  846846 ,729596
> Change-Id: I3584db0d89a10e59d6041e0f4412aaffdc840568
> Reviewed-on: https://chromium-review.googlesource.com/c/1113802
> Commit-Queue: Xi Han <hanxi@chromium.org>
> Reviewed-by: John Abd-El-Malek <jam@chromium.org>
> Reviewed-by: Gabriel Charette <gab@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#603092}

TBR=gab@chromium.org,jam@chromium.org,hanxi@chromium.org

Change-Id: I866cc2148d529d0d7a02d0ac75b2817d1695a8c9
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug:  846846 , 729596
Reviewed-on: https://chromium-review.googlesource.com/c/1303042
Reviewed-by: Xi Han <hanxi@chromium.org>
Commit-Queue: Xi Han <hanxi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603194}
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/app/DEPS
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/app/content_main_runner_impl.h
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/browser/browser_main_loop.cc
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/browser/browser_main_loop.h
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/browser/browser_main_loop_unittest.cc
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/browser/service_manager/service_manager_context.cc
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/browser/service_manager/service_manager_context.h
[modify] https://crrev.com/4339da08a99855adc47716ff95f62b5f60ebe66c/content/browser/startup_data_impl.h

Project Member

Comment 12 by bugdroid1@chromium.org, Nov 2

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

commit f481306ad989755ebe61cfed4ab2a4fa53044b29
Author: Xi Han <hanxi@google.com>
Date: Fri Nov 02 17:19:18 2018

Reland "Start ServiceManger before creating BrowserMainLoop."

This relands commit aa60c219407f1158214858e83e5456e42dcfe891. The original CL
(https://crrev.com/c/1113802) got reverted becuase FeatureList and field
trials are not setup properly in early startup in Android WebView, but
ServiceMangerContext has checked features. See  crbug.com/899376 . The fix is
in a separate CL: https://crrev.com/c/1305876. Another related precursor CL
is: https://crrev.com/c/1308096.

This CL is an exact copy of the original CL.

The original cl description is:
This CL instantiates the ServiceManagerContext before creating
the BrowserMainRunner. It splits the startup path into two,
with/without starting the full browser. The changes are implemented
behind a flag "allow-start-service-manager-only".

Bug:  846846 ,729596
TBR: jam@chromium.org
Change-Id: I5214af850d4ef256c9d223db059ed009a42de714
Reviewed-on: https://chromium-review.googlesource.com/c/1305822
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Cr-Commit-Position: refs/heads/master@{#604969}
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/app/DEPS
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/app/content_main_runner_impl.h
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/browser/browser_main_loop.cc
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/browser/browser_main_loop.h
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/browser/browser_main_loop_unittest.cc
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/browser/service_manager/service_manager_context.cc
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/browser/service_manager/service_manager_context.h
[modify] https://crrev.com/f481306ad989755ebe61cfed4ab2a4fa53044b29/content/browser/startup_data_impl.h

Project Member

Comment 13 by bugdroid1@chromium.org, Nov 7

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

commit faa86b61f1f34002e7bdfc923541d453b9e4223f
Author: Yoshifumi Inoue <yosin@chromium.org>
Date: Wed Nov 07 09:55:04 2018

Revert "Reland "Start ServiceManger before creating BrowserMainLoop.""

This reverts commit f481306ad989755ebe61cfed4ab2a4fa53044b29 and
disables following tests on Windows:
 * RenderThreadImplBrowserTest.NonResourceDispatchIPCTasksDontGoThroughScheduler
 * UserScriptListenerTest.NavigationWaitsForContentScriptsToLoad

Reason for revert: Causes BrowserMainLoopTest, CreateThreadsInSingleProcess to fail every time content_unittests is run, if DCHECKs are enabled.

Original change's description:
> Reland "Start ServiceManger before creating BrowserMainLoop."
>
> This relands commit aa60c219407f1158214858e83e5456e42dcfe891. The original CL
> (https://crrev.com/c/1113802) got reverted becuase FeatureList and field
> trials are not setup properly in early startup in Android WebView, but
> ServiceMangerContext has checked features. See  crbug.com/899376 . The fix is
> in a separate CL: https://crrev.com/c/1305876. Another related precursor CL
> is: https://crrev.com/c/1308096.
>
> This CL is an exact copy of the original CL.
>
> The original cl description is:
> This CL instantiates the ServiceManagerContext before creating
> the BrowserMainRunner. It splits the startup path into two,
> with/without starting the full browser. The changes are implemented
> behind a flag "allow-start-service-manager-only".
>
> Bug:  846846 ,729596
> TBR: jam@chromium.org
> Change-Id: I5214af850d4ef256c9d223db059ed009a42de714
> Reviewed-on: https://chromium-review.googlesource.com/c/1305822
> Commit-Queue: Xi Han <hanxi@chromium.org>
> Reviewed-by: Gabriel Charette <gab@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#604969}

TBR=gab@chromium.org,jam@chromium.org,hanxi@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug:  846846 , 729596,  902311 
Change-Id: I8b46711602a240023f4a03a69aa70f66d4eee726
Reviewed-on: https://chromium-review.googlesource.com/c/1322343
Reviewed-by: Yoshifumi Inoue <yosin@chromium.org>
Commit-Queue: Yoshifumi Inoue <yosin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#606004}
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/chrome/browser/extensions/user_script_listener_browsertest.cc
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/app/DEPS
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/app/content_main_runner_impl.h
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/browser/browser_main_loop.cc
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/browser/browser_main_loop.h
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/browser/browser_main_loop_unittest.cc
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/browser/service_manager/service_manager_context.cc
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/browser/service_manager/service_manager_context.h
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/browser/startup_data_impl.h
[modify] https://crrev.com/faa86b61f1f34002e7bdfc923541d453b9e4223f/content/renderer/render_thread_impl_browsertest.cc

Project Member

Comment 14 by bugdroid1@chromium.org, Nov 27

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

commit 3575eb72d8073cbf789dc5436446fe5f888eea52
Author: Xi Han <hanxi@google.com>
Date: Tue Nov 27 21:39:29 2018

Reland "Start ServiceManger before creating BrowserMainLoop."

This relands commit f481306ad989755ebe61cfed4ab2a4fa53044b29. The CL
got reverted because BrowserMainLoopTest.CreateThreadsInSingleProcess
is falling on Windows. In this CL, we remove the call of
BrowserMainLoop#InitilaizeMojo() which isn't necessary for the test.

Beside, also re-enable two tests which were disabled when the reverting
CL landed:
 * RenderThreadImplBrowserTest.NonResourceDispatchIPCTasksDontGoThroughScheduler

The original cl description is:
This CL instantiates the ServiceManagerContext before creating
the BrowserMainRunner. It splits the startup path into two,
with/without starting the full browser. The changes are implemented
behind a flag "allow-start-service-manager-only".

Bug:  846846 , 902311 
Change-Id: I6e3f6518e414e1298e57b55bd188879461d8f342
Reviewed-on: https://chromium-review.googlesource.com/c/1327413
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#611340}
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/app/DEPS
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/app/content_main_runner_impl.h
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/browser/browser_main_loop.cc
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/browser/browser_main_loop.h
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/browser/service_manager/service_manager_context.cc
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/browser/service_manager/service_manager_context.h
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/browser/startup_data_impl.h
[modify] https://crrev.com/3575eb72d8073cbf789dc5436446fe5f888eea52/content/renderer/render_thread_impl_browsertest.cc

Project Member

Comment 15 by bugdroid1@chromium.org, Nov 29

Labels: merge-merged-3578
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d5be60ba310d4acc439c440d3dc45c410ca75111

commit d5be60ba310d4acc439c440d3dc45c410ca75111
Author: Alexei Svitkine <asvitkine@chromium.org>
Date: Thu Nov 29 13:24:13 2018

Initialize ResouceBundle in ChromeFeatureListCreator.

In this CL, the entire ResouceBundle is initialized in the
ChromeFeatureListCreator. This prevents loading parts of the data pack
earlier and then add it to the ResouceBundle when the full browser
starts.

TBR=hanxi@google.com

(cherry picked from commit 349162b29094cd482cd2f90467b128b55057a804)

Bug:  846846 ,729596
Change-Id: Ia254252288ead936bde8cb65b12cf2fecbfc106f
Reviewed-on: https://chromium-review.googlesource.com/c/1292516
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#603067}
Reviewed-on: https://chromium-review.googlesource.com/c/1354268
Reviewed-by: Alexei Svitkine <asvitkine@chromium.org>
Cr-Commit-Position: refs/branch-heads/3578@{#846}
Cr-Branched-From: 4226ddf99103e493d7afb23a4c7902ee496108b6-refs/heads/master@{#599034}
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/android_webview/browser/aw_browser_main_parts.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/android_webview/lib/aw_main_delegate.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/android_webview/lib/aw_main_delegate.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/app/chrome_main_delegate.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/app/chrome_main_delegate.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/BUILD.gn
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/browser_process.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/browser_process_impl.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/browser_process_impl.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/chrome_browser_main.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/chrome_browser_main.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/chrome_browser_main_android.cc
[add] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/chrome_resource_bundle_helper.cc
[add] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/chrome_resource_bundle_helper.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/chromeos/base/locale_util.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/metrics/chrome_feature_list_creator.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/translate/translate_manager_render_view_host_unittest.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/browser/ui/search/local_ntp_test_utils.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/test/base/scoped_browser_locale.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/test/base/testing_browser_process.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/chrome/test/base/testing_browser_process.h
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/d5be60ba310d4acc439c440d3dc45c410ca75111/content/public/app/content_main_delegate.h

Labels: Merge-Merged-71-3578
The following revision refers to this bug: 
https://chromium.googlesource.com/chromium/src.git/+/d5be60ba310d4acc439c440d3dc45c410ca75111

Commit: d5be60ba310d4acc439c440d3dc45c410ca75111
Author: asvitkine@chromium.org
Commiter: asvitkine@chromium.org
Date: 2018-11-29 13:24:13 +0000 UTC

Initialize ResouceBundle in ChromeFeatureListCreator.

In this CL, the entire ResouceBundle is initialized in the
ChromeFeatureListCreator. This prevents loading parts of the data pack
earlier and then add it to the ResouceBundle when the full browser
starts.

TBR=hanxi@google.com

(cherry picked from commit 349162b29094cd482cd2f90467b128b55057a804)

Bug:  846846 ,729596
Change-Id: Ia254252288ead936bde8cb65b12cf2fecbfc106f
Reviewed-on: https://chromium-review.googlesource.com/c/1292516
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#603067}
Reviewed-on: https://chromium-review.googlesource.com/c/1354268
Reviewed-by: Alexei Svitkine <asvitkine@chromium.org>
Cr-Commit-Position: refs/branch-heads/3578@{#846}
Cr-Branched-From: 4226ddf99103e493d7afb23a4c7902ee496108b6-refs/heads/master@{#599034}
Project Member

Comment 17 by bugdroid1@chromium.org, Dec 11

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

commit 6975304c27f43848f0315d8939184a1e48484191
Author: Xi Han <hanxi@google.com>
Date: Tue Dec 11 20:16:29 2018

Force NetworkService run in process in ServiceManager only mode.

Foces ServiceManager to register NetworkService as a in process service when
running in the ServiceManager only mode.

Bug:  846846 
Change-Id: I9693bbcb3d0379fc293b2277d5dd513a03d3fe8c
Reviewed-on: https://chromium-review.googlesource.com/c/1368455
Reviewed-by: Ken Rockot <rockot@google.com>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Min Qin <qinmin@chromium.org>
Commit-Queue: Xi Han <hanxi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#615640}
[modify] https://crrev.com/6975304c27f43848f0315d8939184a1e48484191/chrome/android/javatests/src/org/chromium/chrome/browser/ServicificationBackgroundServiceTest.java
[modify] https://crrev.com/6975304c27f43848f0315d8939184a1e48484191/chrome/android/javatests/src/org/chromium/chrome/browser/download/ServicificationDownloadTest.java
[modify] https://crrev.com/6975304c27f43848f0315d8939184a1e48484191/content/app/DEPS
[modify] https://crrev.com/6975304c27f43848f0315d8939184a1e48484191/content/app/content_main_runner_impl.cc
[modify] https://crrev.com/6975304c27f43848f0315d8939184a1e48484191/content/public/common/network_service_util.cc
[modify] https://crrev.com/6975304c27f43848f0315d8939184a1e48484191/content/public/common/network_service_util.h

Status: Fixed (was: Assigned)

Sign in to add a comment