git-svn-id: https://svn.apache.org/repos/asf/maven/repository-manager/trunk@425307 13f79535-47bb-0310-9956-ffa450edef68tags/archiva-0.9-alpha-1
@@ -15,7 +15,7 @@ | |||
--> | |||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | |||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | |||
<parent> | |||
<groupId>org.apache.maven.repository</groupId> | |||
<artifactId>maven-repository-manager</artifactId> | |||
@@ -37,6 +37,7 @@ | |||
<groupId>org.apache.maven</groupId> | |||
<artifactId>maven-model</artifactId> | |||
</dependency> | |||
<!-- TODO! upgrade to lucene 2.0.0 --> | |||
<dependency> | |||
<groupId>lucene</groupId> | |||
<artifactId>lucene</artifactId> |
@@ -63,6 +63,8 @@ public class DefaultRepositoryIndexSearchLayer | |||
for ( int i = 0; i < RepositoryIndex.FIELDS.length; i++ ) | |||
{ | |||
// TODO! does simply iterating the fields and searching each perform well enough and yield correct rankings? | |||
// look into: http://wiki.apache.org/jakarta-lucene/LuceneFAQ#head-300f0756fdaa71f522c96a868351f716573f2d77 | |||
// ie: http://lucene.apache.org/java/docs/api/org/apache/lucene/queryParser/MultiFieldQueryParser.html | |||
QueryTerm term = new QueryTerm( RepositoryIndex.FIELDS[i], keyword ); | |||
List results = searchAdvanced( new SingleTermQuery( term ), index ); | |||
for ( Iterator iter = results.iterator(); iter.hasNext(); ) |