0
votes

<?xml version="1.0" encoding="UTF-8" ?>
<proxy name="VFS_RTDB_Proxy" serviceGroup="" startOnLoad="true" trace="enable" transports="vfs" xmlns="http://ws.apache.org/ns/synapse">
  <target>
    <inSequence>
      <payloadFactory media-type="json">
        <format>{rtdatas:$1}</format>
        <args>
          <arg expression="get-property('rtDataSets')" />
        </args>
      </payloadFactory>
      <send>
        <endpoint>
          <address format="rest" statistics="enable" trace="enable" uri="http://211.154.164.28:9666/services/oge/vzdb/post/history" />
        </endpoint>
      </send>
    </inSequence>
  </target>
  <parameter name="transport.vfs.Streaming">true</parameter>
  <parameter name="transport.PollInterval">2</parameter>
  <parameter name="transport.vfs.ContentType">text/plain</parameter>
  <parameter name="transport.vfs.ActionAfterProcess">MOVE</parameter>
  <parameter name="transport.vfs.ActionAfterProces">MOVE</parameter>
  <parameter name="transport.vfs.FileURI">D:\exportRTDB</parameter>
  <parameter name="transport.vfs.FileURI">G:\MoveAfterFailure</parameter>

  <parameter name="transport.vfs.MoveAfterFailure">G:\MoveAfterFailure</parameter>
  <parameter name="transport.vfs.FileNamePattern">.*.csv</parameter>
  <parameter name="transport.vfs.ActionAfterFailure">MOVE</parameter>
</proxy>

Why does Send Mediator not execute? When I set Address Endpoint wrapped in Call Mediator, this doesn't execute either. How can I solve this?

When wrapped in Call Mediator, I get follow error:

[2016-03-30 20:31:25,550] INFO - BuilderUtil OMException in getSOAPBuilder org.apache.axiom.soap.SOAPProcessingException: First Element must contain the local name, Envelope , but found html at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.constructNode(StAXSOAPModelBuilder.java:305) at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.createOMElement(StAXSOAPModelBuilder.java:252) at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.createNextOMElement(StAXSOAPModelBuilder.java:234) at org.apache.axiom.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:249) at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.getSOAPEnvelope(StAXSOAPModelBuilder.java:204) at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.(StAXSOAPModelBuilder.java:154) at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.(StAXSOAPModelBuilder.java:140) at org.apache.axis2.builder.BuilderUtil.getSOAPBuilder(BuilderUtil.java:659) at org.apache.axis2.transport.TransportUtils.createDocumentElement(TransportUtils.java:206) at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.java:146) at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.java:109) at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.java:68) at org.apache.axis2.description.OutInAxisOperationClient.handleResponse(OutInAxisOperation.java:348) at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:445) at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:225) at org.apache.axis2.client.OperationClient.execute(OperationClient.java:149) at org.apache.synapse.message.senders.blocking.BlockingMsgSender.sendReceive(BlockingMsgSender.java:254) at org.apache.synapse.message.senders.blocking.BlockingMsgSender.send(BlockingMsgSender.java:175) at org.apache.synapse.mediators.builtin.CallMediator.handleBlockingCall(CallMediator.java:113) at org.apache.synapse.mediators.builtin.CallMediator.mediate(CallMediator.java:85) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:81) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:48) at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:149) at org.apache.synapse.core.axis2.ProxyServiceMessageReceiver.receive(ProxyServiceMessageReceiver.java:185) at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180) at org.apache.axis2.transport.base.AbstractTransportListener.handleIncomingMessage(AbstractTransportListener.java:328) at org.apache.synapse.transport.vfs.VFSTransportListener.processFile(VFSTransportListener.java:751) at org.apache.synapse.transport.vfs.VFSTransportListener.scanFileOrDirectory(VFSTransportListener.java:407) at org.apache.synapse.transport.vfs.VFSTransportListener.poll(VFSTransportListener.java:177) at org.apache.synapse.transport.vfs.VFSTransportListener.poll(VFSTransportListener.java:124) at org.apache.axis2.transport.base.AbstractPollingTransportListener$1$1.run(AbstractPollingTransportListener.java:67) 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-03-30 20:31:25,635] INFO - BuilderUtil Remaining input stream :[] [2016-03-30 20:31:25,635] WARN - FaultHandler ERROR_CODE : 401000 [2016-03-30 20:31:25,651] WARN - FaultHandler ERROR_MESSAGE : First Element must contain the local name, Envelope , but found html [2016-03-30 20:31:25,651] WARN - FaultHandler ERROR_DETAIL : [2016-03-30 20:31:25,651] WARN - FaultHandler ERROR_EXCEPTION : org.apache.synapse.SynapseException: Error while performing the call operation [2016-03-30 20:31:25,651] WARN - FaultHandler FaultHandler : org.apache.synapse.mediators.MediatorFaultHandler@4207ac5d [2016-03-30 20:31:25,651] WARN - MediatorFaultHandler Executing fault handler mediator : org.apache.synapse.mediators.base.SequenceMediator

