tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (Jira)" <j...@apache.org>
Subject [jira] [Updated] (TOMEE-2753) Basic REST service with void return type or no response entity fails
Date Thu, 12 Dec 2019 20:48:00 GMT

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

ASF GitHub Bot updated TOMEE-2753:
----------------------------------
    Labels: pull-request-available  (was: )

> Basic REST service with void return type or no response entity fails
> --------------------------------------------------------------------
>
>                 Key: TOMEE-2753
>                 URL: https://issues.apache.org/jira/browse/TOMEE-2753
>             Project: TomEE
>          Issue Type: Bug
>    Affects Versions: 8.0.0-Final
>            Reporter: Jonathan Gallimore
>            Assignee: Jonathan Gallimore
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 8.0.1
>
>
> It looks like some bean validation is being attempted on the response object, which is
failing because the response entity is null.
>  
> Simple services to reproduce:
> @GET
> @Path("test")
> public void foo() {
> }
> @GET
> @Path("test2")
> public Response foo2() {
>  return Response.ok().build();
> }
>  
> Exception when invoking:
> java.lang.IllegalArgumentException: bean
>   at org.apache.bval.util.Validate.notNull(Validate.java:38)
>   at org.apache.bval.jsr.job.ValidateBean.<init>(ValidateBean.java:35)
>   at org.apache.bval.jsr.job.ValidationJobFactory.validateBean(ValidationJobFactory.java:52)
>   at org.apache.bval.jsr.ValidatorImpl.validate(ValidatorImpl.java:53)
>   at org.apache.cxf.validation.BeanValidationProvider.doValidateBean(BeanValidationProvider.java:149)
>   at org.apache.cxf.validation.BeanValidationProvider.validateReturnValue(BeanValidationProvider.java:135)
>   at org.apache.cxf.validation.BeanValidationOutInterceptor.handleValidation(BeanValidationOutInterceptor.java:43)
>   at org.apache.cxf.validation.AbstractValidationInterceptor.handleMessage(AbstractValidationInterceptor.java:82)
>   at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
>   at org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:90)
>   at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
>   at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
>   at org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267)
>   at org.apache.openejb.server.cxf.rs.CxfRsHttpListener.doInvoke(CxfRsHttpListener.java:258)
>   at org.apache.tomee.webservices.CXFJAXRSFilter.doFilter(CXFJAXRSFilter.java:99)
>   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
>   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
>   at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
>   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
>   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
>   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202)
>   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
>   at org.apache.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:45)
>   at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541)
>   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
>   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
>   at org.apache.tomee.catalina.OpenEJBSecurityListener$RequestCapturer.invoke(OpenEJBSecurityListener.java:97)
>   at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:678)
>   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
>   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
>   at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:367)
>   at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
>   at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:860)
>   at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1598)
>   at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
>   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
>   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
>   at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
>   at java.lang.Thread.run(Thread.java:748)
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message