commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebb (JIRA)" <>
Subject [jira] Commented: (NET-331) AS400 file timestamp format is wrong
Date Sat, 19 Mar 2011 12:58:29 GMT


Sebb commented on NET-331:

Should have realised earlier that the FTPClientConfig.setDefaultDateFormatStr(format) method
can be used to override the default format provided by the parser. So for example:

FTPClient f=FTPClient();
FTPClientConfig conf = new FTPClientConfig(FTPClientConfig.SYST_UNIX);
conf.setDefaultDateFormat("MM/dd/yy HH:mm:ss");

Or the parser could override the preParse() method to scan the raw results and decide which
format to use when the main parse is called.

> AS400 file timestamp format is wrong
> ------------------------------------
>                 Key: NET-331
>                 URL:
>             Project: Commons Net
>          Issue Type: Bug
>          Components: FTP
>    Affects Versions: 2.0
>         Environment: AS400
>            Reporter: Jim Urban
>   Original Estimate: 0h
>  Remaining Estimate: 0h
> There is a bug in  The variable
"private static final String DEFAULT_DATE_FORMAT" needs to be changed from "yy/MM/dd HH:mm:ss";
//01/11/09 12:30:24 to "MM/dd/yy HH:mm:ss"; //01/15/08 14:21:38 to work correctly.  I have
tested this on our companies AS400 and it solved the problem we were having.

This message is automatically generated by JIRA.
For more information on JIRA, see:

View raw message