title: Field with @Version annotation not being sent to frontend
body: <p>I have an object with a property called version with <code>@Version</code> annotation. When retrieving this object from the database and sending it to the front end the version field is missing. Is there some special configuration you need to have to retrieve the object from the database and send it to the frontend? I am using java and spring on the backend. The field in the database is being updated so that part works but for some reason the version field isn't being sent to the front end.</p>
  
  <p>Here are the relevant imports for my domain class:</p>
  
  <pre><code>import javax.persistence.Version;
  
  import com.fasterxml.jackson.annotation.JsonAnySetter;
  import com.fasterxml.jackson.annotation.JsonIgnore;
  import com.fasterxml.jackson.annotation.JsonProperty;
  </code></pre>
  
  <p>Here is the relevant code from my domain entity:</p>
  
  <pre><code>@Entity
  @NamedQueries({})
  @JsonIgnoreProperties({"hibernateLazyInitializer", "handler"})
  @Table(schema = "schema", name = "type")
  public class Type {
      @Column(name = "title", length = 128, nullable = false)
      @Basic(fetch = FetchType.EAGER)
      String title;
  
      @Column(name = "description", length = 128, nullable = false)
      @Basic(fetch = FetchType.EAGER)
      String description;
  
      @Version
      @Column(name = "version", nullable = false)
      @Basic(fetch = FetchType.EAGER)
      int version = 0;
  
      //getters and setters
  
      public void setVersion(int version)
      {
          this.version = version;
      }
      public int getVersion()
      {
          return version;
      }
  }
  </code></pre>
  
  <p>Here are the relevant rest controller imports:</p>
  
  <pre><code>import org.springframework.web.bind.annotation.PathVariable;
  import org.springframework.web.bind.annotation.RequestBody;
  import org.springframework.web.bind.annotation.RequestMapping;
  import org.springframework.web.bind.annotation.RequestMethod;
  import org.springframework.web.bind.annotation.RestController;
  </code></pre>
  
  <p>Here is the Rest Controller Method that sends the entity to the client:</p>
  
  <pre><code>@RequestMapping(value = "/type", method = RequestMethod.GET)
  public List&lt;Type&gt; listTypes() {
      ArrayList&lt;Type&gt; list = new java.util.ArrayList&lt;Type&gt;(TypeService.loadTypes());
      Type type = list.get(0);
      return list;
  }
  </code></pre>
  
  <p>EDIT: I found that the field gets sent if I remove the <code>@Version</code> annotation</p>