我正在寻找用 Maven 替换提供的 Ant 构建。我知道(但没有使用过)ant run,我也不喜欢。
长话短说,NetSuite 提供了一个 wsdl 以在针对其 ERP 产品进行 Web 服务调用时使用,我目前使用他们提供的 ant 构建从 wsdl 生成代理类。(此处提供示例应用程序、wsdl 和修补轴)
我遇到的问题是 ant 任务使用修补过的轴 1.4(和支持库,其中一些已经有 7 年的历史了),我想使用可以从中央 maven 存储库中轻松获得的库来实现这个 wsdl,并且最好是电流。
谁能指出我需要在哪里研究可行的解决方案?
对于任何需要知道的人:我尝试使用axis2生成并引发以下异常:
timeException: Element QName is null for ExceededRequestSizeFault!
at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:293)
at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35)
at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:24)
Caused by: org.apache.axis2.wsdl.codegen.CodeGenerationException: java.lang.RuntimeException: Element QName is null for ExceededRequestSizeFault!
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.emitSkeleton(AxisServiceBasedMultiLanguageEmitter.java:1451)
at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:275)
... 2 more
Caused by: java.lang.RuntimeException: Element QName is null for ExceededRequestSizeFault!
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.getFaultParamElements(AxisServiceBasedMultiLanguageEmitter.java:
2925)
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.getFaultElement(AxisServiceBasedMultiLanguageEmitter.java:2844)
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.generateMethodElement(AxisServiceBasedMultiLanguageEmitter.java:
2366)
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.loadOperations(AxisServiceBasedMultiLanguageEmitter.java:2242)
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.createDOMDocumentForSkeleton(AxisServiceBasedMultiLanguageEmitte
r.java:2156)
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.writeSkeleton(AxisServiceBasedMultiLanguageEmitter.java:2082)
at org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.emitSkeleton(AxisServiceBasedMultiLanguageEmitter.java:1408)
... 3 more
如果它是使用最近的 NetSuite WSDL 的经过测试的解决方案,则可以加分。