title: MongoDB $in operator array max length
body: <p>In Meteor I use MongoDB to store a collection of Objects. There is around 500k docs inserted. </p>
  
  <p>I use <code>Objets.find({ "_id": { "$in": objIds } });</code> Where objIds is an array of _id. This works fine when I have an array length of 1000 but when I try with 13145 _ids the app stops responding. </p>
  
  <p>Obviously there's already an index on the _id field and also this search probably won't ever happen but I'm not sure if this is normal behavior. Is there a max length for the $in operator? Couldn't find one in the documentation.</p>
  
  <p>Here's my publish in Meteor : </p>
  
  <pre><code>Meteor.publish('objetsByIds', function objetsByIdsPublication(objIds) {
        return Objets.find({ "_id": { "$in": objIds } });
    })
  </code></pre>