OL Learn

ftp input picks up file while it's still uploading and deletes it.

I’m having an issue with ftp input.

it’s connected to our clients ftp

ftp input picks up the file while it’s still uploading from the clients side and removes it.

ofcourse this file is broken.

is there a way to check if a file is done uploading/ still growing?

kind regards,

Koen

Hi Koen,

That behavior is normal. I have seen the OL devs explain this a few times. The only way is for your client to upload the files until all files are done uploading. They then upload a text file called trigger.txt .(which can be empty but then if your are using a folder capture, it must be set to “Include empty files”) You then set your process FTP Input Mask to trigger.txt. Once Workflow sees that file it will grab it and you can then use another FTP Input task to grab the files you want.

EDITED: Makes more sense now.

Regards,

S

An alternative to sharne’s advice would be to have your FTP process pick up at a specified schedule. For example, your client has until 10am to drop their files for the day. At 10:30 (gives you a little leeway) your process runs and picks the files. As long as it’s clear with your client that they aren’t allowed to drop after the cutoff period, you shouldn’t encounter any issues.

thanks, I Also thought about this but I can’t ask the clients to creat an extra file

The problem is that when the file is recieved whe have to process it.

I already put a delay on it for 15 minutes, but that doesn’t work all the time.

There are at least 2 more options, beside the already proposed, I can think of.

  1. The uploader could upload the file under a name, you are not watching for (for example “data.csv.writing”) and rename it, after the upload finishes (to “data.csv”, you are watching for). This is fairly easy to do with almost every (s)ftp client.

  2. An extension to the trigger file proposal: If you cannot ask the client to supply the trigger, create 2 Processes watching the same input folder. The second one checks for the trigger file and does the work, when the file is there. The first one checks the last modified modified date of the uploaded file, if there is one, and if the file was not modified in a some predefined period of time, creates the trigger, so the process nr. 2 can start.

Best regards

-i.

Hi,

The site was down so I could not reply. I had another thought, but untested. What if your process monitors an email. The client can setup the FTP to email you once the files are uploaded. Your process then waits for an email and then processes the files. I read a few suggestions here.

But again, I have not tested this theory, just an idea.

Regards,

S

thanks for your comments, for now I instructed the client to send us an email when the upload is ready.

This is not done automaticly so I cannot use this as a trigger.