Routes deployed on dual runtime servers

When a Route (which has a cFtp component) is deployed on multiple runtime servers, it consumes the file from the FTP at the same time and creates a duplicate. This is expected behavior.

 

Best practice

Talend suggests deploying a Route on a single runtime server. If there is a requirement to deploy it on multiple runtime servers, you must redesign the logic accordingly, as FTP Route consumers are not thread-safe.

 

This is a limitation of Apache Camel > FTP components.

 

You can use the readLock option to force Camel to not consume files currently being written. However, this option is turned off by default, as it requires that you have write access.

 

There are other solutions for avoiding consuming files currently being written over FTP; for example, you can write to a temporary destination, and move the file after it has been written.

 

When moving files using the move or preMove options, the files are restricted to the FTP_ROOT folder. That prevents you from moving them outside of the FTP area. If you want to move files to another area, you can use soft links and move them into a soft-linked folder.

 

For more information, see Apache Camel.

Version history
Revision #:
9 of 9
Last update:
‎05-21-2018 01:43 PM
Updated by: