Closed tmahmood-microsoft closed 1 year ago
/azp run
Updated and unhooking the message processor as a part of the transport handler's disconnection detection block.
What scenarios did you test for this? Can we add some tests so that we don't regress in the future? For a unit test you could set up a mock client and trigger the disconnection event handler. Then, verify that the message processor handler was unhooked. As a bonus, you can also test that no other operation was executed on the client, i.e. no other handlers were attached or detached.
/azp run
/azp run
/azp run
/azp run
/azp run
After a disconnect event, when the client reconnects, client subscribes to message receive event again resulting in multiple calls to direct method callback. The root cause was missing unsubscription after a disconnect event.
github issue: https://github.com/Azure/azure-iot-sdk-csharp/issues/3354