Hi
It can happen is somewhere in the chain Response.close() has been
called, can you please investigate further ?
Cheers, Sergey
On 14/06/17 17:50, nicolasduminil wrote:
Hello,
A JAX-RS endpoint, working properly in order to perform its processing, is
raising the following exception on its return statement.
[14/06/17 18:40:00:743 CEST] 000000bd 0(id=120)] I Setting the server's
publish address to be /services/
[14/06/17 18:40:00:837 CEST] 000000bd ServletWrappe I
com.ibm.ws.webcontainer.servlet.ServletWrapper init SRVE0242I:
[QuickSignControllerEar] [/qs]
[be.alphacredit.services.esign.rest.QuickSignControllerApp]: Initialization
successful.
[14/06/17 18:40:01:072 CEST] 000000bd EnvironmentPr I Custom config found
by DeltaSpike. Name: 'META-INF/apache-deltaspike.properties', URL:
'wsjar:file:/C:/Program%20Files/IBM/WebSphere/AppServer/profiles/AppSrv01/installedApps/cac40Node02Cell/QuickSignControllerEar.ear/QuickSignControllerWar-0.0.1-SNAPSHOT.war/WEB-INF/lib/QuickSignControllerEjb-0.0.1-SNAPSHOT.jar!/META-INF/apache-deltaspike.properties'
[14/06/17 18:40:01:072 CEST] 000000bd EnvironmentPr I Custom config found
by DeltaSpike. Name: 'META-INF/apache-deltaspike.properties', URL:
'wsjar:file:/C:/Program%20Files/IBM/WebSphere/AppServer/profiles/AppSrv01/installedApps/cac40Node02Cell/QuickSignControllerEar.ear/QuickSignControllerWar-0.0.1-SNAPSHOT.war/WEB-INF/lib/QuickSignControllerRest-0.0.1-SNAPSHOT.jar!/META-INF/apache-deltaspike.properties'
[14/06/17 18:40:25:134 CEST] 000000bd 0(id=120)] W
org.apache.cxf.phase.PhaseInterceptorChain doDefaultLogging Interceptor for
{http://rest.esign.services.alphacredit.be/}QuickSignControllerServiceImpl
has thrown exception, unwinding now
java.lang.IllegalStateException: Entity is
not available
at
org.apache.cxf.jaxrs.impl.ResponseImpl.checkEntityIsClosed(ResponseImpl.java:614)
at
org.apache.cxf.jaxrs.impl.ResponseImpl.getActualEntity(ResponseImpl.java:148)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.serializeMessage(JAXRSOutInterceptor.java:140)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.processResponse(JAXRSOutInterceptor.java:119)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRSOutInterceptor.java:83)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:307)
at
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:83)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:307)
at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
at
org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:256)
at
com.ibm.ws.jaxrs20.endpoint.AbstractJaxRsWebEndpoint.invoke(AbstractJaxRsWebEndpoint.java:140)
at
com.ibm.websphere.jaxrs.server.IBMRestServlet.handleRequest(IBMRestServlet.java:179)
at
com.ibm.websphere.jaxrs.server.IBMRestServlet.doGet(IBMRestServlet.java:145)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:687)
at
com.ibm.websphere.jaxrs.server.IBMRestServlet.service(IBMRestServlet.java:125)
at
com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1235)
at
com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:779)
at
com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
at
com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
at
com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1124)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:4144)
at
com.ibm.ws.webcontainer.webapp.WebAppImpl.handleRequest(WebAppImpl.java:2208)
at
com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:304)
at
com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1030)
at
com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1817)
at
com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:382)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:532)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:318)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:289)
at
com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminators(NewConnectionInitialReadCallback.java:214)
at
com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:113)
at
com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:175)
at
com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at
com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
at
com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1892)
I need to mention that the service is deployed with WebSphere AS 9.0 and is
using the JAX-RS 2.0 and CXF 3.0.3 which comes with WebSphere.
Many thanks in advance for your help.
Nicolas
--
View this message in context:
http://cxf.547215.n5.nabble.com/CXF-3-0-3-java-lang-IllegalStateException-Entity-is-not-available-on-the-return-from-a-JAX-RS-service-tp5781201.html
Sent from the cxf-user mailing list archive at Nabble.com.