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

Issue 2497313002: android: Don't keep GSA alive if it supports account change broadcasts. (Closed)

Created:
4 years, 1 month ago by Benoit L
Modified:
4 years, 1 month ago
Reviewers:
CC:
chromium-reviews
Target Ref:
refs/pending/branch-heads/2883
Project:
chromium
Visibility:
Public.

Description

android: Don't keep GSA alive if it supports account change broadcasts. Chrome currently connects to a bound service exposed by GSA to get account change notifications. This elevates GSA's priority for the system to the foreground level when Chrome is in the foreground, artificially increasing Chrome's memory footprint. On some phones, the memory consumption of the GSA process can be above 100MB (PSS), even though only the account change notifications are required. Newer versions of GSA send a broadcast intent when the account changes. This CL listens to the broadcasts, and disonnects from the GSA service when GSA support the account change broadcast mechanism, freing the memory for Chrome or other apps on the system. Note that Chrome still briefly connects to GSA on startup to confirm that it supports the broadcast. A forthcoming will remove this. BUG=614388 Review-Url: https://codereview.chromium.org/2431223004 Cr-Commit-Position: refs/heads/master@{#427840} (cherry picked from commit e1d19b388fc67f31372a4c2df33e20c0c18dfd97) Committed: https://chromium.googlesource.com/chromium/src/+/0d49cd8de23891fc2d4d4260271795c4c294bcd4

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+158 lines, -12 lines) Patch
M chrome/android/java/AndroidManifest.xml View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/ChromeActivity.java View 4 chunks +5 lines, -7 lines 0 comments Download
A chrome/android/java/src/org/chromium/chrome/browser/gsa/GSAAccountChangeListener.java View 1 chunk +138 lines, -0 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/gsa/GSAServiceClient.java View 7 chunks +12 lines, -5 lines 0 comments Download
M chrome/android/java_sources.gni View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 3 (1 generated)
Benoit L
Committed patchset #1 (id:1) manually as 0d49cd8de23891fc2d4d4260271795c4c294bcd4 (tree was closed).
4 years, 1 month ago (2016-11-14 14:57:11 UTC) #2
amineer
4 years, 1 month ago (2016-11-15 20:11:59 UTC) #3
Message was sent while issue was closed.
A revert of this CL (patchset #1 id:1) has been created in
https://codereview.chromium.org/2507523003/ by amineer@chromium.org.

The reason for reverting is: Causing crashes, see crbug/665396.

Powered by Google App Engine
This is Rietveld 408576698