Smart Devices offline applications architecture

Official Content
This documentation is valid for:

The Offline Smart Devices applications architecture has to consider two situations where this apps should work: when the application is disconnected and when it has a connection. In the first case, the app has to be able to process data and interact with a database without a network connection. In the second scenario the app can synchronize data with the server by invoking web services.

Connected or not, all the processing of the application is done on the device updating the local database. Once the connection is restored, a synchronization will be executed.



An Offline Application can be splitted into two components: a local component and a server component.
The server may have a backend for the application, the database, and a services layer for data synchronization with the devices.
On the devices, the applications also has a database with a subset of the server data, and all the logic that needs to be executed locally. That logic is written in native code of the device (Objective-c/Swift for iOS, Java for Android, etc). The application has also all the metadata required for the UI layout and user events.

Both components (device and server) communicate via REST services to perform the required synchronization to fill the local database and to send the modifications performed on the device to the server.

The comunication between the Smart Device application and the server is known as synchronization.

Advanced concepts

Read the Advanced Concepts of Offline Applications architecture document to learn more about the Offline applications architecture.