diff --git a/swarmlab-app/src/run/app.js b/swarmlab-app/src/run/app.js index b8a7540..e27be4d 100755 --- a/swarmlab-app/src/run/app.js +++ b/swarmlab-app/src/run/app.js @@ -14,6 +14,10 @@ const subClient = pubClient.duplicate(); io.adapter(createAdapter({ pubClient, subClient })); +RedisClient.on("connect", function() { + console.log("You are now connected"); +}); + const MongoClient = require('mongodb').MongoClient; //var chokidar = require("chokidar"); @@ -426,7 +430,12 @@ function onCollection(err, collection) { resob1.user25user = resdata.data[i].res25user resob1.res25creator = resdata.data[i].res25creator resob1.res25fileforce = resdata.data[i].res25fileforce - resobarray.push(resob1) + resob1.tailed_path = pathfileval + //resobarray.push(resob1) + RedisClient.hmset(pathfileval,JSON.stringify(resob1)) + RedisClient.hgetall(pathfileval, function(err, object) { + console.log('redis '+object); + }); } resob.data = resobarray //var indexfind = global.pipelines.findIndex(x => x.res25swarmlabname==resdata.data[0].res25swarmlabname);