title: Make SpringData update only changed field of POJO
body: <p>I use Spring Data over MongoDB. I was able to save POJOs, update them. It's working fine. But now I want to flush in db only changed fields of POJO. </p>
  
  <p>For example I have User entity. I create user and then update lastActiveDate from time to time.</p>
  
  <pre><code>@Document
  class User {
      @Id
      BigInteger ID;
  
      String email;
  
      String name;
  
      Date lastActiveDate;
  }
  
  User user = new User();
  user.setName("User");
  user.setEmail("example@example.com");
  repository.save(user);
  
  User toUpdUser = repository.findOne(userId);
  toUpdUser.setLastActiveDate(new Date);
  repository.save(toUpdUser );
  </code></pre>
  
  <p>In second save I want update only lastActiveDate field not whole user because Document update can be slow on large entities. Also I want to know changeset (at least set of updated field). </p>
  
  <p>For now I didn't find API to do that. Only possibility is to handle it manually in setters (store set of changed fields and store it manually) but it looks ugly and unsupportable. Another option is using of AOP on beans to achieve same result but IFAIK Spring Data does not treat POJO as Spring bean and uses constructor so after load POJO with AOP will be just POJO.</p>
  
  <p>UPD:
   I looking for method without explicit mongo api (or mongo-like api) call. I have entities with dozens of field and client can change almost any of them. I want to store only changed fields and be able to get changeset to perform some checks. Difference beetween entity store and field update is too big - 5ms vs 0.2ms</p>
  
  <p>Of course I can create my own implementation of POJO mappers with CRUD tracker support but it already exist why not try it. And I can use another framework not only SpringData.</p>