commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gert Vanthienen <gert.vanthie...@skynet.be>
Subject Re: [net] FTPClient.listFiles stalls...
Date Sun, 15 Apr 2007 09:33:36 GMT

Rory,

Do you have any idea when this version will be publicly released (for
inclusion in ServiceMix's components)?

Regards,

Gert




Rory Winston wrote:
> 
> Hi Gert
> 
> There may be a combination of issues here. Can you try the 2.0 RC?
> 
> http://people.apache.org/~rwinston/commons-net-2.0/commons-net-ftp-2.0.0-SNAPSHOT.jar
> 
> You will need to be running JDK 5.0/6.0 for this. This has fixes for
> various threading issues. Of course, if you are constrained toJDK 1.4.x,
> this wont work for you. As regards the potential IIS issue, this is
> difficult for me to comment on, as I dont currently have access to an IIS
> 6.0 FTP server. If anyone knows of a public one that I can make use of
> somewhere, then I could try to reproduce your issue. 
> 
> Thanks
> Rory
> 
> 
> 
> "Jakarta Commons Users List" <commons-user@jakarta.apache.org> wrote:
> 
>> 
>> 
>> And yet another piece of the puzzle...  I also get the stacktrace [2]
>> below
>> when closing the application.  Is this the same thing that is fixed with
>> JIRA issue NET-3 [1]?  
>> 
>> Regards, 
>> 
>> Gert
>> 
>> [1] https://issues.apache.org/jira/browse/NET-3
>> [2] the stack trace
>> java.io.IOException: Fatal thread interruption during read.
>> 
>>         at
>> org.apache.commons.net.telnet.TelnetInputStream.read(TelnetInputStream.java:344)
>> 
>>         at
>> org.apache.commons.net.telnet.TelnetInputStream.read(TelnetInputStream.java:466)
>> 
>>         at
>> java.io.BufferedInputStream.read1(BufferedInputStream.java:254)
>> 
>>         at java.io.BufferedInputStream.read(BufferedInputStream.java:313)
>> 
>>         at
>> sun.nio.cs.StreamDecoder$CharsetSD.readBytes(StreamDecoder.java:411)
>> 
>>         at
>> sun.nio.cs.StreamDecoder$CharsetSD.implRead(StreamDecoder.java:453)
>> 
>>         at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:183)
>> 
>>         at java.io.InputStreamReader.read(InputStreamReader.java:167)
>> 
>>         at java.io.BufferedReader.fill(BufferedReader.java:136)
>> 
>>         at java.io.BufferedReader.readLine(BufferedReader.java:299)
>> 
>>         at java.io.BufferedReader.readLine(BufferedReader.java:362)
>> 
>>         at org.apache.commons.net.ftp.FTP.__getReply(FTP.java:264)
>> 
>>         at org.apache.commons.net.ftp.FTP.getReply(FTP.java:605)
>> 
>>         at
>> org.apache.commons.net.ftp.FTPClient.completePendingCommand(FTPClient.java:1253)
>> 
>>         at
>> org.apache.commons.net.ftp.FTPClient.initiateListParsing(FTPClient.java:2400)
>> 
>>         at
>> org.apache.commons.net.ftp.FTPClient.initiateListParsing(FTPClient.java:2364)
>> 
>>         at
>> org.apache.commons.net.ftp.FTPClient.listFiles(FTPClient.java:2141)
>> 
>>         at
>> org.apache.servicemix.ftp.FtpPollerEndpoint.pollFileOrDirectory(FtpPollerEndpoint.java:210)
>> 
>>         at
>> org.apache.servicemix.ftp.FtpPollerEndpoint.pollFileOrDirectory(FtpPollerEndpoint.java:202)
>> 
>>         at
>> org.apache.servicemix.ftp.FtpPollerEndpoint.poll(FtpPollerEndpoint.java:77)
>> 
>>         at
>> org.apache.servicemix.common.endpoints.PollingEndpoint$PollSchedulerTask$1.run(PollingEndpoint.java:155)
>> 
>>         at
>> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
>> 
>>         at
>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
>> 
>>         at java.lang.Thread.run(Thread.java:595)
>> 
>> 
>> Gert Vanthienen wrote:
>> > 
>> > L.S.,
>> > 
>> > I have changed the FTP poller's code, so the stream is always closed
>> and
>> > completePendingCommand is called, but that doesn't solve my problem. 
>> One
>> > additional observation though: the problem only occurs when the FTP
>> server
>> > is Microsoft's IIS...  Any thoughts?
>> > 
>> > Regards,
>> > 
>> > Gert
>> > 
>> > 
>> > Gert Vanthienen wrote:
>> >> 
>> >> L.S.,
>> >> 
>> >> Still trying to solve the FTP problem in ServiceMix, I'm a bit unsure
>> >> about the usage of completePendingCommand() in our code, which looks
>> >> about like this:
>> >> - calling retrieveInputStream() 
>> >> - reading from the the stream
>> >> - closing the stream 
>> >> - call the completePendingCommand() method
>> >> 
>> >> Under some conditions (Exceptions being thrown), the close() and
>> >> completePendingCommand() are never called.  Could the Exception below
>> be
>> >> caused by continuing to use the same FTPClient instance for other FTP
>> >> operations afterwards?
>> >> 
>> >> Regards,
>> >> 
>> >> Gert
>> >> 
>> >> 
>> >> Gert Vanthienen wrote:
>> >>> 
>> >>> Rory,
>> >>> 
>> >>> We are using commons-net-1.4.1.jar.
>> >>> 
>> >>> Gert
>> >>> 
>> >>> 
>> >>> 
>> >>> Rory Winston wrote:
>> >>>> 
>> >>>> Gert
>> >>>> 
>> >>>> What version of [net] are you using?
>> >>>> Rory
>> >>>> 
>> >>>> "Jakarta Commons Users List" <commons-user@jakarta.apache.org>
>> wrote:
>> >>>> 
>> >>>>> 
>> >>>>> 
>> >>>>> L.S.,
>> >>>>> 
>> >>>>> 
>> >>>>> I'm using Apache ServiceMix's FTP component, which uses commons
net
>> >>>>> FTPClient classes internally to poll for files on an FTP server.

