3

i am trying to send a file over SFTP using mule . We have to specify a fixed path for that , like /home/ftp/ and then file name in outputpattern . but i want to create directories on the fly on remote location . everytime a file is sent , it should be sent in a new directory .

like abc.txt : /home/ftp/abc/abc.txt

pqr.txt : /home/ftp/pqqw/pqr.txt

somaniA
  • 614
  • 2
  • 7
  • 30

2 Answers2

1

I have implemented this by overridingFtpMessageDispatcher in MULE . Here is the blog post about it

somaniA
  • 614
  • 2
  • 7
  • 30
0

I would say that you need a custom java component for this folder creation.

http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/transport/sftp/SftpClient.html#createSftpDirIfNotExists(org.mule.api.endpoint.ImmutableEndpoint,%20java.lang.String)

Zlatin Zlatev
  • 3,034
  • 1
  • 24
  • 32
  • okay , that is what i was thinking about . Is it possible to change existing sftp connector implementation ? so that my flow code would be least modified ? – somaniA Sep 09 '14 at 10:40