node.js - Identity Map with Mongoose -


is there native way mongoose 4.x maintain identity map , avoid returning different object instances same entity in db?

users.findone({_id: objectid("xxx")}, function(err, user1) {   if (err) throw err;   users.findone({_id: objectid("xxx")}, function(err, user2) {      if (err) throw err;      console.log(user1 === user2); // return false   }); }); 


Comments

Popular posts from this blog

javascript - Why Selenium can't find an element that is graphically visible -

java - How to compare two classes -

scala - Using the kronecker product on complex matrices with scalaNLP breeze -