Hi Malaka, I tried the scenario with this proxy configuration. This works fine as expected
<proxy xmlns="http://ws.apache.org/ns/synapse" name="testProxy" transports="https,http" statistics="disable" trace="disable" startOnLoad="true"> <target> <inSequence> <property name="test" value="TESTVAL"/> <property name="conf:/Resource/foo" expression="$ctx:test" scope="registry"/> <respond/> </inSequence> <outSequence> <log/> <send/> </outSequence> </target> <parameter name="serviceType">proxy</parameter> <description/> </proxy> Regards On Mon, Feb 8, 2016 at 4:43 PM, Malaka Silva <[email protected]> wrote: > Hi, > > I guess it does not support dynamic names (expression) when persiting.If > do go ahead with script mediator. > > @Nadeeshaan - Can you please confirm. > > ---------- Forwarded message ---------- > From: Hariprasath Thanarajah <[email protected]> > Date: Mon, Feb 8, 2016 at 4:30 PM > Subject: Error while creating init for 4.10 > To: Malaka Silva <[email protected]> > Cc: Keerthika Mahendralingam <[email protected]>, Kesavan Yogarajah < > [email protected]> > > > Hi Malaka, > > IMHO we can create the salesforce REST connector will support all the ESB > versions. Since there are no difference in performance while we are using > script or property mediator. > Is there any particular reason to create Salesforce REST for 4.10 only by > using property mediator? > > I have an issue in use the user defined path to store the values in > registry using property mediator. > > This is how i used to store the value in Registry. > <property name="$ctx:uri.var.timeRegistryPath" > expression="$ctx:systemTime" scope="registry"/> > > Here the value is store in $ctx:uei.var.timeRegistryPath > > and > > If i using this, > > <property name="get-property('uri.var.timeRegistryPath')" > expression="$ctx:systemTime" scope="registry"/> > > i got the below error, > > ERROR - WSO2Registry Error while saving a resource at > get-property('uri.var.timeRegistryPath') > org.wso2.carbon.registry.core.exceptions.RegistryException: The path > '/_system/governance/get-property('uri.var.timeRegistryPath')' contains one > or more illegal characters (~!@#;%^*()+={}|\<>"',) > at > org.wso2.carbon.registry.core.jdbc.Repository.put(Repository.java:262) > at > org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.put(EmbeddedRegistry.java:709) > at > org.wso2.carbon.registry.core.caching.CacheBackedRegistry.put(CacheBackedRegistry.java:508) > at > org.wso2.carbon.registry.core.session.UserRegistry.putInternal(UserRegistry.java:824) > at > org.wso2.carbon.registry.core.session.UserRegistry.access$1000(UserRegistry.java:60) > at > org.wso2.carbon.registry.core.session.UserRegistry$11.run(UserRegistry.java:800) > at > org.wso2.carbon.registry.core.session.UserRegistry$11.run(UserRegistry.java:797) > at java.security.AccessController.doPrivileged(Native Method) > at > org.wso2.carbon.registry.core.session.UserRegistry.put(UserRegistry.java:797) > at > org.wso2.carbon.mediation.registry.WSO2Registry.newNonEmptyResource(WSO2Registry.java:360) > at > org.apache.synapse.mediators.builtin.PropertyMediator.mediate(PropertyMediator.java:193) > at > org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:81) > at > org.apache.synapse.mediators.filters.FilterMediator.mediate(FilterMediator.java:236) > at > org.apache.synapse.mediators.filters.FilterMediator.mediate(FilterMediator.java:240) > at > org.apache.synapse.mediators.template.InvokeMediator.mediate(InvokeMediator.java:169) > at > org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:273) > at > org.apache.synapse.core.axis2.Axis2SynapseEnvironment.mediateFromContinuationStateStack(Axis2SynapseEnvironment.java:728) > at > org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:273) > at > org.apache.synapse.core.axis2.SynapseCallbackReceiver.handleMessage(SynapseCallbackReceiver.java:529) > at > org.apache.synapse.core.axis2.SynapseCallbackReceiver.receive(SynapseCallbackReceiver.java:172) > at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180) > at > org.apache.synapse.transport.passthru.ClientWorker.run(ClientWorker.java:251) > at > org.apache.axis2.transport.base.threads.NativeWorkerPool$1.run(NativeWorkerPool.java:172) > at > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) > at > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) > at java.lang.Thread.run(Thread.java:745) > [2016-02-08 16:01:03,099] INFO - LogMediator To: > http://www.w3.org/2005/08/addressing/anonymous, WSAction: , SOAPAction: , > MessageID: urn:uuid:24c7cbf4-5793-45b1-8cfa-0e8cbee6fd3e, Direction: > request, MESSAGE = Executing default 'fault' sequence, ERROR_CODE = 0, > ERROR_MESSAGE = Error while saving a resource at > get-property('uri.var.timeRegistryPath'), Payload: > {"access_token":"00D280000017q6q!AQoAQElnJSR6Y3gtxVfqDa_OJl38YmOGJscq6iDCZ.6lfkWSCsmmWp9d669_vWAmL9wnWdbuogXNpDMB_MHQCAjDOWHuRZdL","signature":"9XnwazD8C9igR3rEc9y4BNpea60J5z1e3ABj72r6BuY=","scope":"visualforce > refresh_token wave_api web custom_permissions openid chatter_api api id > full","instance_url":"https://ap2.salesforce.com","id":" > https://login.salesforce.com/id/00D280000017q6qEAA/00528000001m5RRAAY > ","token_type":"Bearer","issued_at":"1454927462120"} > > Can i use the script mediator to store the values in Registry? > > -- > > > *Thank you and Regards**Hariprasath Thanarajah* > Associate Software Engineer | WSO2 > E: [email protected] > M: +94752806528 > > > > > -- > > Best Regards, > > Malaka Silva > Senior Tech Lead > M: +94 777 219 791 > Tel : 94 11 214 5345 > Fax :94 11 2145300 > Skype : malaka.sampath.silva > LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77 > Blog : http://mrmalakasilva.blogspot.com/ > > WSO2, Inc. > lean . enterprise . middleware > http://www.wso2.com/ > http://www.wso2.com/about/team/malaka-silva/ > <http://wso2.com/about/team/malaka-silva/> > https://store.wso2.com/store/ > > Save a tree -Conserve nature & Save the world for your future. Print this > email only if it is absolutely necessary. >
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
