<div>I used to put the file with temp name and client renaming the file name after finishing uploading the file. Of course the server is polling the specific file name extension on the other hand.</div>
<div>However, I found out that this is not enough. Occasionally and specially the file system is NFS and the file is big, this doesn't work well.</div>
<div> </div>
<div>So I come up with other method. Each file consist of 2 component. Real file and specification file.</div>
<div> </div>
<div>Ex) </div>
<div> </div>
<div>- A.exe + A.spec : A.spec has MD5 hash of A.exe and file name</div>
<div>- Upload A.exe first</div>
<div>- Upload A.spec.lock</div>
<div>- Rename A.spec.lock to A.spec</div>
<div>- Meanwhile Server polling *.spec </div>
<div>- Read A.spec</div>
<div>- MD5 (A.exe) and compare with MD5 value in A.spec</div>
<div>- Finally get the A.exe</div>
<div><br><br> </div>
<div><span class="gmail_quote">On 8/30/05, <b class="gmail_sendername">Sebastian Bello</b> <<a href="mailto:sebastian@inswitch.us">sebastian@inswitch.us</a>> wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div>Hi list,</div>
<div> </div>
<div>I need to process files received via ftp.</div>
<div>I see two approaches:</div>
<div> </div>
<div>    1. poll the ftp directory</div>
<div>
<div>    How can I make sure a file download has finished?</div></div>
<div> </div>
<div>    2. use a specialized ftp server which triggers file processing after receipt.</div>
<div>    I've been trying the Erlang ftpd implementation. File uploads seems not to work with a Windows client. And I'm not 100% sure they work fine with a Linux one. Has anybody used ftpd in a production environment?</div>

<div> </div>
<div>Any hints?</div>
<div> </div>
<div>Thanks,</div>
<div>    Sebastian-</div>
<div> </div>
<div> </div>
<div>
<table width="77%" border="0">
<tbody>
<tr>
<td valign="top" width="16%"><img src="cid:018f01c5ad9f$0e77ba60$dc00a8c0@INSWITCH244"></td>
<td valign="top" width="84%">
<p><b><font face="Verdana" color="#000099" size="1">Prepaid Expertise - Programmable Switches <br>Powered by Ericsson Licensed Technology<br>Sebastián Bello - Engineer - Development Center - IN Switch Solutions Inc.<br>Headquarters - 
Miami-U.S.A. Tel: 1305-3578076 Fax: 1305-7686260<br>Development Center - Montevideo - Uruguay Tel/Fax: 5982-7104457<br>IN SWITCH EMEA Phone: +33 0 6 0335 9427 - Fax: +33 0 4 93655773 / <a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:emea@inswitch.us" target="_blank">
emea@inswitch.us</a><br>IN SWITCH ASIA Phone: +92 51 2800397/8- Fax: +92 51 2800399/ <a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:inswasia@inswitch.us" target="_blank">inswasia@inswitch.us</a><br>
e-mail: <a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:sebastian@inswitch.us" target="_blank">sebastian@inswitch.us</a></font><font face="Verdana" color="blue" size="1"><br></font></b></p></td></tr>
</tbody></table><b><font face="Verdana" color="blue" size="1"></font></b></div>  <br clear="all"></blockquote></div><br>