NutzCN Logo
问答 访问wsdl报NullPointerException错
发布于 2214天前 作者 lrw124 3013 次浏览 复制 上一个帖子 下一个帖子
标签: nutzwk

创建基于nutz的普通web项目,可以正常获取第三方提供的wsdl数据。但在基于NutzWK5的项目中,总是报错,日志如下:

org.apache.cxf.endpoint.dynamic.DynamicClientFactory.create
Client(DynamicClientFactory.java:315) - Creating client from WSDL http://38.43.6
4.110/wsdl/1proxy/marry.xml
java.lang.NullPointerException
        at org.apache.cxf.wsdl11.WSDLServiceFactory.<init>(WSDLServiceFactory.ja
va:74)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(Dyn
amicClientFactory.java:317)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(Dyn
amicClientFactory.java:243)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(Dyn
amicClientFactory.java:236)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(Dyn
amicClientFactory.java:191)
        at net.xwyun.pirs4j.web.commons.base.Backend.soapClient(Backend.java:182
)
        at net.xwyun.pirs4j.web.modules.controllers.platform.sys.SysMarryControl
ler.marry(SysMarryController.java:66)
        at net.xwyun.pirs4j.web.modules.controllers.platform.sys.SysMarryControl
ler$FM$marry$e30498877a7ba329609b46dd44b495c2.invoke(SysMarryController.java)
        at org.nutz.mvc.impl.processor.MethodInvokeProcessor.process(MethodInvok
eProcessor.java:31)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at org.nutz.mvc.impl.processor.AdaptorProcessor.process(AdaptorProcessor
.java:38)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at org.nutz.plugins.validation.ValidationProcessor.process(ValidationPro
cessor.java:39)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at org.nutz.mvc.impl.processor.ActionFiltersProcessor.process(ActionFilt
ersProcessor.java:58)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at net.xwyun.pirs4j.web.commons.processor.XssSqlFilterProcessor.process(
XssSqlFilterProcessor.java:35)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at net.xwyun.pirs4j.web.commons.processor.NutShiroProcessor.process(NutS
hiroProcessor.java:52)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at org.nutz.mvc.impl.processor.ModuleProcessor.process(ModuleProcessor.j
ava:123)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at org.nutz.mvc.impl.processor.EncodingProcessor.process(EncodingProcess
or.java:27)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at org.nutz.mvc.impl.processor.UpdateRequestAttributesProcessor.process(
UpdateRequestAttributesProcessor.java:15)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at net.xwyun.pirs4j.web.commons.processor.GlobalsSettingProcessor.proces
s(GlobalsSettingProcessor.java:48)
        at org.nutz.mvc.impl.processor.AbstractProcessor.doNext(AbstractProcesso
r.java:44)
        at net.xwyun.pirs4j.web.commons.processor.LogTimeProcessor.process(LogTi
meProcessor.java:21)
        at org.nutz.mvc.impl.NutActionChain.doChain(NutActionChain.java:44)
        at org.nutz.mvc.impl.ActionInvoker.invoke(ActionInvoker.java:67)
        at org.nutz.mvc.ActionHandler.handle(ActionHandler.java:31)
        at org.nutz.mvc.NutFilter.doFilter(NutFilter.java:202)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet
Handler.java:1610)
        at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilte
rChain.java:61)
        at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.j
ava:108)
        at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilt
er.java:137)
        at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerReq
uestFilter.java:125)
        at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilte
rChain.java:66)
        at org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(Abstrac
tShiroFilter.java:449)
        at org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiro
Filter.java:365)
        at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallab
le.java:90)
        at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable
.java:83)
        at org.apache.shiro.subject.support.DelegatingSubject.execute(Delegating
Subject.java:383)
        at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(Abs
tractShiroFilter.java:362)
        at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerReq
uestFilter.java:125)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet
Handler.java:1610)
        at net.xwyun.pirs4j.web.commons.filter.RouteFilter.doFilter(RouteFilter.
java:31)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet
Handler.java:1610)
        at org.nutz.mvc.WhaleFilter.doFilter(WhaleFilter.java:171)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet
Handler.java:1602)
        at org.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(We
bSocketUpgradeFilter.java:214)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet
Handler.java:1610)
        at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java
:540)
        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.j
ava:146)
        at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.jav
a:548)
        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper
.java:132)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandl
er.java:257)
        at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandl
er.java:1588)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandl
er.java:255)
        at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandl
er.java:1345)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandle
r.java:203)
        at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:
480)
        at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandle
r.java:1557)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandle
r.java:201)
        at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandle
r.java:1247)
        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.j
ava:144)
        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper
.java:132)
        at org.eclipse.jetty.server.Server.handle(Server.java:502)
        at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:364)
        at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.jav
a:260)
        at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(Abstra
ctConnection.java:305)
        at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
        at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
        at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPoo
l.java:765)
        at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool
.java:683)
        at java.lang.Thread.run(Thread.java:748)

5 回复

是不是cxf版本问题

我在pom里面指定了与测试里面完全一样的cxf及相关jar的版本,是否有可能是jetty的原因。

是打包之后报错的嘛? 还是直接运行的时候就报错了?

不愧是大牛,可以获取ws数据了,谢谢

添加回复
请先登陆
回到顶部