azure-sdk-for-android
azure-sdk-for-android copied to clipboard
[FEATURE REQ] callAgent.addOnConnectionStateChangedListener()
Is your feature request related to a problem? Please describe.
If the call agent is no longer connected to Azure, there's currently no event in the Android calling SDK. This means we have no idea if the call agent needs to be disposed and re-created. Please add an event to inform us of when the call agent disconnects.
Describe the solution you'd like
callAgent.addOnConnectionStateChangedListener {
Log.i(TAG, "Connection state of call agent changed from ${it.oldValue} to ${it.newValue} with reason ${it.reason}")
}
Describe alternatives you've considered
Restart the call agent periodically, in case it silently disconnected.
Additional context
The latest beta 1.15.1-beta.1 for the JS calling SDK added callAgent.on('connectionStateChanged');
. Is this planned for the Android SDK as well?
Information Checklist
Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report
- [x] Description Added
- [x] Expected solution specified