[hibernate-issues] [Hibernate-JIRA] Created: (HSEARCH-623) Support for faceting search results
G Fernandes (JIRA)
noreply at atlassian.com
Tue Nov 2 07:22:47 EDT 2010
Support for faceting search results
-----------------------------------
Key: HSEARCH-623
URL: http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-623
Project: Hibernate Search
Issue Type: New Feature
Components: engine
Reporter: G Fernandes
I've been asked more than once about the possibility to support facet retrieval from the search results. The idea is to categorize the results of a query into buckets containing a label plus a number of occurrences. Consider an example: I have a Book entity containing a language field. When I search for Books, I'd like to obtain not only a List<Book>, but also a list of languages and how many books from the search results fit into each of these languages, so that I can render the results as:
Found 17 Books:
English (10)
Italian (5)
Spanish (2)
It'd be also possible to facet on more than a field at the same time, similar to what's being done with projections.
Facet calculation would be done at query time reading directly from the index, probably by using a plugable strategy, examples would be LuceneFieldCacheStrategy and TermEnumStrategy.
Asking for facets would be done at API level, probably with a decorator on top of QueryBuilder something like
facetQueryBuilder.facetOn("field1").facetOn("field2").results().facets();
WDYT?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list