Hi I have come across several blogs and forums and I am still unable to achieve the dynamic endpoint url update.My requirement is to update the API endpoint url based on the request parameter value. Hence I am trying to use Dynamic Endpoint feature in WSO2 Api Manager 2.6.0. I have uploaded the in flow sequence with the below code. But I still get the error.
In flow Code:
<sequence xmlns="http://ws.apache.org/ns/synapse" name="admin--dynamicAPI_v1.0" trace ="enable">
<property name="REST_URL_POSTFIX" scope="axis2" action="remove"/>
<log level="full">
<property name="headerTo" value="http://actualurl/tobe/redirected"/>
<header name="To" expression="get-property('headerTo')"/>
<property name="ENDPOINT_ADDRESS" value="http://actualurl/tobe/redirected"/>
</log>
</sequence>
Error:
TID: [-1234] [] [2020-06-02 10:37:33,154] INFO {org.apache.synapse.mediators.builtin.LogMediator} - To: /service/1.0/, MessageID: urn:uuid:c341daaf-300e-4cdd-b6cd-ba0a7cb4b49d, Direction: request, headerTo = http://actualurl/tobe/redirected, ENDPOINT_ADDRESS = http://actualurl/tobe/redirected, Envelope: {org.apache.synapse.mediators.builtin.LogMediator} TID: [-1234] [] [2020-06-02 10:37:33,156] ERROR {org.apache.axis2.description.ClientUtils} - The system cannot infer the transport information from the /service/1.0/* URL. {org.apache.axis2.description.ClientUtils} TID: [-1234] [] [2020-06-02 10:37:33,156] ERROR {org.apache.synapse.core.axis2.Axis2Sender} - Unexpected error during sending message out {org.apache.synapse.core.axis2.Axis2Sender} org.apache.axis2.AxisFault: The system cannot infer the transport information from the /service/1.0/* URL. at org.apache.axis2.description.ClientUtils.inferOutTransport(ClientUtils.java:86) at org.apache.synapse.core.axis2.DynamicAxisOperation$DynamicOperationClient.executeImpl(DynamicAxisOperation.java:116) at org.apache.axis2.client.OperationClient.execute(OperationClient.java:149) at org.apache.synapse.core.axis2.Axis2FlexibleMEPClient.send(Axis2FlexibleMEPClient.java:603) at org.apache.synapse.core.axis2.Axis2Sender.sendOn(Axis2Sender.java:85) at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.send(Axis2SynapseEnvironment.java:547) at org.apache.synapse.endpoints.AbstractEndpoint.send(AbstractEndpoint.java:384) at org.apache.synapse.endpoints.DefaultEndpoint.send(DefaultEndpoint.java:77) at org.apache.synapse.endpoints.IndirectEndpoint.send(IndirectEndpoint.java:55) at org.apache.synapse.mediators.builtin.SendMediator.mediate(SendMediator.java:123) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:108) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:70) at org.apache.synapse.mediators.filters.FilterMediator.mediate(FilterMediator.java:169) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:108) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:70) at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:158) at org.apache.synapse.rest.Resource.process(Resource.java:351) at org.apache.synapse.rest.API.process(API.java:399) at org.apache.synapse.rest.RESTRequestHandler.apiProcessNonDefaultStrategy(RESTRequestHandler.java:149) at org.apache.synapse.rest.RESTRequestHandler.dispatchToAPI(RESTRequestHandler.java:95) at org.apache.synapse.rest.RESTRequestHandler.process(RESTRequestHandler.java:71) at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:303) at org.apache.synapse.core.axis2.SynapseMessageReceiver.receive(SynapseMessageReceiver.java:92) at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180) at org.apache.synapse.transport.passthru.ServerWorker.processNonEntityEnclosingRESTHandler(ServerWorker.java:337) at org.apache.synapse.transport.passthru.ServerWorker.run(ServerWorker.java:158) at org.apache.axis2.transport.base.threads.NativeWorkerPool$1.run(NativeWorkerPool.java:172) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)*