Simple and easy to implementIt works in a similar way to the Outsystems ‘Read-Only Optimized Sync Pattern’, but implemented in such a way that the sync is bidirectional (read/write).
Data optimizedThis read-write sync pattern only downloads the delta from the server (all the read-write patterns on the outsystems documentation download all the server data on each sync)
No need to remap primary keys when syncing with serverNormally, in order to avoid clashes, records created client side will need to have their primary key reassigned when syncing to the server. Because we are using a Guid this is not an issue, and the keys can be the same on local and server entities.
No need to remap foreign keys when syncing with serverBecause no primary keys are changed when syncing, also the foreign keys don’t need to be remapped.
Uses client-side guid generationIn order to use the same keys on local and server records we need to ensure that the keys are unique, even when generated on an offline mobile device. This is achieved by the use of a unique guid, created on the fly on the mobile device.
Timezone friendlyEven though the sync is using timestamps it will work perfectly across multiple timezones. This is intrinsic to the way Reactive and Mobile outsystems apps handle and store timezones, and no extra code or adjustments need to be done.
Dependencies updated