Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@www.apache.org Received: (qmail 31282 invoked from network); 16 Apr 2005 11:46:36 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 16 Apr 2005 11:46:36 -0000 Received: (qmail 38196 invoked by uid 500); 16 Apr 2005 11:46:17 -0000 Delivered-To: apmail-jakarta-commons-dev-archive@jakarta.apache.org Received: (qmail 38127 invoked by uid 500); 16 Apr 2005 11:46:17 -0000 Mailing-List: contact commons-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Jakarta Commons Developers List" Reply-To: "Jakarta Commons Developers List" Delivered-To: mailing list commons-dev@jakarta.apache.org Received: (qmail 38113 invoked by uid 99); 16 Apr 2005 11:46:17 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (hermes.apache.org: local policy) Received: from smtpout03-04.mesa1.secureserver.net (HELO smtpout03-04.mesa1.secureserver.net) (64.202.165.74) by apache.org (qpsmtpd/0.28) with SMTP; Sat, 16 Apr 2005 04:46:15 -0700 Received: (qmail 29360 invoked from network); 16 Apr 2005 11:46:12 -0000 Received: from unknown (24.13.84.182) by smtpout03-04.mesa1.secureserver.net (64.202.165.74) with ESMTP; 16 Apr 2005 11:46:12 -0000 Message-ID: <4260FB04.2060204@javactivity.org> Date: Sat, 16 Apr 2005 06:46:12 -0500 From: Steve Cohen User-Agent: Mozilla Thunderbird 1.0 (X11/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Jakarta Commons Developers List Subject: Re: [net] FTP client date parsing: new format References: <42607710.1030309@javactivity.org> <4260EAF9.3010706@apache.org> In-Reply-To: <4260EAF9.3010706@apache.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N I'm sorry, you're right again. IWhen you first wrote me about the numeric date I assumed that the new system just happened to handle it, without bothering to look at the regex that decided what the date parser must parse. Then when I hadn't heard from you for awhile, I thought we were over this hump. But yes, this is a problem, and it looks as if Rory's fix is a good one. I will add some junit test cases to verify this. Neeme Praks wrote: > > AFAIK, the new system uses both: regexp for extracting the timestamp > from the entry line and then using DateFormat to parse that. > Example: > -rw-r--r-- 1 1000 1000 27 Jan 24 11:31 messages.vsp > from this line the regexp extracts the timestamp part ("Jan 24 11:31") > and then DateFormat is used to parse this to a valid Date object. > The issue here is that the failure is already at regexp matching, and > the code never reaches the DateFormat parsing part. > > I'll try to check out Rory's changes during the weekend. > > Rgds, > Neeme > > Steve Cohen wrote: > >> No, that's not it at all. Remember that the new system does not use >> Regexes for date parsing, it uses SimpleDateFormats. From Mr. Praks' >> descriptions, I am assuming he's now running the 1.3 or earlier >> versions, which do use regexes. >> >> This surprises me because I've had several conversations with him over >> the past month in which the new system was discussed. Perhaps he >> forgot to specify the date format as "yyyy/MM/dd" in his >> FTPClientConfig this time? Or perhaps his code is finding an older >> commons-net.jar than he was expecting? >> >> Steve Cohen >> >> Rory Winston wrote: >> >>> Right, the problem with this format is that the date is not composed >>> of three discrete components (from a regex POV), but two. Basically >>> what we will need to do is expand the regex to handle thuis - can you >>> give me details of the FTP server operating system and FTP server >>> software version if you have it please. >>> >>> Cheers >>> Rory >> >> --------------------------------------------------------------------- To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-dev-help@jakarta.apache.org