title: Jackson Mapping with object in spring mvc
body: <p>I have a Java POJO where I have declared certain fields. One of the fields is:</p>
  
  <pre><code>private Page&lt;MyAbcClass&gt; pageDto;
  </code></pre>
  
  <p>The Page object is org.springframework.data.domain.Page</p>
  
  <p>When I send this object from my UI that is built upon angular, the object could not map correctly and throws this exception:</p>
  
  <pre><code>    Caused by: com.fasterxml.jackson.databind.JsonMappingException: Can not construct instance of org.springframework.data.domain.Page, problem: abstract types either need to be mapped to concrete types, have custom deserializer, or be instantiated with additional type information
   at [Source: java.io.PushbackInputStream@2a89f0ab; line: 1, column: 9233] (through reference chain: com.abc.JavaPojo["pageDto"])
      at com.fasterxml.jackson.databind.JsonMappingException.from(JsonMappingException.java:148)
      at com.fasterxml.jackson.databind.DeserializationContext.instantiationException(DeserializationContext.java:892)
      at com.fasterxml.jackson.databind.deser.AbstractDeserializer.deserialize(AbstractDeserializer.java:139)
      at com.fasterxml.jackson.databind.deser.SettableBeanProperty.deserialize(SettableBeanProperty.java:520)
      at com.fasterxml.jackson.databind.deser.impl.MethodProperty.deserializeAndSet(MethodProperty.java:95)
      at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserializeFromObject(BeanDeserializer.java:339)
      at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:133)
      at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:3736)
      at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:2810)
      at org.springframework.http.converter.json.AbstractJackson2HttpMessageConverter.readJavaType(AbstractJackson2HttpMessageConverter.java:222)
      ... 88 common frames omitted
  </code></pre>
  
  <p>There is some probelm with the JSON mapping but I could not figure what.</p>