gpt4 book ai didi

soap - mule esb web 服务使用者 SOAP - 错误 : Prefix not specified

转载 作者:行者123 更新时间:2023-12-01 14:04:30 28 4
gpt4 key购买 nike

我尝试用我自己的网络服务 SOAP 重现 Mule ESB 3.5.0 社区运行时的示例项目“tshirt-service-consumer”的流程“listInventory”。但是当我运行该项目时,我的控制台出现错误

WARN  2014-07-20 22:16:21,541 [main] org.mule.module.ws.consumer.RequestBodyGenerator: Unable to check if the operation requires input parameters, the payload will be used as SOAP body
org.mule.common.metadata.MetaDataGenerationException: org.apache.xmlbeans.XmlException: error: Prefix not specified
at org.mule.common.metadata.XmlMetaDataFieldFactory.createFields(XmlMetaDataFieldFactory.java:104)
at org.mule.common.metadata.DefaultXmlMetaDataModel.<init>(DefaultXmlMetaDataModel.java:46)
at org.mule.module.ws.consumer.RequestBodyGenerator.generateRequestBody(RequestBodyGenerator.java:79)
at org.mule.module.ws.consumer.WSConsumer.parseWsdl(WSConsumer.java:333)
at org.mule.module.ws.consumer.WSConsumer.initialise(WSConsumer.java:87)
at org.mule.processor.chain.AbstractMessageProcessorChain.initialise(AbstractMessageProcessorChain.java:80)
at org.mule.construct.AbstractFlowConstruct.initialiseIfInitialisable(AbstractFlowConstruct.java:314)
at org.mule.construct.AbstractPipeline.doInitialise(AbstractPipeline.java:215)
at org.mule.construct.AbstractFlowConstruct$1.onTransition(AbstractFlowConstruct.java:109)
at org.mule.construct.AbstractFlowConstruct$1.onTransition(AbstractFlowConstruct.java:103)
at org.mule.lifecycle.AbstractLifecycleManager.invokePhase(AbstractLifecycleManager.java:138)
at org.mule.construct.FlowConstructLifecycleManager.fireInitialisePhase(FlowConstructLifecycleManager.java:78)
at org.mule.construct.AbstractFlowConstruct.initialise(AbstractFlowConstruct.java:102)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1612)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1553)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1483)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:524)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:461)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:295)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:292)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:626)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:932)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)
at org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:86)
at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:105)
at org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:135)
at org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:90)
at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:43)
at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:69)
at org.mule.config.builders.AutoConfigurationBuilder.autoConfigure(AutoConfigurationBuilder.java:101)
at org.mule.config.builders.AutoConfigurationBuilder.doConfigure(AutoConfigurationBuilder.java:52)
at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:43)
at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:69)
at org.mule.context.DefaultMuleContextFactory$1.configure(DefaultMuleContextFactory.java:84)
at org.mule.context.DefaultMuleContextFactory.doCreateMuleContext(DefaultMuleContextFactory.java:217)
at org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:76)
at org.mule.module.launcher.application.DefaultMuleApplication.init(DefaultMuleApplication.java:174)
at org.mule.module.launcher.artifact.ArtifactWrapper$2.execute(ArtifactWrapper.java:62)
at org.mule.module.launcher.artifact.ArtifactWrapper.executeWithinArtifactClassLoader(ArtifactWrapper.java:129)
at org.mule.module.launcher.artifact.ArtifactWrapper.init(ArtifactWrapper.java:57)
at org.mule.module.launcher.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:25)
at org.mule.module.launcher.DefaultArchiveDeployer.guardedDeploy(DefaultArchiveDeployer.java:274)
at org.mule.module.launcher.DefaultArchiveDeployer.deployArtifact(DefaultArchiveDeployer.java:294)
at org.mule.module.launcher.DefaultArchiveDeployer.deployExplodedApp(DefaultArchiveDeployer.java:261)
at org.mule.module.launcher.DefaultArchiveDeployer.deployExplodedArtifact(DefaultArchiveDeployer.java:110)
at org.mule.module.launcher.DeploymentDirectoryWatcher.deployExplodedApps(DeploymentDirectoryWatcher.java:287)
at org.mule.module.launcher.DeploymentDirectoryWatcher.start(DeploymentDirectoryWatcher.java:148)
at org.mule.tooling.server.application.ApplicationDeployer.main(ApplicationDeployer.java:130)
Caused by: org.apache.xmlbeans.XmlException: error: Prefix not specified
at org.apache.xmlbeans.impl.store.Locale$SaxLoader.load(Locale.java:3459)
at org.apache.xmlbeans.impl.store.Locale.parse(Locale.java:706)
at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:690)
at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:677)
at org.apache.xmlbeans.impl.schema.SchemaTypeLoaderBase.parse(SchemaTypeLoaderBase.java:208)
at org.mule.common.metadata.XmlMetaDataFieldFactory.findRootElement(XmlMetaDataFieldFactory.java:246)
at org.mule.common.metadata.XmlMetaDataFieldFactory.createFields(XmlMetaDataFieldFactory.java:95)
... 53 more

