DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=37897>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ· INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=37897 ------- Additional Comments From [EMAIL PROTECTED] 2006-01-07 02:37 ------- I checked out the commons net javadoc http://jakarta.apache.org/commons/net/apidocs/org/apache/commons/net/ftp/FTPClient.html It says you can get a list of files (w/ timestamps) for a whole directory: FTPFile[] files = listFiles(directory); It recommends against putting wildcards in the directory name; It says the server may or may not support it. Any ftp server I have used in recent memory suports basic file globbing, so I'm not sure if this is a real problem or not. Ideally you would want to do FTPFile[] files = ftp.listFiles("/usr/pronto/web/html/jsp/*.jsp"); rather than listing all the files in the directory with FTPFile[] files = ftp.listFiles("/usr/pronto/web/html/jsp"); because the latter would make the ftp task slower in the case were there is only a few files which match in a directory which has lots of files. In my case, I have 224 JSP files in /usr/pronto/web/html/jsp, and no other files. The main complication is that Ant's path selectors are so powerful, it would be hard to handle all the cases. One thought I had was to go ahead and let the current code create the list of files to be transfered from the path selectors. Then, examine all the files and find all the unique directory names. Then, if "depends=yes" has been set, we could go ahead and do a ftp.listFiles() on each of the directories, and manually throw away and FTPFiles which don't match one of the files to be transferred; the FTPFIles which match our list of files are kept around in a hash table map. Then when sendFile() calls isItUpToDate(), we can refer to the FTPFiles lookup table. In some situations, this might be slower, but I think it many of the use cases, this will speed things up dramatically. In my case, the ftp task will probably take 1 or 2 seconds whereas it is taking 50 seconds right now. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
