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

Issue 10704214: [Sync] Refactor sync manager into interface. (Closed)

Created:
8 years, 5 months ago by Nicolas Zea
Modified:
8 years, 5 months ago
CC:
chromium-reviews, Raghu Simha, ncarter (slow), pam+watch_chromium.org, akalin, tim (not reviewing)
Visibility:
Public.

Description

[Sync] Refactor sync manager into interface. sync_manager.h now defines a pure interface. The actual implementation is in sync_manager_impl.h/cc. In order to support this, we also create a SyncManagerFactory, which allows us to dependency inject a SyncManager implementation into the SyncBackendHost. Follow up patches will make use of this injection, as well as split the SyncManager tests out of syncapi_unittest. R=akalin@chromium.org BUG=133061 TEST= Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=147076

Patch Set 1 #

Patch Set 2 : Self review #

Total comments: 10

Patch Set 3 : Address comments #

Patch Set 4 : FFFFF #

Total comments: 4

Patch Set 5 : Address Comments #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+522 lines, -2836 lines) Patch
M chrome/browser/sync/glue/data_type_manager_impl.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/sync/glue/sync_backend_host.h View 1 5 chunks +8 lines, -1 line 0 comments Download
M chrome/browser/sync/glue/sync_backend_host.cc View 1 9 chunks +13 lines, -7 lines 1 comment Download
M chrome/browser/sync/glue/sync_backend_host_unittest.cc View 2 chunks +3 lines, -0 lines 0 comments Download
M chrome/browser/sync/profile_sync_service.h View 1 2 3 4 3 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/sync/profile_sync_service.cc View 1 2 3 4 3 chunks +11 lines, -6 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_harness.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/sync/test_profile_sync_service.cc View 1 chunk +3 lines, -2 lines 0 comments Download
M sync/internal_api/js_sync_manager_observer.cc View 1 chunk +1 line, -0 lines 0 comments Download
M sync/internal_api/js_sync_manager_observer_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M sync/internal_api/public/sync_manager.h View 8 chunks +49 lines, -104 lines 0 comments Download
A sync/internal_api/public/sync_manager.cc View 1 chunk +19 lines, -0 lines 0 comments Download
A sync/internal_api/public/sync_manager_factory.h View 1 chunk +30 lines, -0 lines 0 comments Download
A sync/internal_api/public/util/sync_string_conversions.h View 1 chunk +20 lines, -0 lines 0 comments Download
A sync/internal_api/public/util/sync_string_conversions.cc View 1 chunk +39 lines, -0 lines 0 comments Download
D sync/internal_api/sync_manager.cc View 1 chunk +0 lines, -2532 lines 0 comments Download
A sync/internal_api/sync_manager_factory.cc View 1 chunk +22 lines, -0 lines 0 comments Download
A sync/internal_api/sync_manager_impl.h View 1 2 1 chunk +128 lines, -0 lines 0 comments Download
A + sync/internal_api/sync_manager_impl.cc View 1 2 61 chunks +141 lines, -171 lines 0 comments Download
M sync/internal_api/syncapi_unittest.cc View 5 chunks +9 lines, -6 lines 0 comments Download
M sync/sync.gyp View 3 chunks +7 lines, -1 line 0 comments Download
M sync/tools/sync_client.cc View 1 2 3 4 chunks +11 lines, -6 lines 0 comments Download

Messages

Total messages: 9 (0 generated)
Nicolas Zea
PTAL
8 years, 5 months ago (2012-07-14 01:49:54 UTC) #1
tim (not reviewing)
drive-by review http://codereview.chromium.org/10704214/diff/3001/sync/internal_api/sync_manager_impl.cc File sync/internal_api/sync_manager_impl.cc (right): http://codereview.chromium.org/10704214/diff/3001/sync/internal_api/sync_manager_impl.cc#newcode314 sync/internal_api/sync_manager_impl.cc:314: void AddObserver(SyncManagerImpl::Observer* observer); SyncManager::Observer is still correct ...
8 years, 5 months ago (2012-07-16 21:25:30 UTC) #2
Nicolas Zea
Addressed overzealous use of Search/Replace. PTAL http://codereview.chromium.org/10704214/diff/3001/sync/internal_api/sync_manager_impl.cc File sync/internal_api/sync_manager_impl.cc (right): http://codereview.chromium.org/10704214/diff/3001/sync/internal_api/sync_manager_impl.cc#newcode314 sync/internal_api/sync_manager_impl.cc:314: void AddObserver(SyncManagerImpl::Observer* observer); ...
8 years, 5 months ago (2012-07-16 21:54:22 UTC) #3
Nicolas Zea
Fixed sync client, NOW PTAL
8 years, 5 months ago (2012-07-16 22:08:10 UTC) #4
tim (not reviewing)
http://codereview.chromium.org/10704214/diff/2003/chrome/browser/sync/profile_sync_service.cc File chrome/browser/sync/profile_sync_service.cc (right): http://codereview.chromium.org/10704214/diff/2003/chrome/browser/sync/profile_sync_service.cc#newcode1203 chrome/browser/sync/profile_sync_service.cc:1203: reason = syncer::CONFIGURE_REASON_NEWLY_ENABLED_DATA_TYPE; Hmm. restart == true doesn't imply ...
8 years, 5 months ago (2012-07-16 23:07:47 UTC) #5
Nicolas Zea
http://codereview.chromium.org/10704214/diff/2003/chrome/browser/sync/profile_sync_service.cc File chrome/browser/sync/profile_sync_service.cc (right): http://codereview.chromium.org/10704214/diff/2003/chrome/browser/sync/profile_sync_service.cc#newcode1203 chrome/browser/sync/profile_sync_service.cc:1203: reason = syncer::CONFIGURE_REASON_NEWLY_ENABLED_DATA_TYPE; On 2012/07/16 23:07:47, timsteele wrote: > ...
8 years, 5 months ago (2012-07-17 00:56:17 UTC) #6
tim (not reviewing)
LGTM http://codereview.chromium.org/10704214/diff/2026/chrome/browser/sync/glue/sync_backend_host.cc File chrome/browser/sync/glue/sync_backend_host.cc (right): http://codereview.chromium.org/10704214/diff/2026/chrome/browser/sync/glue/sync_backend_host.cc#newcode973 chrome/browser/sync/glue/sync_backend_host.cc:973: options.make_http_bridge_factory_fn.Run().Pass(), Ah ha.. I was wondering how this ...
8 years, 5 months ago (2012-07-17 16:11:54 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/zea@chromium.org/10704214/2026
8 years, 5 months ago (2012-07-17 18:10:08 UTC) #8
commit-bot: I haz the power
8 years, 5 months ago (2012-07-17 20:12:17 UTC) #9
Change committed as 147076

Powered by Google App Engine
This is Rietveld 408576698