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

Issue 1851004: Adding sync support for Passwords (Closed)

Created:
10 years, 7 months ago by Zachary Kuznia
Modified:
9 years, 7 months ago
Reviewers:
albertb
CC:
chromium-reviews, Paweł Hajdan Jr., ncarter (slow), idana, tim (not reviewing), ben+cc_chromium.org
Visibility:
Public.

Description

Adding sync support for Passwords BUG=none TEST=none Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=47686

Patch Set 1 #

Patch Set 2 : Added unit tests #

Patch Set 3 : Code review #

Patch Set 4 : Code Review #

Total comments: 58

Patch Set 5 : Code review changes #

Total comments: 2

Patch Set 6 : Rebase #

Patch Set 7 : Code Review changes #

Total comments: 16

Patch Set 8 : Code Review fixes #

Patch Set 9 : Ready for checkin #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1727 lines, -2 lines) Patch
M chrome/browser/sync/engine/model_safe_worker.h View 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/sync/engine/syncapi.h View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/sync/glue/data_type_manager_impl.cc View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_change_processor.h View 1 2 3 4 5 6 1 chunk +79 lines, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_change_processor.cc View 1 2 3 4 5 6 7 1 chunk +213 lines, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_data_type_controller.h View 1 2 3 4 1 chunk +89 lines, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_data_type_controller.cc View 1 2 3 4 5 6 7 1 chunk +144 lines, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_model_associator.h View 1 2 3 4 5 6 7 1 chunk +158 lines, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_model_associator.cc View 1 2 3 4 5 6 7 1 chunk +402 lines, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_model_worker.h View 5 6 7 1 chunk +43 lines, -0 lines 0 comments Download
A chrome/browser/sync/glue/password_model_worker.cc View 1 chunk +41 lines, -0 lines 0 comments Download
M chrome/browser/sync/glue/sync_backend_host.h View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/sync/glue/sync_backend_host.cc View 5 6 7 3 chunks +8 lines, -2 lines 0 comments Download
M chrome/browser/sync/profile_sync_factory.h View 2 chunks +9 lines, -0 lines 0 comments Download
M chrome/browser/sync/profile_sync_factory_impl.h View 1 2 3 4 5 6 7 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/browser/sync/profile_sync_factory_impl.cc View 1 2 3 4 5 6 7 4 chunks +29 lines, -0 lines 0 comments Download
M chrome/browser/sync/profile_sync_factory_mock.h View 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/browser/sync/profile_sync_service.cc View 2 3 4 5 6 7 2 chunks +3 lines, -0 lines 0 comments Download
A chrome/browser/sync/profile_sync_service_password_unittest.cc View 1 2 3 4 5 6 7 8 1 chunk +472 lines, -0 lines 0 comments Download
M chrome/browser/sync/syncable/syncable.cc View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 6 7 8 1 chunk +8 lines, -0 lines 0 comments Download
M chrome/chrome_tests.gypi View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M chrome/common/chrome_switches.h View 1 2 3 4 5 6 7 8 2 chunks +2 lines, -0 lines 0 comments Download
M chrome/common/chrome_switches.cc View 1 2 3 4 5 6 7 8 2 chunks +6 lines, -0 lines 0 comments Download
M chrome/common/pref_names.h View 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M chrome/common/pref_names.cc View 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M chrome/test/profile_mock.h View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
Zachary Kuznia
10 years, 7 months ago (2010-05-06 22:00:06 UTC) #1
Zachary Kuznia
10 years, 7 months ago (2010-05-06 22:16:37 UTC) #2
albertb
Wow, there is an absurd amount of boilerplate code to simply sync a new data ...
10 years, 7 months ago (2010-05-07 00:13:06 UTC) #3
Zachary Kuznia
http://codereview.chromium.org/1851004/diff/8001/9002 File chrome/browser/password_manager/password_store.h (right): http://codereview.chromium.org/1851004/diff/8001/9002#newcode20 chrome/browser/password_manager/password_store.h:20: namespace browser_sync { On 2010/05/07 00:13:07, albertb wrote: > ...
10 years, 7 months ago (2010-05-11 18:04:17 UTC) #4
albertb
http://codereview.chromium.org/1851004/diff/8001/9008 File chrome/browser/sync/glue/password_change_processor.cc (right): http://codereview.chromium.org/1851004/diff/8001/9008#newcode36 chrome/browser/sync/glue/password_change_processor.cc:36: notification_service_.reset(new NotificationService); On 2010/05/11 18:04:17, zork wrote: > On ...
10 years, 7 months ago (2010-05-12 15:26:12 UTC) #5
Zachary Kuznia
http://codereview.chromium.org/1851004/diff/8001/9008 File chrome/browser/sync/glue/password_change_processor.cc (right): http://codereview.chromium.org/1851004/diff/8001/9008#newcode36 chrome/browser/sync/glue/password_change_processor.cc:36: notification_service_.reset(new NotificationService); If we don't need it on Mac, ...
10 years, 7 months ago (2010-05-12 21:53:54 UTC) #6
albertb
10 years, 7 months ago (2010-05-18 20:51:59 UTC) #7
64 bytes from albertb@chromium.org (74.125.19.147): icmp_seq=1 ttl=57 time=2h20m