当我用另一个客户端 soap 调用我的网络服务时,我没有问题。

wsdl :

<?xml version='1.0' encoding='UTF-8'?><!-- Published by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is Metro/2.3 (tags/2.3-7528; 2013-04-29T19:34:10+0000) JAXWS-RI/2.2.8 JAXWS/2.2 svn-revision#unknown. --><!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is Metro/2.3 (tags/2.3-7528; 2013-04-29T19:34:10+0000) JAXWS-RI/2.2.8 JAXWS/2.2 svn-revision#unknown. --><definitions xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://www.w3.org/ns/ws-policy" xmlns:wsp1_2="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://xml.heg-arc.ch/srv/CustomerService/1.0" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://xml.heg-arc.ch/srv/CustomerService/1.0" name="CustomerService">
<import namespace="http://xml.he-arc.ch/srv/CustomerService/1.0" location="http://localhost:8080/TB-Service2/CustomerService?wsdl=1"/>
<wsp:Policy wsu:Id="CustomerSOAPServicePortBindingPolicy"/>
<binding xmlns:ns1="http://xml.he-arc.ch/srv/CustomerService/1.0" name="CustomerSOAPServicePortBinding" type="ns1:CustomerService">
<wsp:PolicyReference URI="#CustomerSOAPServicePortBindingPolicy"/>
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
<operation name="updCustomer">
<soap:operation soapAction=""/>
<input>
<soap:body use="literal"/>
</input>
<output>
<soap:body use="literal"/>
</output>
</operation>
<operation name="addCustomer">
<soap:operation soapAction=""/>
<input>
<soap:body use="literal"/>
</input>
<output>
<soap:body use="literal"/>
</output>
</operation>
<operation name="getCustomer">
<soap:operation soapAction=""/>
<input>
<soap:body use="literal"/>
</input>
<output>
<soap:body use="literal"/>
</output>
</operation>
<operation name="delCustomer">
<soap:operation soapAction=""/>
<input>
<soap:body use="literal"/>
</input>
<output>
<soap:body use="literal"/>
</output>
</operation>
<operation name="getCustomers">
<soap:operation soapAction=""/>
<input>
<soap:body use="literal"/>
</input>
<output>
<soap:body use="literal"/>
</output>
</operation>
</binding>
<service name="CustomerService">
<port name="CustomerSOAPServicePort" binding="tns:CustomerSOAPServicePortBinding">
<soap:address location="http://localhost:8080/TB-Service2/CustomerService"/>
</port>
</service>
</definitions>

<ws:consumer-config name="Web_Service_Consumer" wsdlLocation="http://localhost:8080/TB-Service2/CustomerService?wsdl" service="CustomerService" port="CustomerSOAPServicePort" serviceAddress="http://localhost:8080/TB-Service2/CustomerService" doc:name="Web Service Consumer"/>
<data-mapper:config name="Xml_getCustomersResponse__To_JSON" transformationGraphPath="xml_getcustomersresponse__to_json.grf" doc:name="Xml_getCustomersResponse__To_JSON"/>
<flow name="web-service-parkingFlow1" doc:name="web-service-parkingFlow1">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" path="getCustomers" doc:name="HTTP"/>
<ws:consumer config-ref="Web_Service_Consumer" operation="getCustomers" doc:name="Web Service Consumer"/>
<data-mapper:transform config-ref="Xml_getCustomersResponse__To_JSON" doc:name="Xml&lt;getCustomersResponse&gt; To JSON"/>
<http:response-builder status="200" contentType="application/json" doc:name="HTTP Response Builder"/>
</flow>

最佳答案

关于soap - mule esb web 服务使用者 SOAP - 错误 : Prefix not specified,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24854627/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com