Transferring files is usually required in big integrations where we need to move some files without processing them. For example, we can be polling for a file in a local directory and once the file appears, we move it to another folder, such as a remote FTP server. In that scenario, we must take care of big files in order to not use too much memory resources (refer to the Large files configuration section at the beginning of the chapter).
In the next example, we will use an inboundEndpoint to poll a directory for a file, and then we will send that file to a FTP server. In order to do that, we need to create two resources: the inboundEndpoint that is waiting for the file, and a sequence that will send the file to the remote FTP server:
<inboundEndpoint name="TransferFile" onError="fault" protocol="file" sequence="TransferFileSequence...