cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Beryozkin (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (CXF-7442) Improve handling of JSR 310 Date Time API
Date Thu, 13 Jul 2017 11:33:00 GMT

    [ https://issues.apache.org/jira/browse/CXF-7442?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16085560#comment-16085560
] 

Sergey Beryozkin edited comment on CXF-7442 at 7/13/17 11:32 AM:
-----------------------------------------------------------------

Hi Dennis, if you agree then I'd like to suggest to put it into the providers subpackage,
lets name it may be as either JavaTypesConverterProvider or JavaTypesParamConverterProvider
or may be StandardTypesConverterProvider or whatever you prefer :-). It would have an internal
LocalTime ParamConverter for a start and then we can add more ones as needed...  


was (Author: sergey_beryozkin):
Hi Dennis, if you agree then I'd like to suggest to put it into the providers subpackage,
lets name it may be as either JavaTypesConverterProvider or JavaTypesParamConverterProvider
or may be StandardTypesConverterProvider or whatever you prefer :-). It would an internal
LocalTime ParamConverter for a start and then we can add more ones as needed...  

> Improve handling of JSR 310 Date Time API
> -----------------------------------------
>
>                 Key: CXF-7442
>                 URL: https://issues.apache.org/jira/browse/CXF-7442
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAX-RS
>    Affects Versions: 3.1.12
>            Reporter: Dennis Kieselhorst
>             Fix For: 3.2.0
>
>
> If a wrong date is given as param, the type is a JSR 310 Datatype and an XmlAdapter is
used, it will result in a ClassCastException. Moreover the catch block in org.apache.cxf.jaxrs.utils.JAXBUtils.useAdapter
logs using ex.printStackTrace(). I created a testcase in org.apache.cxf.jaxrs.utils.InjectionUtilsTest#testJsr310DateExceptionHandling.
> In my view it should end up in IllegalArgumentException/ createParamConversionException
as for other invalid params.
> General question: Since CXF 3.2 depends on Java 8 do we want to make JSR 310 handling
more convenient so that XmlAdapter stuff is no longer required?



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message