I'm not sure but I can't add a poller to my sftp outbound gateway. I tried doing it but I have no luck, it does not poll during start up so I have created a service interface and then just call the method via scheduler. Is there a better way to do it? Here is snippet of what I did :
<int:channel channel="requestChannel"
<int:queue />
</int:channel>
<int-sftp:outbound-gateway id="ls"
auto-startup="true"
expression="payload"
request-channel="requestChannel"
remote-directory="${remote-directory}"
command-options="-1"
session-factory="sftpSessionFactory"
command="ls"
reply-channel="replyChannel">
<int:poller fixed-delay="10000" max-messages-per-poll="1"/>
</int-sftp:outbound-gateway>