Skip to content
This repository has been archived by the owner on Jul 3, 2020. It is now read-only.

objectMapper.readValue issue #74

Open
kumaranilgupta opened this issue Feb 23, 2015 · 1 comment
Open

objectMapper.readValue issue #74

kumaranilgupta opened this issue Feb 23, 2015 · 1 comment

Comments

@kumaranilgupta
Copy link

Hi ,

Getting following error when i am trying to perform this command. curl -i -v -H "Authorization: bearer 00-11-22-33" http://localhost:8082 getting below error. org.codehaus.jackson.map.JsonMappingException: Unexpected token (START_OBJECT), expected START_ARRAY: need JSON Array to contain As.WRAPPER_ARRAY type information for class org.surfnet.oaaas.model.VerifyTokenResponse at [Source: java.io.StringReader@4d5d021; line: 1, column: 1] at org.codehaus.jackson.map.JsonMappingException.from(JsonMappingException.java:163) at org.codehaus.jackson.map.deser.StdDeserializationContext.wrongTokenException(StdDeserializationContext.java:261) at org.codehaus.jackson.map.jsontype.impl.AsArrayTypeDeserializer._locateTypeId(AsArrayTypeDeserializer.java:100) at org.codehaus.jackson.map.jsontype.impl.AsArrayTypeDeserializer._deserialize(AsArrayTypeDeserializer.java:86) at org.codehaus.jackson.map.jsontype.impl.AsArrayTypeDeserializer.deserializeTypedFromObject(AsArrayTypeDeserializer.java:55) Please suggest. failing to execute this line verifyTokenResponse = objectMapper.readValue(responseString, VerifyTokenResponse.class);

Please suggest for the fix...

@davidlzs
Copy link

One quick fix is: update the apis-example-resource-server-war\src\test\resources\apis-resource-server.properties to set the adminService.jsonTypeInfoIncluded property to false.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants