Previous Page Arrow Next Page Arrow

4.3 Per-resource Synchronization State

In a synchronization feed, every resource entry carries a special payload describing its synchronization state. This payload will typically look like:

<syncState xmlns="http://schemas.sage.com/sdata/sync/2008/1">
  <endpoint>http://www.example.com/sdata/myApp1/myContract/-/accounts</endpoint>
  <tick>6</tick>
  <stamp>2008-05-25T14:52:03.281Z</stamp>
  <user>john.doe@acme.com</user>
</syncState>

The elements of this synchronization payload are described in the following table:

Element Type Description Example
endpoint URL URL of the synchronization endpoint where the resource was last modified (created, updated or deleted). http://www.example.com/sdata/myApp1/myContract/-/accounts
tick integer Tick at the endpoint when the resource was last modified. 6
stamp timestamp Datetime at which the resource was last modified. 2008-05-25T14:52:03.281Z
user string Identification of the user who last modified the resource (optional) john.doe@acme.com
A provider exposing a resource kind for synchronization MUST provide, in response to operations on the $syncSource and $syncTarget operations, a feed containing for each entry the syncState of the entry in the format described above.
The provider MUST furthermore ensure that the information presented in the synchronization state conforms to the following restrictions:
The pair (endpoint, tick) is unique
For every endpoint, the maximum of the corresponding tick values is less than or equal to the values exposed in the $syncDigest result

Previous Page Arrow Next Page Arrow