Closed rjbaat closed 4 years ago
Each redis-in connection uses unique ioredis connections while other nodes in the library share these connections. But same disconnect method was used in all the nodes including redis-in. Resulting in connections being kept alive even after node is deleted or the flow that node belongs to is disabled.
function RedisIn(n) {
node.on('close', function(done) {
if (node.command === "psubscribe") {
node.client.punsubscribe();
}
else if (node.command === "subscribe") {
node.client.unsubscribe();
}
if (node.sto !== null) {
clearInterval(node.sto);
node.sto = null;
}
node.status({});
node.client.disconnect(); /* Add This Line*/
disconnect(node.server); /* This line wont disconnect from client in Redis-in's case*/
node.topics = [];
done();
});
}
I know it's nearly a year, but is there an update to this?
This node now has a different strategy, Redis In now uses exclusive connection and others share the same connection optionally.
Hi, I make 2 big updates in this project, if you still use this module please give me a feedback.
Hi All, When i add a redis in node with BLPOP i get data incoming. Then i remove the node and it will still keep incoming data in my debug node. So it looks like the disconnect isn't done when removing the redis in node. I have this issue with 0.19.0 of node red and installed by manage pallete.