运行以下代码
for (var i= 0; i< 20; i++) {
redisClient.lindex("devices", i, function (errorMessage, DeviceList) {
for (var j= 0; j< 20; j++) {
var deviceCoordinateList = resultData[j].split(',');
var deviceCoordinate = deviceCoordinateList[0]+i+ ','+deviceCoordinateList [1]+i;
redisClient.lpush(DeviceList, deviceCoordinate, redisInitialise.print);
}
});
}
我收到错误:
Error: Error: Redis connection gone from close event.
如何解决?
答案 0 :(得分:3)
redisClient.quit();