Re: svn commit: r824220 - in /archiva/trunk/archiva-modules/archiva-base/archiva-repository-layer/src: main/java/org/apache/maven/archiva/repository/scanner/functors/ test/java/org/apache/maven/archiva/repository/metadata/ test/java/org/apache/maven/archiv...

View: New views
1 Messages — Rating Filter:   Alert me  

Parent Message unknown Re: svn commit: r824220 - in /archiva/trunk/archiva-modules/archiva-base/archiva-repository-layer/src: main/java/org/apache/maven/archiva/repository/scanner/functors/ test/java/org/apache/maven/archiva/repository/metadata/ test/java/org/apache/maven/archiv...

by brettporter :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


On 12/10/2009, at 3:29 PM, jzurbano@... wrote:

> -
> /**
>  * ConsumerWantsFilePredicate
>  *
> @@ -62,8 +63,19 @@
>                     // Timestamp finished points to the last  
> successful scan, not this current one.
>                     if ( basefile.lastModified() < changesSince )
>                     {
> -                        // Skip file as no change has occured.
> -                        satisfies = false;
> +                        // MRM-1246
> +                        // compares the lastModified of the version-
> level (basefile) and the project-level (parent) metadata
> +                        File parent = basefile.getParentFile
> ().getParentFile();
> +
> +                        if ( parent.lastModified() >  
> basefile.lastModified() )
> +                        {
> +                            satisfies = true;
> +                        }
> +                        else
> +                        {
> +                            // Skip file as no change has occurred.
> +                            satisfies = false;
> +                        }
>                     }

is this doing what it intends? It seems to be comparing the timestamp  
of the parent directory, not the parent metadata file, and not all  
files passing through the predicate are metadata files.

Does disabling this change cause the tests to fail to verify they are  
working?

- Brett