Hello everybody, we have the following situation:
Is there a clever way built into MobiLink to check from the mobile device if we can reach the server? Thanks for your help and best regards, Alex |
Both dbmlsync and UltraLite have a synchronization parameter you can use called "Ping". No data will be exchanged in the synchronization, and no changes will be made to the progress values, but the MobiLink client will connect to the ML Server and authenticate. http://dcx.sap.com/index.html#sqla170/en/html/8270a6956ce210149fbe87a85693bed4.html Alternatively, outside of the MobiLink client, you could simply use TCP/IP to attempt to connect to the socket where the ML Server is running. If the TCP/IP socket connect is successful, you know that you can reach the ML Server from the client and that "some" process is listening on the port where you expect the ML Server to be running. This is a cheaper option, but makes your device look a bit like a port scanner, so the firewall might get upset at you and block the device. Reg 1
For Android, use the UltraLiteJ SyncParms.setPingOnly(). This pings the server but does not perform a sync.
(13 Jun '18, 09:11)
Chris Keating
Hello guys, thank you for the suggestion. We tried this and it works just fine on iOS, where we get a success or failure almost instantly. On Android however it takes 75 seconds for the ping to return in case the server can not be reached. Setting the timout parameter does not change this. Are we doing something wrong or is there a bug with the Android implementation? Thanks and best regards, Alex
(18 Jun '18, 07:18)
Alexander Ilg
|