aws-amplify / aws-sdk-android

AWS SDK for Android. For more information, see our web site:
https://docs.amplify.aws
Other
1.02k stars 548 forks source link

TransferNetworkConnectionType.MOBILE doesn't work when WiFi is connected on "no internet" network (API 25) #3531

Open draskori opened 4 months ago

draskori commented 4 months ago

I need to be connected on WiFi network which has no internet gateaway and to communicate through mobile connection with server and S3 uploads. When I specify TransferNetworkConnectionType.MOBILE in TransferUtility, observers get status WAITING_FOR_NETWORK and doesn't start (even if I turn off WiFi after that). If WiFi is off when starting uploads then it works ok. On higher Android levels (Android 10+) it works ok.

tylerjroach commented 4 months ago

Hi @draskori,

Older versions of Android OS were not as intelligent as newer versions in managing multiple network connection types. If you were on WIFI, there are limitations around managing a cellular connection as well. More recent versions of Android are able to gracefully handle this.

I'll try and see what Android OS documentation I can find on this. However, it is unexpected that even after turning WIFI off, the upload wont begin. Someone on our team will try to replicate.