thanks for attention
i used int-ftp:outbound-gateway
with mget
command, i want to when retrieve file from server if file that retrieve from server exists in local directory then thrown bellow exception :
org.springframework.messaging.MessagingException: Local file .\backup\a\in\a.in already exists
adapter code is:
<int-ftp:outbound-gateway id="gatewayGET"
local-directory-expression="'./backup/' +#remoteDirectory"
session-factory="ftpSessionFactory"
request-channel="toGet"
reply-channel="toRemoveChannel"
command="mget"
command-options="-R"
expression="payload.remoteDirectory + '/' + payload.filename"/>
thans for help me.