org.springframework.http.converter.HttpMessageNotReadableException: Could not read JSON: Unrecognized field "uri" (Class org.json.JSONObject), not marked as ignorable at [Source: sun.net.www.protocol.http.HttpURLConnection$HttpInputStream@6f526c5f; line: 2, column: 12] (through reference chain: org.json.JSONObject["uri"]); nested exception is org.codehaus.jackson.map.exc.UnrecognizedPropertyException: Unrecognized field "uri" (Class org.json.JSONObject), not marked as ignorable at [Source: sun.net.www.protocol.http.HttpURLConnection$HttpInputStream@6f526c5f; line: 2, column: 12] (through reference chain: org.json.JSONObject["uri"])

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • Carried over from SOCIAL-423: I tried the latest build but I get org.springframework.http.converter.HttpMessageNotReadableException: Could not read JSON: No suitable constructor found for type [simple type, class org.springframework.social.facebook.api.FacebookProfile]: can not instantiate from JSON object (need to add/enable type information?) at [Source: java.io.ByteArrayInputStream@7e305fb2; line: 1, column: 2]; nested exception is com.fasterxml.jackson.databind.JsonMappingException: No suitable constructor found for type [simple type, class org.springframework.social.facebook.api.FacebookProfile]: can not instantiate from JSON object (need to add/enable type information?) at [Source: java.io.ByteArrayInputStream@7e305fb2; line: 1, column: 2] at org.springframework.http.converter.json.MappingJackson2HttpMessageConverter.readJavaType(MappingJackson2HttpMessageConverter.java:228) at org.springframework.http.converter.json.MappingJackson2HttpMessageConverter.read(MappingJackson2HttpMessageConverter.java:220) at org.springframework.web.client.HttpMessageConverterExtractor.extractData(HttpMessageConverterExtractor.java:95) at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:549) at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:517) at org.springframework.web.client.RestTemplate.getForObject(RestTemplate.java:255) at org.springframework.social.facebook.api.impl.FacebookTemplate.fetchObject(FacebookTemplate.java:165) at org.springframework.social.facebook.api.impl.UserTemplate.getUserProfile(UserTemplate.java:50) at org.springframework.social.facebook.api.impl.UserTemplate.getUserProfile(UserTemplate.java:46) exception
    via by Craig Walls,
  • GitHub comment 58#294182989
    via GitHub by athrane
    ,
    • org.springframework.http.converter.HttpMessageNotReadableException: Could not read JSON: Unrecognized field "uri" (Class org.json.JSONObject), not marked as ignorable at [Source: sun.net.www.protocol.http.HttpURLConnection$HttpInputStream@6f526c5f; line: 2, column: 12] (through reference chain: org.json.JSONObject["uri"]); nested exception is org.codehaus.jackson.map.exc.UnrecognizedPropertyException: Unrecognized field "uri" (Class org.json.JSONObject), not marked as ignorable at [Source: sun.net.www.protocol.http.HttpURLConnection$HttpInputStream@6f526c5f; line: 2, column: 12] (through reference chain: org.json.JSONObject["uri"]) at org.springframework.http.converter.json.MappingJacksonHttpMessageConverter.readJavaType(MappingJacksonHttpMessageConverter.java:181) at org.springframework.http.converter.json.MappingJacksonHttpMessageConverter.read(MappingJacksonHttpMessageConverter.java:173) at org.springframework.web.client.HttpMessageConverterExtractor.extractData(HttpMessageConverterExtractor.java:94) at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:517) at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:472) at org.springframework.web.client.RestTemplate.getForObject(RestTemplate.java:237)

    Users with the same issue

    tvrmsmith
    tvrmsmith3 times, last one,
    Unknown visitor1 times, last one,