LGTM with a few nits and with caveat that Mac will be broken if the Keychain is
setup to prompt the user.

http://codereview.chromium.org/1851004/diff/34001/25005
File chrome/browser/sync/glue/password_change_processor.cc (right):

http://codereview.chromium.org/1851004/diff/34001/25005#newcode32
chrome/browser/sync/glue/password_change_processor.cc:32:
DCHECK(!ChromeThread::CurrentlyOn(ChromeThread::UI));
nit- You could check that you're on the DB thread on Windows and Linux.

http://codereview.chromium.org/1851004/diff/34001/25005#newcode48
chrome/browser/sync/glue/password_change_processor.cc:48: LOG(INFO) << "Observed
password change.";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25005#newcode68
chrome/browser/sync/glue/password_change_processor.cc:68: {
nit- Shouldn't the { go on the previous line with everything inside indented
back two spaces?

http://codereview.chromium.org/1851004/diff/34001/25007
File chrome/browser/sync/glue/password_data_type_controller.cc (right):

http://codereview.chromium.org/1851004/diff/34001/25007#newcode37
chrome/browser/sync/glue/password_data_type_controller.cc:37: LOG(INFO) <<
"Starting password data controller.";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25007#newcode56
chrome/browser/sync/glue/password_data_type_controller.cc:56: LOG(INFO) <<
"Stopping password data type controller.";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25007#newcode72
chrome/browser/sync/glue/password_data_type_controller.cc:72: LOG(INFO) <<
"Password data type controller StartImpl called.";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25007#newcode105
chrome/browser/sync/glue/password_data_type_controller.cc:105: LOG(INFO) <<
"Password data type controller StartDone called.";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25007#newcode117
chrome/browser/sync/glue/password_data_type_controller.cc:117: LOG(INFO) <<
"Password data type controller StartDoneImpl called.";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25007#newcode125
chrome/browser/sync/glue/password_data_type_controller.cc:125: LOG(INFO) <<
"Password data type controller StopImpl called.";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25009
File chrome/browser/sync/glue/password_model_associator.cc (right):

http://codereview.chromium.org/1851004/diff/34001/25009#newcode36
chrome/browser/sync/glue/password_model_associator.cc:36:
DCHECK(!ChromeThread::CurrentlyOn(ChromeThread::UI));
On Windows and Linux you could check that you're actually on the DB thread.

http://codereview.chromium.org/1851004/diff/34001/25009#newcode40
chrome/browser/sync/glue/password_model_associator.cc:40: LOG(INFO) <<
"Associating Password Models";
nit- Remove this.

http://codereview.chromium.org/1851004/diff/34001/25010
File chrome/browser/sync/glue/password_model_associator.h (right):

http://codereview.chromium.org/1851004/diff/34001/25010#newcode46
chrome/browser/sync/glue/password_model_associator.h:46: // We do not check if
we have local data before this run; we always
"before this runs"

http://codereview.chromium.org/1851004/diff/34001/25012
File chrome/browser/sync/glue/password_model_worker.h (right):

http://codereview.chromium.org/1851004/diff/34001/25012#newcode23
chrome/browser/sync/glue/password_model_worker.h:23: // from the syncapi that
need to be fulfilled on the password thread.
nit- DB thread on Windows and Linux

http://codereview.chromium.org/1851004/diff/34001/25013
File chrome/browser/sync/glue/sync_backend_host.cc (right):

http://codereview.chromium.org/1851004/diff/34001/25013#newcode91
chrome/browser/sync/glue/sync_backend_host.cc:91: new PasswordModelWorker(
nit- Indent two more

http://codereview.chromium.org/1851004/diff/34001/25020
File chrome/browser/sync/profile_sync_service_password_unittest.cc (right):

http://codereview.chromium.org/1851004/diff/34001/25020#newcode111
chrome/browser/sync/profile_sync_service_password_unittest.cc:111:
notification_service_ = new ThreadNotificationService(&db_thread_);
I don't see any trybot results for your patch. Do those tests pass on Mac?

http://codereview.chromium.org/1851004/diff/34001/25020#newcode194
chrome/browser/sync/profile_sync_service_password_unittest.cc:194:
std::vector<PasswordForm>* entries) {
nit- Fix indentation.

Powered by Google App Engine
This is Rietveld 408576698