You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by MohanN <ma...@gmail.com> on 2009/01/02 19:58:04 UTC

Time out Setting [commons NET/FTP]

Hi,
Can someone please help me? 
I am new to the FTP Client stuff. 
I need to transfer the files from my server to other remote servers. 
I have a batch Job running which will transfer the files using the Apache
FTPClient. 
If there are any issues like network issues we need to send out an email
Notification to customer support people so they can escalate the issue. We
know the Size of the file and how much time it takes to transfer the files
in ideal case. But we had seen some cases where it took more than 15 minutes
to transfer just 10KB files. We want to send email if that happens again. 
What kind of timeout settings I need to set?
I am using Apache common net 2.0 and Java 5. 
I really appreciate your help. 
Thanks, 
Mohan N 
-- 
View this message in context: http://www.nabble.com/Time-out-Setting--commons-NET-FTP--tp21255584p21255584.html
Sent from the Commons - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Re: Time out Setting [commons NET/FTP]

Posted by chitraa <ac...@gmail.com>.
Hi,
Have you tried calling the FTPClient's setSoTimeout(timeout) method after
calling its connect() method?

Then, when your trying to retrieve the file (using the retrieveFile method),
you can catch the IOException and send out your email.


MohanN wrote:
> 
> Hi,
> Can someone please help me? 
> I am new to the FTP Client stuff. 
> I need to transfer the files from my server to other remote servers. 
> I have a batch Job running which will transfer the files using the Apache
> FTPClient. 
> If there are any issues like network issues we need to send out an email
> Notification to customer support people so they can escalate the issue. We
> know the Size of the file and how much time it takes to transfer the files
> in ideal case. But we had seen some cases where it took more than 15
> minutes to transfer just 10KB files. We want to send email if that happens
> again. 
> What kind of timeout settings I need to set?
> I am using Apache common net 2.0 and Java 5. 
> I really appreciate your help. 
> Thanks, 
> Mohan N 
> 

-- 
View this message in context: http://www.nabble.com/Time-out-Setting--commons-NET-FTP--tp21255584p21700606.html
Sent from the Commons - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org