views:

239

answers:

1
  1. Any example of scenarios other than doing search for which I could use "compass"? Lets say we have a page that list top 10 most view article. How to use compass to show this kind of results. Any demo/sample project on this to refer to? definitely Jira would be a good example but its source code is not available. I want to know how to maximize the benefits of using compass-lucene in an application.

  2. May i know where can i download spring-compass jpa @annotated example? The nightly built i downloaded is xml-based.

+1  A: 

Any example of scenarios other than doing search for which I could use "compass"?

Well, AFAIK, this is what is has been designed for.

Lets say we have a page that list top 10 most view article. How to use compass to show this kind of results.

I'm not sure this is a good use-case, Compass is in my opinion useful when you want to search results across the whole application business domain model i.e. not only lets say articles (in that case, you can just query the database).

Now, let's imagine that your domains objects are searchable classes and have a searchable property numberOfViews, I guess it would be possible to search on this property (refer to the whole Searching section).

Any demo/sample project on this to refer to?

The compass distribution includes samples: a Library basic example that highlights the main features of Compass::Core and a Petclinic sample that shows how to add compass to an existing application (the Spring petclinic sample).

I want to know how to maximize the benefits of using compass-lucene in an application.

Read the author's blog, Compass wiki and the reference documentation :)

May i know where I can download spring-compass jpa @annotated example?

As mentioned, the spring-compass sample included in compass distribution is based on Spring's petclinic which doesn't use annotations (see SPR-2960). Just in case, petclinic annotated entities are attached to SPR-2960 so feel free to use them.

Pascal Thivent