1
Are you getting any errors?Thusitha Thilina Dayaratne
@ThusithaThilinaDayaratne When I wrapped in Call Mediator,get follow error, please view my answerProEditor

1 Answers

0
votes

The follow is changed proxy config, Get error By follow config;I have not publish proxy as WSDL,so I did not found web Page....

<?xml version="1.0" encoding="UTF-8"?>
<proxy name="VFS_RTDB_Proxy" serviceGroup="" startOnLoad="true"
  trace="enable" transports="vfs" xmlns="http://ws.apache.org/ns/synapse">
   <localEntry key="smooks-key" src="file:repository/samples/resources/smooks/smooks-config.xml"/>
  <target>
    <inSequence>
           <class description="" name="cn.oge.kdm.mediator.RTDataSetMediator"/>
<!--      <log description="" level="custom">
        <property expression="get-property('rtDataSets')" name="RTDATASET"/>
      </log> -->
      <payloadFactory media-type="json">
        <format>{"rtdatas":$1}</format>
        <args>
          <arg expression="get-property('rtDataSets')"/>
        </args>
      </payloadFactory>
        <call blocking="true">
           <endpoint>
           <address  statistics="enable" trace="enable" uri="http://211.154.164.98:9766/services/oge/vzdb/post/history"/>
        </endpoint>
        </call>
          </inSequence>
    <outSequence>

      <!-- <log level="full"/> -->
      <property name="OUT_ONLY" scope="default" type="STRING" value="true"/>
      <property
        expression="fn:concat(fn:substring-after(get-property('MessageID'), 'urn:uuid:'), '.xml')"
        name="transport.vfs.ReplyFileName" scope="transport" type="STRING"/>
    </outSequence>
    <faultSequence>
     <!--  <class description="" name="cn.oge.kdm.mediator.DecompressionMediator"/> -->
      <log level="full"/>
    </faultSequence>
  </target>
  <parameter name="transport.vfs.Streaming">true</parameter>
  <parameter name="transport.PollInterval">2</parameter>
  <parameter name="transport.vfs.ContentType">text/plain</parameter>
  <parameter name="transport.vfs.ActionAfterProcess">MOVE</parameter>
  <parameter name="transport.vfs.ActionAfterProces">MOVE</parameter>
  <parameter name="transport.vfs.FileURI">D:\exportRTDB</parameter>
  <parameter name="transport.vfs.MoveAfterProcess">vfs:ftp://ProEditor:****@211.154.164.99/</parameter>
  <parameter name="transport.vfs.MoveAfterFailure">G:\MoveAfterFailure</parameter>
  <parameter name="transport.vfs.FileNamePattern">.*.csv</parameter>
  <parameter name="transport.vfs.ActionAfterFailure">MOVE</parameter>
</proxy>