Skip to Content
0
Former Member
Dec 06, 2006 at 02:22 PM

File Adapter Overwriting the output files

103 Views

Hi All,

I´m using a File Receiver Adapter to write flat files on to an FTP. Same Communication Channel is used for all types of output files (As per the business requirement the file name(

MzOutput.txt

) shud b same for Deliverz orders, Purchase orders etc...). The receiver legacz szstem reads one file at atime and deletes it. So if i´m writing a Deliverz Order File, i have to wait until the file

MzOutput.txt

gets deleted and then i have to write the next file using the same name. in order to acheive this, i had used a module processor which waits until that

MzOutput.txt

gets deleted. Mz problem is

As there are ´n´ no of orders waiting in the queue, if at 12:14:00 the

MzOutput.txt

gets deleted, then two threads which check for the existance of the

MzOutput.txt

file finds nothing and tries to write at same time. as a result, first file got overwritten by the second file.
I dint check the indicator

OverwriteExisting File

in the CC configuration.

If i use two different CC channels to write the same file, it is giving FTP Exception which is true.

I´m loosing few deliveries as a result of the above case. Can anzone please help me out in this regard?

Thnx in Advance

Anil