diff options
author | rlarocque@chromium.org <rlarocque@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-04 02:51:36 +0000 |
---|---|---|
committer | rlarocque@chromium.org <rlarocque@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-04 02:51:36 +0000 |
commit | a95754871e9e86ee503c46d12e8704c02f6c6e35 (patch) | |
tree | 92be09176ae15cd5e02595e3586db4f4d2026499 /sync/internal_api/public/util | |
parent | 01e117df184677e024d7f4f17fee7fdfeb1e4053 (diff) | |
download | chromium_src-a95754871e9e86ee503c46d12e8704c02f6c6e35.zip chromium_src-a95754871e9e86ee503c46d12e8704c02f6c6e35.tar.gz chromium_src-a95754871e9e86ee503c46d12e8704c02f6c6e35.tar.bz2 |
sync: Per-type update application
This change moves the update application functionality from the
ApplyUpdatesAndResolveConflictsCommand into the
SyncDirectoryUpdateHandler class. This change will allow us to
implement update application differently for different types.
Because update application happens on the model threads, the
ApplyUpdatesAndResolveConflictsCommand had to be aware of
ModelSafeRoutingInfo, ModelSafeWorkers, and other concepts intended to
hide threading details. The new code takes a different approach. It
hides the threading details specific to each type inside its
SyncDirectoryUpateHandler by initializing it with a scoped_refptr to its
associated ModelSafeWorker.
The ApplyUpdatesAndResolveConflictsCommand was the last SyncerCommand.
With its removal, we can also remove the definitions of SyncerCommand,
ModelChangingSyncerCommand and SyncerCommandTest.
BUG=278484
Review URL: https://codereview.chromium.org/72403003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@238532 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'sync/internal_api/public/util')
-rw-r--r-- | sync/internal_api/public/util/syncer_error.h | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/sync/internal_api/public/util/syncer_error.h b/sync/internal_api/public/util/syncer_error.h index 471bc7e..db59b7d 100644 --- a/sync/internal_api/public/util/syncer_error.h +++ b/sync/internal_api/public/util/syncer_error.h @@ -9,15 +9,7 @@ namespace syncer { -// This enum describes all the ways a SyncerCommand can fail. -// -// SyncerCommands do many different things, but they share a common function -// signature. This enum, the return value for all SyncerCommands, must be able -// to describe any possible failure for all SyncerComand. -// -// For convenience, functions which are invoked only by SyncerCommands may also -// return a SyncerError. It saves us having to write a conversion function, and -// it makes refactoring easier. +// This enum describes all the possible results of a sync cycle. enum SYNC_EXPORT_PRIVATE SyncerError { UNSET = 0, // Default value. CANNOT_DO_WORK, // A model worker could not process a work item. |