title: How to execute MongoDB native query (JSON) using mongo-java-driver only?
body: <p>How to fire mongo native queries using java-mongo-driver only.</p>
  
  <blockquote>
    <p><strong>No</strong> Spring-Data or EclipseLink or Hibernate OGM, <strong>Only using</strong> java-mongo-driver</p>
  </blockquote>
  
  <p><strong>Sample query :</strong></p>
  
  <pre><code>db.orders.aggregate([
     {
        $unwind: "$specs"
     },
     {
        $lookup:
           {
              from: "inventory",
              localField: "specs",
              foreignField: "size",
              as: "inventory_docs"
          }
     },
     {
        $match: { "inventory_docs": { $ne: [] } }
     }
  ])
  </code></pre>