title: Spring Data mongo to insert null values to DB
body: <p>I am using Spring data mongo to insert a record to Mongo, </p>
  
  <p>here is my code
  mongoTemplate.save(person,"personCollection");</p>
  
  <p>Here is my person object</p>
  
  <pre><code>public class Person implements Serializable {
     int age;
     String address;
     String name;
  
  //Getters and setters including hashcode and equals
  }
  </code></pre>
  
  <p>my address is null here , after inserting the record in the collection, the data is populated with only age and name</p>
  
  <p>i know that mongodb treats null value and noKey as the same thing, but my requirement is to even populate the address:null to have the schema consistent how do i do this with Spring Data mongo</p>
  
  <p>current o/p: {"age":21,"name":"john Doe"}</p>
  
  <p>expected o/p: {"age":21,"name":"john Doe","address":null}</p>