>> >>>>> After a
>> >>>>> while, the polling threads lock up with the stacktrace mentioned
>> >>>>> below: I'm
>> >>>>> trying to solve this issue.  What can be the cause of this lockup
>> and
>> >>>>> how
>> >>>>> can I avoid this?  Is there a way to specify a time-out on this
>> >>>>> operation?
>> >>>>> 
>> >>>>> 
>> >>>>> Regards,
>> >>>>> 
>> >>>>> Gert Vanthienen
>> >>>>> 
>> >>>>> 
>> >>>>> 
>> >>>>> Stack trace:
>> >>>>>    java.net.PlainSocketImpl.socketAccept(Native Method)
>> >>>>>    java.net.PlainSocketImpl.accept(PlainSocketImpl.java:384)
>> >>>>>    java.net.ServerSocket.implAccept(ServerSocket.java:450)
>> >>>>>    java.net.ServerSocket.accept(ServerSocket.java:421)
>> >>>>>   
>> >>>>>
>> org.apache.commons.net.ftp.FTPClient._openDataConnection_(FTPClient.java:502)
>> >>>>>   
>> >>>>>
>> org.apache.commons.net.ftp.FTPClient.initiateListParsing(FTPClient.java:2390)
>> >>>>>   
>> >>>>>
>> org.apache.commons.net.ftp.FTPClient.initiateListParsing(FTPClient.java:2364)
>> >>>>>   
>> org.apache.commons.net.ftp.FTPClient.listFiles(FTPClient.java:2141)
>> >>>>>   
>> >>>>>
>> org.apache.servicemix.ftp.FtpPollerEndpoint.pollFileOrDirectory(FtpPollerEndpoint.java:211)
>> >>>>>   
>> >>>>>
>> org.apache.servicemix.ftp.FtpPollerEndpoint.pollFileOrDirectory(FtpPollerEndpoint.java:203)
>> >>>>>   
>> >>>>>
>> org.apache.servicemix.ftp.FtpPollerEndpoint.poll(FtpPollerEndpoint.java:78)
>> >>>>>    ...
>> >>>>> -- 
>> >>>>> View this message in context:
>> >>>>>
>> http://www.nabble.com/-net--FTPClient.listFiles-stalls...-tf3491086.html#a9749725
>> >>>>> Sent from the Commons - User mailing list archive at Nabble.com.
>> >>>>> 
>> >>>>> 
>> >>>>>
>> ---------------------------------------------------------------------
>> >>>>> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>> >>>>> For additional commands, e-mail:
>> commons-user-help@jakarta.apache.org
>> >>>>> 
>> >>>>> 
>> >>>> 
>> >>>> 
>> >>>> 
>> >>>> -----------------------------------------------------------------
>> >>>> Find the home of your dreams with eircom net property
>> >>>> Sign up for email alerts now http://www.eircom.net/propertyalerts
>> >>>> 
>> >>>> 
>> >>>> 
>> >>>>
>> ---------------------------------------------------------------------
>> >>>> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>> >>>> For additional commands, e-mail:
>> commons-user-help@jakarta.apache.org
>> >>>> 
>> >>>> 
>> >>>> 
>> >>> 
>> >>> 
>> >> 
>> >> 
>> > 
>> > 
>> 
>> -- 
>> View this message in context:
>> http://www.nabble.com/-net--FTPClient.listFiles-stalls...-tf3491086.html#a9831829
>> Sent from the Commons - User mailing list archive at Nabble.com.
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>> 
>> 
> 
> 
> 
> -----------------------------------------------------------------
> Find the home of your dreams with eircom net property
> Sign up for email alerts now http://www.eircom.net/propertyalerts
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/-net--FTPClient.listFiles-stalls...-tf3491086.html#a10000798
Sent from the Commons - User mailing list archive at Nabble.com.


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


Mime
View raw message