-
Bug
-
Resolution: Done
-
Major
-
3.6.3.Final
-
None
-
None
Clone of JBEAP-16475 jira
javax.ws.rs.core.Response.readEntity(Class<T>) fails to convert a single boolean value, i.e. with Boolean.class as argument.
Exception in thread "main" javax.ws.rs.ProcessingException: RESTEASY008200: JSON Binding deserialization error: null at org.jboss.resteasy.plugins.providers.jsonb.JsonBindingProvider.readFrom(JsonBindingProvider.java:88) at org.jboss.resteasy.core.interception.AbstractReaderInterceptorContext.readFrom(AbstractReaderInterceptorContext.java:66) at org.jboss.resteasy.core.interception.AbstractReaderInterceptorContext.proceed(AbstractReaderInterceptorContext.java:56) at org.jboss.resteasy.client.jaxrs.internal.ClientResponse.readFrom(ClientResponse.java:341) at org.jboss.resteasy.client.jaxrs.internal.ClientResponse.readEntity(ClientResponse.java:268) at org.jboss.resteasy.specimpl.BuiltResponse.readEntity(BuiltResponse.java:237) at org.jboss.qa.resteasy.test.resource.App.main(App.java:25) Caused by: java.util.NoSuchElementException at org.glassfish.json.JsonParserImpl.next(JsonParserImpl.java:361) at org.eclipse.yasson.internal.JsonbRiParser.next(JsonbRiParser.java:140) at org.eclipse.yasson.internal.JsonbRiParser.moveTo(JsonbRiParser.java:221) at org.eclipse.yasson.internal.JsonbRiParser.moveToValue(JsonbRiParser.java:208) at org.eclipse.yasson.internal.serializer.BooleanTypeDeserializer.deserialize(BooleanTypeDeserializer.java:44) at org.eclipse.yasson.internal.serializer.BooleanTypeDeserializer.deserialize(BooleanTypeDeserializer.java:31) at org.eclipse.yasson.internal.Unmarshaller.deserializeItem(Unmarshaller.java:61) at org.eclipse.yasson.internal.Unmarshaller.deserialize(Unmarshaller.java:51) at org.eclipse.yasson.internal.JsonBinding.deserialize(JsonBinding.java:45) at org.eclipse.yasson.internal.JsonBinding.fromJson(JsonBinding.java:85) at org.jboss.resteasy.plugins.providers.jsonb.JsonBindingProvider.readFrom(JsonBindingProvider.java:80) ... 6 more
I think it cased by this issue https://github.com/eclipse-ee4j/yasson/issues/188, which I guess will be fixed in version org.eclipse:yasson:1.0.4
If I exclude org.jboss.resteasy.resteasy-json-binding-provider it works.
<exclusions> <module name="org.jboss.resteasy.resteasy-json-binding-provider" /> </exclusions>
json-b can be disabled on server side also by variable
-Dresteasy.preferJacksonOverJsonB=true
- is cloned by
-
JBEAP-16475 (7.2.z) Rest Client fails to convert a single boolean value
- Closed