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

Issue 8665011: sync: remove GetAuthenticatedUsername from ProfileSyncService/SyncBackendHost. (Closed)

Created:
9 years, 1 month ago by tim (not reviewing)
Modified:
9 years ago
CC:
chromium-reviews, ncarter (slow), nkostylev+watch_chromium.org, Raghu Simha, cbentzel+watch_chromium.org, darin-cc_chromium.org, davemoore+watch_chromium.org, Paweł Hajdan Jr., estade+watch_chromium.org, stevenjb+watch_chromium.org, tim (not reviewing), akalin
Visibility:
Public.

Description

sync: remove GetAuthenticatedUsername from ProfileSyncService/SyncBackendHost. Removing as it's not necessary and simplifies code to make it easier to ultimately rid ProfileSyncService of cros_user, and ultimately convert it to a ProfileKeyedService. Before this change the two values only differ 1) on chrome os, where kGoogleServicesUsername doesn't seem to be set today (and in some cases we use cros_user as a crutch), and 2) when kGoogleServicesUsername is cleared, but that only happens on DisableForUser. In the future I'd imagine this value to be allowed to outlive that call as well, which would be OK. BUG=88109, 93922 TEST=bits of UI that show usernames continue to show usernames Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=112643

Patch Set 1 : init #

Total comments: 1

Patch Set 2 : fix test #

Total comments: 8

Patch Set 3 : review #

Patch Set 4 : rebase #

Total comments: 4

Patch Set 5 : review2 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+80 lines, -75 lines) Patch
M chrome/browser/chromeos/login/login_utils.cc View 1 2 3 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/sync/glue/sync_backend_host.h View 1 2 3 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/glue/sync_backend_host.cc View 1 2 3 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/internal_api/sync_manager.h View 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/internal_api/sync_manager.cc View 1 2 3 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/profile_sync_service.h View 1 2 3 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/sync/profile_sync_service.cc View 1 2 3 1 chunk +0 lines, -7 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_mock.h View 1 2 3 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_mock.cc View 1 2 1 chunk +21 lines, -0 lines 0 comments Download
M chrome/browser/sync/sync_global_error_unittest.cc View 1 2 3 4 chunks +8 lines, -9 lines 0 comments Download
M chrome/browser/sync/sync_setup_flow.cc View 2 chunks +5 lines, -5 lines 0 comments Download
M chrome/browser/sync/sync_setup_wizard_unittest.cc View 2 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/sync/sync_ui_util.cc View 1 2 3 4 6 chunks +11 lines, -6 lines 0 comments Download
M chrome/browser/sync/sync_ui_util_unittest.cc View 1 2 3 4 10 chunks +17 lines, -22 lines 0 comments Download
M chrome/browser/ui/webui/ntp/new_tab_page_sync_handler.cc View 2 chunks +5 lines, -1 line 0 comments Download

Messages

Total messages: 10 (0 generated)
tim (not reviewing)
I'm in the process of trying this out on chromeos, but what with turkey day ...
9 years, 1 month ago (2011-11-23 20:13:41 UTC) #1
Andrew T Wilson (Slow)
http://codereview.chromium.org/8665011/diff/5001/chrome/browser/sync/sync_setup_flow.cc File chrome/browser/sync/sync_setup_flow.cc (right): http://codereview.chromium.org/8665011/diff/5001/chrome/browser/sync/sync_setup_flow.cc#newcode107 chrome/browser/sync/sync_setup_flow.cc:107: prefs::kGoogleServicesUsername)); I'm slightly nervous about this, as it's not ...
9 years, 1 month ago (2011-11-24 01:48:16 UTC) #2
stevenjb
I applied this patch, ran it on a chromeos device, and induced a browser crash. ...
9 years, 1 month ago (2011-11-24 03:31:26 UTC) #3
tim (not reviewing)
Thanks for the review + big thanks for trying the patch Steven! http://codereview.chromium.org/8665011/diff/5001/chrome/browser/sync/sync_setup_flow.cc File chrome/browser/sync/sync_setup_flow.cc ...
9 years, 1 month ago (2011-11-24 03:59:42 UTC) #4
Andrew T Wilson (Slow)
http://codereview.chromium.org/8665011/diff/5001/chrome/browser/sync/sync_setup_flow.cc File chrome/browser/sync/sync_setup_flow.cc (right): http://codereview.chromium.org/8665011/diff/5001/chrome/browser/sync/sync_setup_flow.cc#newcode107 chrome/browser/sync/sync_setup_flow.cc:107: prefs::kGoogleServicesUsername)); OK, if you're saying the user always has ...
9 years, 1 month ago (2011-11-24 17:14:08 UTC) #5
tim (not reviewing)
Addressed comments, I kind of took the lazy way to refactor into ProfileSyncServiceMock, but let ...
9 years ago (2011-12-01 08:03:19 UTC) #6
Andrew T Wilson (Slow)
LGTM with a couple of nits. http://codereview.chromium.org/8665011/diff/12001/chrome/browser/sync/sync_ui_util.cc File chrome/browser/sync/sync_ui_util.cc (right): http://codereview.chromium.org/8665011/diff/12001/chrome/browser/sync/sync_ui_util.cc#newcode140 chrome/browser/sync/sync_ui_util.cc:140: string16 label; Do ...
9 years ago (2011-12-01 23:08:07 UTC) #7
tim (not reviewing)
Thanks. Fixed some tests that were added on rebase, will give 'em a whirl at ...
9 years ago (2011-12-02 02:19:58 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tim@chromium.org/8665011/16001
9 years ago (2011-12-02 04:07:07 UTC) #9
commit-bot: I haz the power
9 years ago (2011-12-02 05:25:40 UTC) #10
Change committed as 112643

Powered by Google App Engine
This is Rietveld 408576698