Forum Discussion

venkateshsattur's avatar
venkateshsattur
Regular Visitor
4 years ago
Solved

Deploy Virtual Service as war not working, getting DispatchException: java.lang.NullPointerException

Hi Team,

 

We created a virtual service and deplyed it as war on  apache tomcat. while trying to trigger the sercive, we are getting the below exception

18:18:33,594 ERROR [errorlog] got an exception while dispatching - returning a default 500 response
18:18:33,603 ERROR [errorlog] com.eviware.soapui.impl.wsdl.mock.DispatchException: java.lang.NullPointerException
com.eviware.soapui.impl.wsdl.mock.DispatchException: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:191) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.getMockResult(RestMockDispatcher.java:115) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.lambda$0(RestMockDispatcher.java:56) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.model.support.HasMockResultsMockDispatcher.doDispatch(HasMockResultsMockDispatcher.java:90) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.dispatchRequest(RestMockDispatcher.java:56) [ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:172) [ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.mockaswar.MockAsWarServlet$MockServletSoapUICore.dispatchRequest(MockAsWarServlet.java:243) [ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.mockaswar.MockAsWarServlet.service(MockAsWarServlet.java:176) [ready-api-soapui-3.2.0.jar:3.2.0]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) [servlet-api.jar:?]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) [catalina.jar:9.0.10]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.10]
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) [tomcat-websocket.jar:9.0.10]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.10]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) [catalina.jar:9.0.10]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:491) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) [catalina.jar:9.0.10]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [catalina.jar:9.0.10]
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:668) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [catalina.jar:9.0.10]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [catalina.jar:9.0.10]
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) [tomcat-coyote.jar:9.0.10]
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-coyote.jar:9.0.10]
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764) [tomcat-coyote.jar:9.0.10]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388) [tomcat-coyote.jar:9.0.10]
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:9.0.10]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:9.0.10]
at java.lang.Thread.run(Thread.java:835) [?:?]
Caused by: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:166) ~[ready-api-soapui-3.2.0.jar:3.2.0]
... 30 more
com.eviware.soapui.impl.wsdl.mock.DispatchException: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:191)
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.getMockResult(RestMockDispatcher.java:115)
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.lambda$0(RestMockDispatcher.java:56)
at com.eviware.soapui.model.support.HasMockResultsMockDispatcher.doDispatch(HasMockResultsMockDispatcher.java:90)
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.dispatchRequest(RestMockDispatcher.java:56)
at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:172)
at com.eviware.soapui.mockaswar.MockAsWarServlet$MockServletSoapUICore.dispatchRequest(MockAsWarServlet.java:243)
at com.eviware.soapui.mockaswar.MockAsWarServlet.service(MockAsWarServlet.java:176)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
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:199)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:491)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:668)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408)
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.base/java.lang.Thread.run(Thread.java:835)
Caused by: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:166)
... 30 more
18:20:02,204 ERROR [SoapUI] An error occurred [java.lang.NullPointerException], see error log for details
18:33:47,652 ERROR [errorlog] got an exception while dispatching - returning a default 500 response
18:33:47,669 ERROR [errorlog] com.eviware.soapui.impl.wsdl.mock.DispatchException: java.lang.NullPointerException
com.eviware.soapui.impl.wsdl.mock.DispatchException: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:191) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.getMockResult(RestMockDispatcher.java:115) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.lambda$0(RestMockDispatcher.java:56) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.model.support.HasMockResultsMockDispatcher.doDispatch(HasMockResultsMockDispatcher.java:90) ~[ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.dispatchRequest(RestMockDispatcher.java:56) [ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:172) [ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.mockaswar.MockAsWarServlet$MockServletSoapUICore.dispatchRequest(MockAsWarServlet.java:243) [ready-api-soapui-3.2.0.jar:3.2.0]
at com.eviware.soapui.mockaswar.MockAsWarServlet.service(MockAsWarServlet.java:176) [ready-api-soapui-3.2.0.jar:3.2.0]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) [servlet-api.jar:?]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) [catalina.jar:9.0.10]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.10]
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) [tomcat-websocket.jar:9.0.10]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.10]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) [catalina.jar:9.0.10]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:491) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) [catalina.jar:9.0.10]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [catalina.jar:9.0.10]
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:668) [catalina.jar:9.0.10]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [catalina.jar:9.0.10]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [catalina.jar:9.0.10]
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) [tomcat-coyote.jar:9.0.10]
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-coyote.jar:9.0.10]
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764) [tomcat-coyote.jar:9.0.10]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388) [tomcat-coyote.jar:9.0.10]
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:9.0.10]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:9.0.10]
at java.lang.Thread.run(Thread.java:835) [?:?]
Caused by: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:166) ~[ready-api-soapui-3.2.0.jar:3.2.0]
... 30 more
com.eviware.soapui.impl.wsdl.mock.DispatchException: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:191)
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.getMockResult(RestMockDispatcher.java:115)
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.lambda$0(RestMockDispatcher.java:56)
at com.eviware.soapui.model.support.HasMockResultsMockDispatcher.doDispatch(HasMockResultsMockDispatcher.java:90)
at com.eviware.soapui.impl.rest.mock.RestMockDispatcher.dispatchRequest(RestMockDispatcher.java:56)
at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:172)
at com.eviware.soapui.mockaswar.MockAsWarServlet$MockServletSoapUICore.dispatchRequest(MockAsWarServlet.java:243)
at com.eviware.soapui.mockaswar.MockAsWarServlet.service(MockAsWarServlet.java:176)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
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:199)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:491)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:668)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408)
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.base/java.lang.Thread.run(Thread.java:835)
Caused by: java.lang.NullPointerException
at com.eviware.soapui.impl.rest.mock.RestMockAction.dispatchRequest(RestMockAction.java:166)
... 30 more

 

Attaching the project. Can you please help us in identifying the root cause of issue.

 

Regards,

Venkatesh

  • Hi Venkatesh,

     

    you are using service with pro features that are not supported to run with war file. please convert to normal service. it will work.

     

    Best Regards,

    Venkata Yedida 

1 Reply

  • venkatayedida's avatar
    venkatayedida
    Occasional Contributor

    Hi Venkatesh,

     

    you are using service with pro features that are not supported to run with war file. please convert to normal service. it will work.

     

    Best Regards,

    Venkata Yedida