title: NodeJS - Is Mongoose faster than MongoJS?
body: <p>I've got an application that runs on NodeJS, and uses MongoDB as a database for information.</p>
  
  <p>Currently I hook into MongoDB via the <a href="https://github.com/gett/mongojs" rel="nofollow">MongoJS</a> module, which aims to "emulate the official mongodb API as much as possible".</p>
  
  <p>The application gets about 20,000 objects and saves each one to MongoDB. First, it looks up the database to see whether the object already exists, then it either updates the existing entry or adds a new entry. </p>
  
  <p>This can be quite slow. I'm not sure if it's because <code>MongoJS</code> is synchronous/single-stream (if it even is - I'm not sure!), or it's just a reality of writing a lot of entries to a DB, but it takes 45min-1hr to do all of this and I'd obviously like to cut this down as much as possible.</p>
  
  <p>I'm wondering whether <a href="http://mongoosejs.com/" rel="nofollow">Mongoose</a> would be a better/faster option for this. Apparently it's asynchronous, I don't know whether that would have an affect at all on performance.</p>