cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Colm O hEigeartaigh (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (CXF-6375) Providers.getMessageBodyReader throws NPE
Date Fri, 14 Oct 2016 14:24:23 GMT

     [ https://issues.apache.org/jira/browse/CXF-6375?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Colm O hEigeartaigh closed CXF-6375.
------------------------------------

> Providers.getMessageBodyReader throws NPE
> -----------------------------------------
>
>                 Key: CXF-6375
>                 URL: https://issues.apache.org/jira/browse/CXF-6375
>             Project: CXF
>          Issue Type: Bug
>          Components: JAX-RS
>    Affects Versions: 3.0.3
>         Environment: Windows
>            Reporter: Neal Hu
>            Assignee: Sergey Beryozkin
>             Fix For: 3.1.0, 3.0.5
>
>
>  org.apache.cxf.jaxrs.impl.ProvidersImpl.getMessageBodyReader and org.apache.cxf.jaxrs.impl.ProvidersImpl.getMessageBodyWriter
are public methods that can be invoke by end user via injected providers.getMessageBodyReader(x,null,x,x).

> Recently we received TCK failure(NPE) on invoke above method when the Type genericType
is null.
> the stack trace is:
> at java.lang.Class.isAssignableFrom(Native Method)
> 	at org.apache.cxf.jaxrs.provider.JAXBElementProvider.objectFactoryOrIndexAvailable(JAXBElementProvider.java:109)
> 	at org.apache.cxf.jaxrs.provider.AbstractJAXBProvider.objectFactoryForType(AbstractJAXBProvider.java:584)
> 	at org.apache.cxf.jaxrs.provider.AbstractJAXBProvider.isSupported(AbstractJAXBProvider.java:570)
> 	at org.apache.cxf.jaxrs.provider.AbstractJAXBProvider.isReadable(AbstractJAXBProvider.java:440)
> 	at org.apache.cxf.jaxrs.provider.ProviderFactory.chooseMessageReader(ProviderFactory.java:845)
> 	at org.apache.cxf.jaxrs.provider.ProviderFactory.createMessageBodyReader(ProviderFactory.java:504)
> 	at org.apache.cxf.jaxrs.impl.ProvidersImpl.getMessageBodyReader(ProvidersImpl.java:45)
> How do you think the value of genericType is null? Is it valid or not. If not we may
challenge the TCK case. However the NPE is not allowed.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message