[Sync] Implement support for untracking new entities

Desktop / Chromium - gangwu [chromium.org] - 16 June 2017 13:51 EDT

This is a follow up CL for https://codereview.chromium.org/2915763005. The CL above let processor can obtain storage key during bridge merge/apply, but some entities maybe expired and bridge do not want to persist them, so this CL add a function called UntrackEntity in processor to let processor to remove tracker for those entities.

BUG=719570

Review-Url: https://codereview.chromium.org/2935583002 Cr-Commit-Position: refs/heads/master@{#480096}

20065cf [Sync] Implement support for untracking new entities
.../sync/model/fake_model_type_change_processor.cc | 3 ++
.../sync/model/fake_model_type_change_processor.h | 1 +
.../sync/model/fake_model_type_sync_bridge.cc | 13 ++++++--
.../sync/model/fake_model_type_sync_bridge.h | 7 ++++
.../sync/model/model_type_change_processor.h | 8 +++++
.../sync/model_impl/shared_model_type_processor.cc | 11 +++++++
.../sync/model_impl/shared_model_type_processor.h | 1 +
.../shared_model_type_processor_unittest.cc | 37 ++++++++++++++++++++--
.../sync/test/engine/mock_model_type_worker.cc | 12 +++++++
.../sync/test/engine/mock_model_type_worker.h | 7 ++++
10 files changed, 96 insertions(+), 4 deletions(-)

Upstream: git.chromium.org


  • Share