title: How to perform $out in an aggregation in mongoose?
body: <p>I looked for documentation of how to perform $out in an aggregation but I didn't find.</p>
  
  <p>This is my query:</p>
  
  <pre><code>Top.aggregate([
    {$sort: {created: -1}},
    {$group: {_id:'$location', title:{$push: '$title'}}},
    {$project: {location: '$location', mostRecentTitle: '$title'}},
    {$out: "aggr_out"}
  ]).exec(function(err, docs) {  console.log(docs); console.log(err) });
  </code></pre>
  
  <p>Schema:</p>
  
  <pre><code>var schema = mongoose.Schema({
    location: {type: String},
    title: {type: String},
    created: {type: Number, default: Math.floor(new Date() / 1000)}
  })
  </code></pre>
  
  <p>It might to be compatible with mongodb 3.0.x</p>