> I’m building a client for sync storage 1.5 and I am wondering about the exact > behavior of a client if a changed syncID in the Metaglobal Record is detected. > Is the client supposed to drop all local data? The documentation just talks > about 'cached data’.
When the syncID changes (either global or per-collection), the client should drop any sync-related metadata it has for that collection — e.g., last sync timestamps — and sync it from scratch. It should not delete local data. The reason why is somewhat obvious, if you think about it — one of the situations in which a syncID changes is when the server is wiped, and the user would probably be upset if that also discarded all of their local data, leaving them with nothing. A syncID change should essentially follow the same code path as a first sync: download all records, reconcile them against local data, upload anything that conflicted or wasn’t present so that the server and the local client agree. > Another question: According to the documentation about the object formats, > the client record has > a field ‚commands‘. Is there documentation about the possible commands? Your best reference is one of the existing implementations. These are handily summarized here: http://mxr.mozilla.org/mozilla-central/source/services/sync/modules/engines/clients.js#187 The desktop Sync UI for Sync 1.5 doesn’t expose resetting (Bug 978574), nor do any clients meaningfully expose logout, so you should start with displayURI. _______________________________________________ Sync-dev mailing list [email protected] https://mail.mozilla.org/listinfo/sync-dev

