【发布时间】:2016-05-24 10:47:33
【问题描述】:
感谢关注
我在spring集成中使用int-ftp:inbound-channel-adapter,我想从ftp服务器检索文件并在其上处理,并将备份保存在本地目录中,但是当应用程序处于启动状态int-ftp:inbound-channel-adapter从备份位置的本地旧文件创建消息并尝试发送如下引导我的代码:
<bean id="acceptOnceFilter"
class="org.springframework.integration.file.filters.AcceptOnceFileListFilter" />
<int-ftp:inbound-channel-adapter id="sam-inbound-channel-adapter"
channel="sam-ready-to-process-inbound"
session-factory="sam-ftp-Session"
auto-create-local-directory="true"
delete-remote-files="true"
auto-startup="true"
filename-pattern="*.bmp"
remote-directory="/in/"
remote-file-separator="/"
local-filter="acceptOnceFilter"
preserve-timestamp="true"
local-filename-generator-expression="@fileName.name('sam',#this)"
temporary-file-suffix=".writing"
local-directory="./backup/sam/in//">
<int:poller fixed-rate="10000"/>
</int-ftp:inbound-channel-adapter>
提前致谢
【问题讨论】:
标签: java spring-boot spring-integration spring-batch