[opencms-dev] Problem with Solr

Petronio Emilia emilia.petronio at sed.ethz.ch
Mon Feb 24 17:33:44 CET 2014


Hi,

I have iOpenCms Version 9.0 and I want to search for text  that I have created either in a page  of the "demo" sub-site (for instance a text within a bootstrap textblock at http://localhost/opencms/opencms/demo/text-block/index.html)   or on a textblock in a containerpage of a sub-site created by me but I get no result.

Example of what I did:

- I inserted a textblock (tb_000013.xml, type: bs-textblock) into localhost/opencms/opencms/demo/text-block/index.html; I wrote  some words, i.e. "geoenergy"
- I rebuilt the Solr offline index;  I got the following msg: "indexing localhost/opencms/opencms/demo/text-block/index.html ..is ok; indexing tb_000013.xml is skipped"
- I clicked on the search magnifier located on the demo menu and searched for "geoenergy" : no result
- I clicked on the "search" item in the top-right menu and searched for "geonergy" : no result
- I made following Solr request to search for content type bs-textblock:
http://sccer-soe.ethz.ch:8080/opencms/opencms/handleSolrSelect?&core=Solr%20Offline&fq=bs-textblock  -> no result
- I made the following request to search for the containerpage with geonergy
http://sccer-soe.ethz.ch:8080/opencms/opencms/handleSolrSelect?&core=Solr%20Offline&fq=type:containerpage&fq=content:geoenergy-> I get a result with my containerpage


Questions:
1) Which Solr query is carried out when I type a word into the searchWidgetAutoComplete of the search form which available in the demo ?  I have seen from the jsp of the search detail page (http://localhost/opencms/opencms/system/modules/ch.ethz.sccer.bootstrap.formatters/search/search.jsp) that the jsp context.jsp is included but it is not clear to me if I have to make any change there.

2) I don't understand why the resource type bs-textblock is not found: the standard solr offline index accepts the document type "xmlpage". Isn't the type bs-textblock an xmldocument, like ddarticle (which is found)? What should I do to find this resource type?

3) Why the content in my containerpage is not found by the search in the standard menus (magnifier   or menu item)?

4) Why is it found if I request
http://sccer-soe.ethz.ch:8080/opencms/opencms/handleSolrSelect?&core=Solr%20Offline&fq=type:containerpage&fq=content:geoenergy?

The search doesn't work even if I publish the resources and rebuild the index solr online. The resource property "search.exclude " of the containerpage and of the textblock is not set to "solr".

Thank you very much in advance for your answer.

E.Petronio



More information about the opencms-dev mailing list