There is STILL a memory leak somehow. When the flows are redeployed or restarted, old versions of the client connection remain in tact and polling continues for them as well. I'm not sure why yet, since this bit of code
node.on('close', function () {
// NOTE: We reference node.client.devices here, just in case
// there were devices initialized on this client that did not
// make it into the node.devices map. This ensures no memory
// leaking in case of bugs/errors.
node.client.devices.forEach(device => {
device.stopPolling()
device.closeConnection()
})
node.client.stopDiscovery()
})
was supposed to prevent that from happening. I'm working on a fix right now.
There is STILL a memory leak somehow. When the flows are redeployed or restarted, old versions of the client connection remain in tact and polling continues for them as well. I'm not sure why yet, since this bit of code
was supposed to prevent that from happening. I'm working on a fix right now.