summaryrefslogtreecommitdiffstats
path: root/sync/internal_api/README
diff options
context:
space:
mode:
authorakalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-21 09:59:42 +0000
committerakalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-21 09:59:42 +0000
commit91835ca82c6ff7f1aeb68e314a3842da1aca6841 (patch)
treec7e8119bd0fb2a8e1d6910c969e1d3f62dbff1f8 /sync/internal_api/README
parent7983f3bae6ab9c86aea81816e6bb1bd15ab114fe (diff)
downloadchromium_src-91835ca82c6ff7f1aeb68e314a3842da1aca6841.zip
chromium_src-91835ca82c6ff7f1aeb68e314a3842da1aca6841.tar.gz
chromium_src-91835ca82c6ff7f1aeb68e314a3842da1aca6841.tar.bz2
[Sync] Move 'syncapi_core' and 'sync_unit_tests' targets to sync/
Also move related test files. Lock down deps for sync/internal_api. Clean up some deps on chrome/browser/sync. BUG=117585 TEST= Review URL: https://chromiumcodereview.appspot.com/10147003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@133349 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'sync/internal_api/README')
-rw-r--r--sync/internal_api/README32
1 files changed, 32 insertions, 0 deletions
diff --git a/sync/internal_api/README b/sync/internal_api/README
new file mode 100644
index 0000000..32987bb
--- /dev/null
+++ b/sync/internal_api/README
@@ -0,0 +1,32 @@
+This file defines the "sync API", an interface to the syncer
+backend that exposes (1) the core functionality of maintaining a consistent
+local snapshot of a hierarchical object set; (2) a means to transactionally
+access and modify those objects; (3) a means to control client/server
+synchronization tasks, namely: pushing local object modifications to a
+server, pulling nonlocal object modifications from a server to this client,
+and resolving conflicts that may arise between the two; and (4) an
+abstraction of some external functionality that is to be provided by the
+host environment.
+
+This interface is used as the entry point into the syncer backend
+when the backend is compiled as a library and embedded in another
+application. A goal for this interface layer is to depend on very few
+external types, so that an application can use the sync backend
+without introducing a dependency on specific types. A non-goal is to
+have binary compatibility across versions or compilers; this allows the
+interface to use C++ classes. An application wishing to use the sync API
+should ideally compile the syncer backend and this API as part of the
+application's own build, to avoid e.g. mismatches in calling convention,
+structure padding, or name mangling that could arise if there were a
+compiler mismatch.
+
+The schema of the objects in the sync domain is based on the model, which
+is essentially a hierarchy of items and folders similar to a filesystem,
+but with a few important differences. The sync API contains fields
+such as URL to easily allow the embedding application to store web
+browser bookmarks. Also, the sync API allows duplicate titles in a parent.
+Consequently, it does not support looking up an object by title
+and parent, since such a lookup is not uniquely determined. Lastly,
+unlike a filesystem model, objects in the Sync API model have a strict
+ordering within a parent; the position is manipulable by callers, and
+children of a node can be enumerated in the order of their position.