After we upgraded from 2.6.1 to 2.7.0, when using connect with autoConnect true, devices are not reconnecting after the first disconnection.
We use client and server with clientManager.useServer(serverManager)
After debugging what I understand is happening in our code is :
In 2.6.1 :
On disconnection, server manager onConnectionStateChangedis triggered
It does not callnotifyDeviceDisconnectedin this version
client manager onConnectionStateChangedis triggered.
This set the variable wasConnectedto the value of connectedwhich is truecallsinternalConnectbecause wasConnectedis true and that will make the device autoconnect in the future
In 2.7.0
On disconnection, server manager onConnectionStateChangedis triggered
This now callsnotifyDeviceDisconnectedthat sets connectedto false
client manager onConnectionStateChangedis triggered.
This set the variable wasConnectedto the value of connectedwhich is falseDoes not callinternalConnectbecause wasConnectedis false and that will not make the device autoconnect in the future
Is this a bug, or are we using the library wrong in some way ?
Hi,
After we upgraded from 2.6.1 to 2.7.0, when using connect with autoConnect true, devices are not reconnecting after the first disconnection.
We use client and server with
clientManager.useServer(serverManager)
After debugging what I understand is happening in our code is :In 2.6.1 : On disconnection, server manager
onConnectionStateChanged
is triggered It does not callnotifyDeviceDisconnected
in this version client manageronConnectionStateChanged
is triggered. This set the variablewasConnected
to the value ofconnected
which is true callsinternalConnect
becausewasConnected
is true and that will make the device autoconnect in the futureIn 2.7.0 On disconnection, server manager
onConnectionStateChanged
is triggered This now callsnotifyDeviceDisconnected
that setsconnected
to false client manageronConnectionStateChanged
is triggered. This set the variablewasConnected
to the value ofconnected
which is false Does not callinternalConnect
becausewasConnected
is false and that will not make the device autoconnect in the futureIs this a bug, or are we using the library wrong in some way ?
Thanks.