Device connectivity analysis¶
Results¶
Envoy Mobile currently handles switching preferred networks between wifi/cellular based on reachability updates from the OS. After switching to a new preferred network, all future requests made through the library will use the new connection.
iOS¶
The above approach has proven successful for unary requests, but has been problematic for long-lived streams due to the fact that the library does not aggressively shut down these streams when the preferred network changes, causing them to sometimes hang until they time out.
Android¶
We did not observe any issues when switching between background/foreground or between wifi/cellular.
Experimentation method¶
Modified versions of the “hello world” example apps were used to run the following experiments, validating that the library is able to continue making successful requests after each change.
Lifecycle experiment steps:
Open the example application
Background the application
Foreground the application
Network experimentation steps:
Turn on wifi
Open the example application
Turn off wifi
Turn on wifi
Turn on airplane mode
Turn off airplane mode
iOS configuration¶
Build the library with debugging symbols (using
--copt=-ggdb3
)Add the outputted
Envoy.framework
to the example appIn the active scheme of the app’s Xcode
Environment Variables
, setCFNETWORK_DIAGNOSTICS=3
to enable more verboseCFNetwork
logsSet Envoy’s logs to
trace
Android configuration¶
Build the library
Build and run the example app:
./bazelw mobile-install //examples/kotlin/hello_world:hello_envoy_kt --fat_apk_cpu=armeabi-v7a
Open issues¶
For current issues with device conditions, please see issues with the perf/device label.