Hi Stefan, currently I can't recommend an "out of the box" solution.
The most promising path are the upcoming Cordova Plugin integration tools and all cordova plugins which offer "background" upload/download capabilities.
Namely this plugin
https://github.com/spoonconsulting/cordova-plugin-background-upload and this plugin
https://github.com/sgrebnov/cordova-plugin-background-download/blob/master/src/ios/BackgroundDownload.m are plugins dealing under IOS with the "NSURLSession" API
https://developer.apple.com/documentation/foundation/nsurlsession?language=objcwhich ensures upload/download "out of process" by the system networking daemon.
So regardless if your GMI process is in the foreground or background using this API ensures that uploads/downloads continue.
I can't estimate if on Android the same happens (need to ask my GMA colleague)
For the download plugin I already made a sample for GMI 1.30.06
(Are you in the 3.10 Genero-EAP ?) downloadable from
https://www.generomobile.de/gmi/cdvdownload.zipFor the upload I need to check if the upload plugin is already usable in GMI.
If none of the plugins are fitting your purpose then there is also the possibility adding a custom frontcall in GMI/GMA using the appropriate system APIs . This could be done already for the released GM 1.20.
I can only warn to use
ON IDLE 1
to do networks syncs.
1. this will make you unhappy because this needs to be implanted in each possible DIALOG the user enters and will hence lead to code pollution.
2. If you are in INPUT statements you may run into focus and validation issues
(reminder: ON IDLE flushes the current field, if you are in an INTEGER field and type accidentally "a" then you get an unwanted validation error and your end users will be irritated)
3. It won't work anyway if your app is a longer time in the background (at least on IOS).
As mentioned my comments are pretty IOS centric, but I guess the Android answer will be similar
Regards, Leo