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

Issue 23809005: sync: Implement per-type GetCommitIds (Closed)

Created:
7 years, 3 months ago by rlarocque
Modified:
7 years, 3 months ago
CC:
chromium-reviews, tim+watch_chromium.org, rsimha+watch_chromium.org, haitaol+watch_chromium.org
Visibility:
Public.

Description

sync: Implement per-type GetCommitIds Convert the SyncerCommand GetCommitIdsCommand into a function named GetCommitIds that serves the same purpose. There was no benefit in keeping this functionality in a SyncerCommand, and doing so would have made the implementation of a per-type GetCommitIds more difficult. Expose a function to get the IDs to commit for a single data type. This function is used in the implementation of GetCommitIdsCommand, but nowhere else. It will become more useful when we try to implement the model type abstraction layer. BUG=278484 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=222234

Patch Set 1 #

Patch Set 2 : Fix include order #

Patch Set 3 : Comments + algorithm improvements #

Total comments: 17

Patch Set 4 : Address comments; hide some functions in empty namespace #

Patch Set 5 : Rearrange the header file #

Patch Set 6 : Remove unnecessary whitespace #

Total comments: 9

Patch Set 7 : Address Tim's comments #

Total comments: 7

Patch Set 8 : Fix some nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+278 lines, -671 lines) Patch
M sync/engine/commit.cc View 2 chunks +3 lines, -6 lines 0 comments Download
A sync/engine/get_commit_ids.h View 1 2 3 4 5 6 1 chunk +56 lines, -0 lines 0 comments Download
A + sync/engine/get_commit_ids.cc View 1 2 3 4 5 6 7 13 chunks +202 lines, -91 lines 0 comments Download
D sync/engine/get_commit_ids_command.h View 1 chunk +0 lines, -140 lines 0 comments Download
D sync/engine/get_commit_ids_command.cc View 1 chunk +0 lines, -424 lines 0 comments Download
M sync/engine/syncer_unittest.cc View 1 2 3 4 chunks +15 lines, -8 lines 0 comments Download
M sync/sync_core.gypi View 1 chunk +2 lines, -2 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
rlarocque
Please review. https://codereview.chromium.org/23809005/diff/8001/sync/engine/get_commit_ids.cc File sync/engine/get_commit_ids.cc (right): https://codereview.chromium.org/23809005/diff/8001/sync/engine/get_commit_ids.cc#newcode213 sync/engine/get_commit_ids.cc:213: std::set<int64> added_handles_; This member is not really ...
7 years, 3 months ago (2013-09-05 18:33:48 UTC) #1
Nicolas Zea
https://codereview.chromium.org/23809005/diff/8001/sync/engine/get_commit_ids.cc File sync/engine/get_commit_ids.cc (right): https://codereview.chromium.org/23809005/diff/8001/sync/engine/get_commit_ids.cc#newcode174 sync/engine/get_commit_ids.cc:174: bool AddUncommittedParentsAndTheirPredecessors( make these methods private? https://codereview.chromium.org/23809005/diff/8001/sync/engine/get_commit_ids.cc#newcode207 sync/engine/get_commit_ids.cc:207: void ...
7 years, 3 months ago (2013-09-05 23:55:36 UTC) #2
rlarocque
Patch updated. PTAL. https://codereview.chromium.org/23809005/diff/8001/sync/engine/get_commit_ids.cc File sync/engine/get_commit_ids.cc (right): https://codereview.chromium.org/23809005/diff/8001/sync/engine/get_commit_ids.cc#newcode174 sync/engine/get_commit_ids.cc:174: bool AddUncommittedParentsAndTheirPredecessors( On 2013/09/05 23:55:37, Nicolas ...
7 years, 3 months ago (2013-09-06 18:58:26 UTC) #3
tim (not reviewing)
https://codereview.chromium.org/23809005/diff/28001/sync/engine/get_commit_ids.cc File sync/engine/get_commit_ids.cc (right): https://codereview.chromium.org/23809005/diff/28001/sync/engine/get_commit_ids.cc#newcode82 sync/engine/get_commit_ids.cc:82: DVLOG(1) << "Debug commit batch result:" << (*out)[i]; nit ...
7 years, 3 months ago (2013-09-08 19:48:20 UTC) #4
rlarocque
Addressed comments. PTAL. https://codereview.chromium.org/23809005/diff/28001/sync/engine/get_commit_ids.cc File sync/engine/get_commit_ids.cc (right): https://codereview.chromium.org/23809005/diff/28001/sync/engine/get_commit_ids.cc#newcode82 sync/engine/get_commit_ids.cc:82: DVLOG(1) << "Debug commit batch result:" ...
7 years, 3 months ago (2013-09-09 17:41:29 UTC) #5
Nicolas Zea
LGTM with nits https://codereview.chromium.org/23809005/diff/36001/sync/engine/get_commit_ids.cc File sync/engine/get_commit_ids.cc (right): https://codereview.chromium.org/23809005/diff/36001/sync/engine/get_commit_ids.cc#newcode30 sync/engine/get_commit_ids.cc:30: void FilterUnreadyEntries( I think it's useful ...
7 years, 3 months ago (2013-09-09 17:58:15 UTC) #6
rlarocque
https://codereview.chromium.org/23809005/diff/36001/sync/engine/get_commit_ids.cc File sync/engine/get_commit_ids.cc (right): https://codereview.chromium.org/23809005/diff/36001/sync/engine/get_commit_ids.cc#newcode30 sync/engine/get_commit_ids.cc:30: void FilterUnreadyEntries( On 2013/09/09 17:58:15, Nicolas Zea wrote: > ...
7 years, 3 months ago (2013-09-09 18:36:25 UTC) #7
tim (not reviewing)
lgtm
7 years, 3 months ago (2013-09-09 22:38:06 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rlarocque@chromium.org/23809005/45001
7 years, 3 months ago (2013-09-09 22:41:44 UTC) #9
commit-bot: I haz the power
7 years, 3 months ago (2013-09-10 09:10:57 UTC) #10
Message was sent while issue was closed.
Change committed as 222234

Powered by Google App Engine
This is Rietveld 408576698