几年来,我一直在使用 Spring-Integration 4.1.6 连接到旧的 FTP 服务器。FTP 服务器最近被更新的版本(新服务器是 Globalscape EFT Enterprise)替换,我的 int-ftp 入站通道适配器立即停止查找文件。我监视了几个帐户,它们都同时停止工作。
下面是其中一个的配置:
<beans:bean id="ftpSessionFactory" class="org.springframework.integration.ftp.session.DefaultFtpSessionFactory">
<beans:property name="host" value="${ftp.host}" />
<beans:property name="port" value="${ftp.port}" />
<beans:property name="username" value="${ftp.username}" />
<beans:property name="password" value="${ftp.password}" />
<beans:property name="clientMode" value="2" />
<beans:property name="fileType" value="2" />
<beans:property name="bufferSize" value="5000000" />
</beans:bean>
<beans:bean id="cachingSessionFactory" class="org.springframework.integration.file.remote.session.CachingSessionFactory">
<beans:constructor-arg ref="ftpSessionFactory" />
<beans:constructor-arg value="1" />
<beans:property name="sessionWaitTimeout" value="60000" />
</beans:bean>
<int-ftp:inbound-channel-adapter id="ftpInboundChannelAdapter" channel="ftpChannelIn" session-factory="cachingSessionFactory" auto-create-local-directory="true"
delete-remote-files="true" remote-directory="dev" local-directory="C:/temp" auto-startup="true">
<poller max-messages-per-poll="-1" receive-timeout="10000" cron="0 0/2 * * * *" >
<transactional/>
</poller>
</int-ftp:inbound-channel-adapter>
当我调试适配器时,我看到了这个语句:
[org.springframework.integration.ftp.inbound.FtpInboundFileSynchronizer] cannot copy, not a file: dev/dev
但是 dev 下面没有名为 dev 的文件夹,只有一个 .csv 文件。
结构是 /path/to/user/dev/file.csv 并且 FTP 服务器配置为在用户执行 PWD 时向用户显示整个路径。
而且我确信当登录发生时,它们被放置在 /path/to/user 文件夹中。
我在本地环境中建立了另一个 FTP 服务器,它运行良好。
某些非标准 FTP 服务器是否存在导致此类问题的问题?
先感谢您