我的要求是需要上传文件,然后需要将文件移动到处理中。有时我看到错误说文件被移动或删除。这可能是因为文件在文件传输完全完成之前被移动到进程。
配置是
<int:publish-subscribe-channel id="publishToSFTPChannel" ></int:publish-subscribe-channel>
<file:inbound-channel-adapter
directory="file:#{configurationService.configuration.getProperty('csv.export.file.location')}"
id="fileInbound" channel="publishToSFTPChannel" filename-pattern="*.csv" >
<int:poller fixed-rate="11000" max-messages-per-poll="100"/>
</file:inbound-channel-adapter>
<int-sftp:outbound-channel-adapter id="sftpOutboundAdapter"
session-factory="sftpSessionFactory"
channel="publishToSFTPChannel"
charset="UTF-8"
remote-directory="#{csvRemoteDirectory}"
remote-file-separator="/" order="1" />
<file:outbound-channel-adapter id="moveProcessedFile"
channel="publishToSFTPChannel"
directory="file:#{configurationService.configuration.getProperty('auspost.csv.export.file.location')}/${tenantId}/processed"
您能否提供一些输入如何在订单 1 完成之前保留订单 2