骡子FTP下载默认删除

时间:2017-06-25 04:16:20

标签: mule mule-studio mule-component mule-el

使用mule ftp:inbound-endpoint如何

  • 使用文件名过滤器查找文件“ CurrentMonth(MMM) .csv”并在本地服务器目录中下载副本。
  • 下载完成后,请关闭默认删除功能,以免在ftp网站上进行任何更改。

以下是流配置 <flow name="ftpFlow1"> <ftp:inbound-endpoint host="apca.com.au" port="21" responseTimeout="10000" doc:name="FTP"/> </flow>

提前感谢您的帮助。

1 个答案:

答案 0 :(得分:0)

这可能会有所帮助:

&#13;
&#13;
<?xml version="1.0" encoding="UTF-8"?>

<mule xmlns:file="http://www.mulesoft.org/schema/mule/file" xmlns:scripting="http://www.mulesoft.org/schema/mule/scripting" xmlns:objectstore="http://www.mulesoft.org/schema/mule/objectstore" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
	xmlns:spring="http://www.springframework.org/schema/beans" 
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/objectstore http://www.mulesoft.org/schema/mule/objectstore/current/mule-objectstore.xsd
http://www.mulesoft.org/schema/mule/scripting http://www.mulesoft.org/schema/mule/scripting/current/mule-scripting.xsd
http://www.mulesoft.org/schema/mule/file http://www.mulesoft.org/schema/mule/file/current/mule-file.xsd">
    <objectstore:config name="ObjectStore__Connector" partition="testObjec" doc:name="ObjectStore: Connector"/>
    <file:endpoint path="inp_path" moveToPattern="doloaded_file_name" moveToDirectory="local_directory_to_download" name="File" responseTimeout="10000" doc:name="File">
        <file:filename-regex-filter pattern="CurrentMonth(MMM).csv" caseSensitive="true"/>
    </file:endpoint>
    <flow name="testFlow">
        <poll doc:name="Poll">
            <file:outbound-endpoint responseTimeout="10000" ref="File" doc:name="File"/>
        </poll>
    </flow>

 
</mule>
&#13;
&#13;
&#13;