简体   繁体   English

Spring Integration SFTP上传非XML配置

[英]Spring Integration SFTP Upload non-XML Configuration

I have been scouring the internet for ways to setup the sftp outbound gateway using the annotation configuration system. 我一直在互联网上搜寻使用注释配置系统设置sftp出站网关的方法。 So far I have come up empty. 到目前为止,我已经空了。

So is there a way to configure the following XML in the Java code with the help of Spring Annotations? 那么,有什么方法可以借助Spring Annotations在Java代码中配置以下XML?

<int-sftp:outbound-gateway id="gatewayLS"
                           session-factory="sftpSessionFactory"
                           request-channel="inbound"
                           command="ls"
                           command-options=""
                           expression="payload"
                           reply-channel="toSplitter"/>

We have been adding java config to the manual as time permits. 在时间允许的情况下,我们一直在手册中添加java config。

See the file section for an example using the file outbound channel adapter. 有关使用文件出站通道适配器的示例,请参见文件部分

For SFTP, the MessageHandler is a FileTransferringMessageHandler - it needs to be configured with the session factory etc. 对于SFTP, MessageHandlerFileTransferringMessageHandler需要使用会话工厂等进行配置。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM