我在WSO2ESB中部署一些代理配置时遇到问题。当我复制代理配置文件,甚至一些Apache Synapse样本(如样本151)时,我收到此错误: “代理服务定义需要'name'属性。”
The full stack trace is as follows:
wso2esb-4.6.0/repository/deployment/server/synapse-configs/default/proxy-services/synapse_sample_151.xml failed - Continue in fail-safe mode
org.apache.synapse.SynapseException: The 'name' attribute is required for a Proxy service definition
at org.apache.synapse.config.xml.ProxyServiceFactory.handleException(ProxyServiceFactory.java:369)
at org.apache.synapse.config.xml.ProxyServiceFactory.createProxy(ProxyServiceFactory.java:79)
at org.apache.synapse.deployers.ProxyServiceDeployer.deploySynapseArtifact(ProxyServiceDeployer.java:58)
at org.wso2.carbon.proxyadmin.ProxyServiceDeployer.deploySynapseArtifact(ProxyServiceDeployer.java:73)
at org.apache.synapse.deployers.AbstractSynapseArtifactDeployer.deploy(AbstractSynapseArtifactDeployer.java:172)
at org.apache.axis2.deployment.repository.util.DeploymentFileData.deploy(DeploymentFileData.java:136)
at org.apache.axis2.deployment.DeploymentEngine.doDeploy(DeploymentEngine.java:810)
at org.apache.axis2.deployment.repository.util.WSInfoList.update(WSInfoList.java:144)
at org.apache.axis2.deployment.RepositoryListener.update(RepositoryListener.java:377)
at org.apache.axis2.deployment.RepositoryListener.checkServices(RepositoryListener.java:254)
at org.apache.axis2.deployment.RepositoryListener.startListener(RepositoryListener.java:371)
at org.apache.axis2.deployment.scheduler.SchedulerTask.checkRepository(SchedulerTask.java:59)
at org.apache.axis2.deployment.scheduler.SchedulerTask.run(SchedulerTask.java:67)
at org.wso2.carbon.core.deployment.CarbonDeploymentSchedulerTask.runAxisDeployment(CarbonDeploymentSchedulerTask.java:67)
at org.wso2.carbon.core.deployment.CarbonDeploymentSchedulerTask.run(CarbonDeploymentSchedulerTask.java:112)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:351)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:178)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
答案 0 :(得分:0)
问题是,如果直接将代理配置部署到“proxy”文件夹loaction,则proxy.xml和代理服务名称应该相同。但是,如果您尝试使用代理编辑器创建代理,您只需给出名称,那么系统将自动使用代理服务的相同名称来创建proxy.xml
答案 1 :(得分:0)
部署到repository / deployment / server / default / synapseconfig / proxy 并确保将所有必要的端点和序列部署到此
中