Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(385)

Issue 2793623002: android: Limit num renderer to service slots (Closed)

Created:
3 years, 8 months ago by boliu
Modified:
3 years, 8 months ago
Reviewers:
Jay Civelli
CC:
chromium-reviews, jam, nasko+codewatch_chromium.org, darin-cc_chromium.org, creis+watch_chromium.org, agrieve+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

android: Limit num renderer to service slots This is a temporary workaround crbug.com/693484. The issue is chrome on android expects the OS to not be able to maintain more than 20 service processes. So the current code can only has 20 sandboxed slots, but tells chrome that it can create as many renderer as it wants. On some OEM devices, android has been tweaked to allow more than 20 background processes, and this leads to a catastrophic failure case of not being able to create new renderers. The real fix of chrome actively killing LRU child is not ready, so this is an imperfect workaround, to tell chrome to not create more than 20 renderers. Note this will not cover all cases since this is a soft limit, and there are other non-renderer sandboxed child processes beyond renderer. But this should cover a large chunk of use cases to be address this severe failure case in the short term. BUG=693484 Review-Url: https://codereview.chromium.org/2793623002 Cr-Commit-Position: refs/heads/master@{#461482} Committed: https://chromium.googlesource.com/chromium/src/+/cbef3d37319db3e6153494db5f97df9412959856

Patch Set 1 #

Patch Set 2 : catch exception in unit tests #

Patch Set 3 : fix remaining unit tests #

Total comments: 6
Unified diffs Side-by-side diffs Delta from patch set Stats (+47 lines, -6 lines) Patch
M content/browser/child_process_launcher.h View 1 chunk +5 lines, -0 lines 0 comments Download
M content/browser/child_process_launcher.cc View 1 chunk +7 lines, -0 lines 0 comments Download
M content/browser/child_process_launcher_helper.h View 1 chunk +1 line, -0 lines 3 comments Download
M content/browser/child_process_launcher_helper_android.cc View 1 chunk +7 lines, -0 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 1 chunk +7 lines, -1 line 0 comments Download
M content/browser/renderer_host/render_process_host_unittest.cc View 1 2 1 chunk +0 lines, -4 lines 3 comments Download
M content/public/android/java/src/org/chromium/content/browser/ChildProcessLauncher.java View 1 chunk +1 line, -1 line 0 comments Download
M content/public/android/java/src/org/chromium/content/browser/ChildProcessLauncherHelper.java View 1 2 2 chunks +19 lines, -0 lines 0 comments Download

Messages

Total messages: 14 (7 generated)
boliu
comfortable stamping this?
3 years, 8 months ago (2017-04-01 00:28:26 UTC) #5
Jay Civelli
How does the Chrome native code handles the killing of the service when we reach ...
3 years, 8 months ago (2017-04-03 16:19:48 UTC) #6
boliu
pushing back a bit on all comments :p On 2017/04/03 16:19:48, Jay Civelli wrote: > ...
3 years, 8 months ago (2017-04-03 16:33:03 UTC) #7
Jay Civelli
https://codereview.chromium.org/2793623002/diff/40001/content/browser/child_process_launcher_helper.h File content/browser/child_process_launcher_helper.h (right): https://codereview.chromium.org/2793623002/diff/40001/content/browser/child_process_launcher_helper.h#newcode173 content/browser/child_process_launcher_helper.h:173: static size_t GetNumberOfRendererSlots(); On 2017/04/03 16:33:03, boliu wrote: > ...
3 years, 8 months ago (2017-04-03 16:40:50 UTC) #8
Jay Civelli
lgtm
3 years, 8 months ago (2017-04-03 16:40:58 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2793623002/40001
3 years, 8 months ago (2017-04-03 16:45:15 UTC) #11
commit-bot: I haz the power
3 years, 8 months ago (2017-04-03 18:36:24 UTC) #14
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as
https://chromium.googlesource.com/chromium/src/+/cbef3d37319db3e6153494db5f97...

Powered by Google App Engine
This is Rietveld 408576698