[Building Sakai] Sakai Search Tool 2.6

Zhen Qian zqian at umich.edu
Thu Jun 30 11:53:09 PDT 2011


Hi, Amy:

Collecting all search result and sort then outside search engine is one way to accomplish the task. However, doing so might introduce performance problem if the returning result is of big list.

Before Lucene 1.4, search results were only returned in descending relevance score  order. Sakai search tool is based on Lucence 2.9 (as of Sakai 2.7), so we are likely to leverage Lucene's inner sorting capabilities by doing the following steps:

1. Note that currently Sakai entities are indexed with the following fields populated: "siteid", "url", "tool", "title", "contents", "context", "subtype", "type", "id", "container", "reference", "digestCount". The field definition is inside SearchService.java. You can select subset of the list as search sort choices in Search tool, add the sort filter to search interface, I think it is the index.vm file, so that user can select the sort criteria. 

2. Modify search() inside SearchBeanImpl.java, so that you can set the sortName attribute to based user's selection of sort criteria;

3. Check search() inside BaseSearchServiceImpl.java, make sure the indexSorter field is setup correctly for sort. So if you are sorting based on title, the indexSorter should be constructed as new Sort("title").

And now you can search and sort!

HTH,

- Zhen

On Jun 30, 2011, at 5:18 AM, Amy wrote:

> Hi David,
>  
> Any idea maybe on how to make the view?
>  
> Thanks!
>  
> Best regards,
> Amy
>  
> From: sakai-dev-bounces at collab.sakaiproject.org [mailto:sakai-dev-bounces at collab.sakaiproject.org] On Behalf Of David Horwitz
> Sent: Thursday, 30 June, 2011 4:36 PM
> To: sakai-dev at collab.sakaiproject.org
> Subject: Re: [Building Sakai] Sakai Search Tool 2.6
>  
> Hi Amy,
> 
> The short answer is as the tool is, is no. The results are presented sorted by relevance to the search. It should be possible to make a view that is a sortable table (though the paging will probably make this non trivial) I doubt though that the search tool actually knows enough about the returned results to make this feature really useful.
> 
> regards
> 
> David
> 
> On 06/30/2011 10:31 AM, Amy wrote:
> Hi All,
>  
> Good day!
>  
> I have a question regarding the Sakai version 2.6 Search Tool.
>  
> Is it possible to have results from Search be sort-able and placed in tables?
>  
> This is a request from my client and really need help on this fast.
>  
> Thanks!
> 
> Best regards,
> Amy Leyson
> Instructional Design Consultant
> Jupiter Innovations Pte Ltd
> No. 10, Toh Guan Road
> #02-01, TT International Trade Park
> Singapore 608838
> Tel:  +65-65874666 ext. 1023
> Fax: +65-68610448
> Mobile: +65 82899667
> Email: amy at jupinno.com
> www.jupinno.com
>  
>  
>  
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>  
> TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of "unsubscribe"
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
> 
> TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of "unsubscribe"

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20110630/2c3d9fc7/attachment.html 


More information about the sakai-dev mailing list