I know that the I/O Adapter polling operation will detect a file that is being FTP’d before the FTP process is complete. I had to put a custom code step in the component that was triggered by the polling operation to read each line (using buffered java reads) to end of file, testing to see if the trailer record existed yet. If it didn’t exist, I did a thread.sleep for 2 minutes and then looked again. Once the trailer record was found, I allowed the integration to continue.
This worked well for awhile until one day we got a String Index Out Of Range exception in the custom Java code. That was because in a rare instance, my Java read got only 1/2 of a line (FTP process was in the process of writing that line at the same time as the read) and the string function I used to look at a field in the record tried to access past the end of the line. To fix this I added code to test for the length of the line, and if it was not a full record, I assumed the FTP was not complete and went into the sleep logic.