[ http://issues.apache.org/jira/browse/AVALON-7?page=all ]
     
Shash Chatterjee resolved AVALON-7:
-----------------------------------

    Resolution: Fixed

Fixed:

Author: shash
Date: Sat Jul 23 06:23:24 2005
New Revision: 224462

URL: http://svn.apache.org/viewcvs?rev=224462&view=rev
Log:
Fix for AVALON-7
Calculate where the oldest file is in the array of files, don';t assume it is 
always at index 0

Modified:
    
excalibur/trunk/containerkit/logkit/src/java/org/apache/log/output/io/rotate/RevolvingFileStrategy.java

> Logkit/ResolvingFileStrategy assumes FIle.listFiles() returns in 
> oldest-to-newest order
> ---------------------------------------------------------------------------------------
>
>          Key: AVALON-7
>          URL: http://issues.apache.org/jira/browse/AVALON-7
>      Project: Avalon
>         Type: Bug
>  Environment: OS: Fedora Core 4, i686, kernel 2.6.12
> JDK: Sun JDK-1.4.2_08
>     Reporter: Shash Chatterjee
>     Assignee: Shash Chatterjee

>
> On specified environment, RevolvingFileStrategtTestCase.testFullRotation() 
> fails.
> The cause is that ResolvingFileStrategy.calculateInitialRotation() assumes 
> that the oldest file will be returned at index 0.  At least on this platform, 
> the files matching the given pattern seem to be returned in random order.
> Fix is to actually find the minimum rotation, mark it's index in the returned 
> array, then use the index when calculating time for the oldest file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to