Return-Path: X-Original-To: apmail-cxf-issues-archive@www.apache.org Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 474C01763D for ; Fri, 15 May 2015 14:02:00 +0000 (UTC) Received: (qmail 5705 invoked by uid 500); 15 May 2015 14:02:00 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 5664 invoked by uid 500); 15 May 2015 14:02:00 -0000 Mailing-List: contact issues-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list issues@cxf.apache.org Received: (qmail 5642 invoked by uid 99); 15 May 2015 14:02:00 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 15 May 2015 14:02:00 +0000 Date: Fri, 15 May 2015 14:02:00 +0000 (UTC) From: "Ruben Lara (JIRA)" To: issues@cxf.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CXF-3278) Invalid Enum passed in WebMethod results to a null object MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CXF-3278?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14545538#comment-14545538 ] Ruben Lara commented on CXF-3278: --------------------------------- Hi Daniel, I'm facing the same problem. What do you mean with "you would need to turn on the schema validation"? I already set the validation on @SchemaValidation(type = SchemaValidationType.IN) public class CarServiceEndpointImpl implements Car { ... } I'm working with spring boot and configuring cxf with java config. Everything but the enum validation is working perfectly. @Bean public Endpoint carWebService(final Bus cxfBus, final LoggingInInterceptor inInterceptor, final LoggingOutInterceptor outInterceptor, final BasicAuthAuthorizationInterceptor authInInterceptor) { final Endpoint endpoint = new EndpointImpl(cxfBus, carServiceEnpointImpl()); ((EndpointImpl) endpoint).setAddress(carServiceName); ((EndpointImpl) endpoint).getInInterceptors().add(authInInterceptor); ((EndpointImpl) endpoint).getInInterceptors().add(inInterceptor); ((EndpointImpl) endpoint).getOutInterceptors().add(outInterceptor); ((EndpointImpl) endpoint).publish(); return endpoint; } @Bean public Costs carServiceEnpointImpl() { return new CarServiceEnpointImpl(); } Or is there another setting I'm missing in my project? > Invalid Enum passed in WebMethod results to a null object > --------------------------------------------------------- > > Key: CXF-3278 > URL: https://issues.apache.org/jira/browse/CXF-3278 > Project: CXF > Issue Type: Bug > Affects Versions: 2.3.2 > Reporter: Ioannis Mavroukakis > Fix For: Invalid > > > Given the following method > {code} > @WebMethod > public BaseResponse removeDepositLimits( > @WebParam( name = SERVICE_AUTH ) @XmlElement( required = true ) final Authorisation auth , > @WebParam( name = TOKEN ) @XmlElement( required = true ) final String token , > @WebParam( name = "timeFrame" ) @XmlElement( required = true ) final DepositLimit.TimeFrame timeFrame ) > {code} > when timeFrame is a value that's not in the TimeFrame enum, timeFrame is set to null, this should return an error to the invoker instead. -- This message was sent by Atlassian JIRA (v6.3.4#6332)