When developing mobile software solutions, one of the primary considerations is the most efficient way in which to synchronize production data. While all client-server systems must account for this, mobile software development presents its own set of challenges, which stem from the almost universal truth that, at some point, mobile users will need to work in a disconnected environment.
Users will not always be connected, and in many cases will spend most of their day without network connectivity. Therefore, when users do synchronize their clients, information must be resolved concerning what data a user needs. It can be extremely inefficient to attempt to retrieve all production data during synchronization. Most production applications contain large amounts of data stored on the client devices and attempting to retrieve everything during synchronization can result in long delays during the synchronization process. This is unnecessary in most environments, as much of the production data stored on the client is likely to still be current and accurate as compared to the data in the back end system.
An Agentry application project accounts for this within its structure. The architecture of all synchronization components allows the developer to be far more selective about what data needs to be retrieved during the synchronization process. The method recommended by Syclo is called the Exchange Data Model.
Exchange data is the term used to refer to information about what production data the client has and when it was last retrieved, as well as the data contained in the back end system and when it was last modified. With this information available the developer can implement synchronization processes that only retrieve information that has been modified since the last time a client synchronized with the Server. Any unchanged data is not retrieved. This model will result in quicker and more efficient synchronization for users, as well as reducing the amount of resources needed by the system as a whole during the synchronization process. All data definition types and their related synchronization components allow for and are intended to be used in an exchange data model.
For the date and time of data retrieval on the clients, the synchronization processing within Agentry provides the ability to retrieve, store and access the client-side information about when data was last retrieved. Objects, complex tables and data tables all have the ability to store what is called the “last update” value that represents the date and time data was retrieved.
For date and time values related to changes made on the back end system, mechanisms must exist or be added for the mobile application to track changes to data that occur in between users’ synchronizations.
The specific methods and mechanisms for accomplishing the above tasks will differ as a result of a combination of different factors that include the type of production data being synchronized (objects, complex tables, or data tables), the type of back end system in use, the capabilities of a specific back end system, the specific needs of a given application, and the specific needs of an implementation of a given application.
Regardless of the technical details of how the above steps are accomplished, the following summary of the exchange data model holds true. Begin by determining what the client has and when it received it. Next use this information to determine what is different in the back end system and when it was changed. Finally, retrieve only the data which is different on the back end. Any other data in the back end system can be ignored as it has not been modified and therefore is accurate and still current on the client.