I have a requirement to trigger background syncing of local storage data to server in mobile application whenever device comes online, irrespective of whether the application is open or not.
Can we do it in OutSystems, if possible please share the solution approach
Hey, let's split these 2 behaviors.
Trigger background sync when the application is open and the device gets online should be relatively easy. This a configuration that you need to check (below is an action on the skeleton of a mobile app):
Regarding the sync when the application is in the background is a completely different story and it is not supported out of the box by OutSystems. I've tried a few times before but the behavior is not consistent, due to the different versions of the mobile OS (multiple versions of Android, and iOS).
I would suggest a different approach and deeply try to understand if you can implement something else, like a notification saying that the user has pending updates, for example. Try to use the Pareto principle (80/20)
Regards