Changeset 7456

Show
Ignore:
Timestamp:
03/17/09 18:24:09 (17 months ago)
Author:
ronald
Message:

Display authors in search results in the order they appear in the article.

DublinCore?.creators is currently unordered; while it would be possible to
change it to be ordered, that would not come for free in terms of query
performance. Using the already ordered author list from the citation is a
bit slower, but not hugely so: it slows down retrieval of the article
info for a search hit by 10% (i.e. a page full of results now takes 10s
instead of 9s).

This closes #1124.

Location:
head/ambra/webapp/src/main/java/org/topazproject/ambra/search/service
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • head/ambra/webapp/src/main/java/org/topazproject/ambra/search/service/Results.java

    r7454 r7456  
    175175      return new SearchHit(hit.getHitScore(), hit.getUri(), article.getDublinCore().getTitle(), 
    176176                           createHighlight("body", findTextRepresentation(article).getBodyAsText()), 
    177                            article.getDublinCore().getCreators(), 
     177                           article.getDublinCore().getBibliographicCitation().getAuthorsRealNames(), 
    178178                           article.getDublinCore().getDate()); 
    179179    } catch (IOException ioe) { 
  • head/ambra/webapp/src/main/java/org/topazproject/ambra/search/service/SearchHit.java

    r7197 r7456  
    1919package org.topazproject.ambra.search.service; 
    2020 
     21import java.util.Collection; 
    2122import java.util.Date; 
    22 import java.util.Set; 
    2323 
    2424import org.apache.commons.lang.StringUtils; 
     
    4242   */ 
    4343  public SearchHit(double hitScore, String uri, String title, String highlight, 
    44                    Set<String> creators, Date date) { 
     44                   Collection<String> creators, Date date) { 
    4545    this.hitScore  = hitScore; 
    4646    this.uri       = uri;