You're going to need an error handler here:

var self = this;
db.on('error', function (error) {
   self.logerror('Redis error: ' + error.message);
});

And some kind of reconnection logic.   Try stopping Redis whilst your plugin is running and you'll see what I mean.