Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
Windows XP, JDK1.5
Description
Created a sequence as follows with a security enabled endpoint where the policy key is read from the registry.
**********************************************************************************************************************************************************************************************
<syn:definitions xmlns:syn="http://ws.apache.org/ns/synapse">
<syn:registry provider="org.wso2.esb.registry.ESBRegistry">
<syn:parameter name="root">file:registry/</syn:parameter>
<syn:parameter name="cachableDuration">15000</syn:parameter>
</syn:registry>
<endpoint name="secure">
<wsdl service="SecureStockQuoteService" port="SecureStockQuoteServiceSOAP11port_http1" uri="http://localhost:9000/soap/SecureStockQuoteService?wsdl">
<enableAddressing/>
<enableSec policy="Policy/policy_3.xml"/>
</wsdl>
</endpoint>
<sequence name="sample_50">
<in>
<send>
<endpoint key="secure"/>
</send>
</in>
<out>
<header xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" name="wsse:Security" action="remove"/>
</out>
<send/>
</sequence>
<definitions>
**********************************************************************************************************************************************************************************************
Send a request and you will get the following exception
******************************************************************************************************************************
ERROR [15 May 10:55:39] Axis2FlexibleMEPClient - Cannot locate Policy from the property : Policy/policy_3.xml
ERROR [15 May 10:55:39] Axis2Sender - Unexpected error during Sending message onwards
org.apache.synapse.SynapseException: Cannot locate Policy from the property : Policy/policy_3.xml
at org.apache.synapse.core.axis2.Axis2FlexibleMEPClient.handleException(Axis2FlexibleMEPClient.java:321)
at org.apache.synapse.core.axis2.Axis2FlexibleMEPClient.getPolicy(Axis2FlexibleMEPClient.java:314)
at org.apache.synapse.core.axis2.Axis2FlexibleMEPClient.send(Axis2FlexibleMEPClient.java:203)
at org.apache.synapse.core.axis2.Axis2Sender.sendOn(Axis2Sender.java:50)
at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.send(Axis2SynapseEnvironment.java:112)
at org.apache.synapse.endpoints.WSDLEndpoint.send(WSDLEndpoint.java:127)
at org.apache.synapse.endpoints.IndirectEndpoint.send(IndirectEndpoint.java:57)
at org.apache.synapse.mediators.builtin.SendMediator.mediate(SendMediator.java:92)
at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:49)
at org.apache.synapse.mediators.filters.InMediator.mediate(InMediator.java:54)
at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:49)
at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:104)
at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:143)
at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:49)
at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:104)
at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:104)
at org.apache.synapse.core.axis2.SynapseMessageReceiver.receive(SynapseMessageReceiver.java:73)
at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:144)
at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:279)
at org.apache.axis2.transport.nhttp.ServerWorker.processPost(ServerWorker.java:200)
at org.apache.axis2.transport.nhttp.ServerWorker.run(ServerWorker.java:167)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)
******************************************************************************************************************************