<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
{mso-style-priority:99;
mso-style-link:"Balloon Text Char";
margin:0cm;
margin-bottom:.0001pt;
font-size:8.0pt;
font-family:"Tahoma","sans-serif";}
span.BalloonTextChar
{mso-style-name:"Balloon Text Char";
mso-style-priority:99;
mso-style-link:"Balloon Text";
font-family:"Tahoma","sans-serif";}
span.EmailStyle19
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:windowtext;}
span.EmailStyle20
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:#1F497D;}
span.EmailStyle21
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:#1F497D;}
p.Sprechblasentext, li.Sprechblasentext, div.Sprechblasentext
{mso-style-name:Sprechblasentext;
mso-style-link:"Sprechblasentext Zchn";
margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
span.SprechblasentextZchn
{mso-style-name:"Sprechblasentext Zchn";
mso-style-priority:99;
mso-style-link:Sprechblasentext;
font-family:"Tahoma","sans-serif";}
span.EmailStyle24
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=NO-BOK link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Hi Kai,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>I was able to confirm that xmlcontent doesn’t get indexed, but thanks anyway. :)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Cheers,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Paul<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> opencms-dev-bounces@opencms.org [mailto:opencms-dev-bounces@opencms.org] <b>On Behalf Of </b>Schliemann, Kai<br><b>Sent:</b> 14. september 2015 16:34<br><b>To:</b> The OpenCms mailing list<br><b>Subject:</b> Re: [opencms-dev] Solr query specific index<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Hi Paul,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>I don’t have an answer for your question, but maybe this hint helps you?<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Did you check your solr cores with LUKE - <a href="https://code.google.com/p/luke/">https://code.google.com/p/luke/</a></span><span lang=EN-US style='color:black'>?</span><span lang=EN-US style='color:#1F497D'> <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>With Luke you can check if and what information are in your index.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>HTH<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Best regards<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Kai<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span lang=DE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>Von:</span></b><span lang=DE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> <a href="mailto:opencms-dev-bounces@opencms.org">opencms-dev-bounces@opencms.org</a> [<a href="mailto:opencms-dev-bounces@opencms.org">mailto:opencms-dev-bounces@opencms.org</a>] <b>Im Auftrag von </b>Paul-Inge Flakstad<br><b>Gesendet:</b> Montag, 14. September 2015 15:51<br><b>An:</b> The OpenCms mailing list<br><b>Betreff:</b> Re: [opencms-dev] Solr query specific index<o:p></o:p></span></p></div></div><p class=MsoNormal><span lang=DE><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>OK, so after some more careful reading, I understand that need to define</span><span lang=EN-US> <span style='color:#1F497D'>a class on the <index> node.<o:p></o:p></span></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>I tried using the class used by the default index:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <index class=”org.opencms.search.solr.CmsSolrIndex”> <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>This made the NPE go away, but I got zero results no matter what I do – even if I query for everything. It’s like nothing’s indexed. Re-building made no difference. On a side note: When I tested applying this class on the index that’s used in the “regular” site search – the index I’m actually trying to work with here – it broke. (Front-end searching just resulted in “Server error unknown”.)<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>I have no idea what I’m doing wrong here. :/ Do I have to write a custom class? Define the index/source differently?<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>My source consists of (mostly) xmlcontent. Here is what I tried so far (did not work):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><index class=”org.opencms.search.solr.CmsSolrIndex”><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <name>my_index</name><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <rebuild>auto</rebuild><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <project>Online</project><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <locale>en</locale><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <configuration>standard</configuration><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <sources><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <source>my_source </source><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> </sources><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <param name="org.opencms.search.CmsSearchIndex.checkTimeRange">false</param><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <param name="search.solr.postProcessor">org.opencms.search.solr.CmsSolrLinkProcessor</param><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'></index><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>...<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><indexsource><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <name>my_source</name><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <indexer class="org.opencms.search.CmsVfsIndexer"/><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <resources><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <resource>/sites/default/</resource><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> </resources><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <documenttypes-indexed><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <name>html</name><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <name>text</name><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <name>xmlcontent</name><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <name>xmlcontent-solr</name><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> <name>xmlpage</name><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'> </documenttypes-indexed><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'></indexsource><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Cheers,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'>Paul<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> <a href="mailto:opencms-dev-bounces@opencms.org">opencms-dev-bounces@opencms.org</a> [<a href="mailto:opencms-dev-bounces@opencms.org">mailto:opencms-dev-bounces@opencms.org</a>] <b>On Behalf Of </b>Paul-Inge Flakstad<br><b>Sent:</b> 14. september 2015 13:22<br><b>To:</b> The OpenCms mailing list<br><b>Subject:</b> [opencms-dev] Solr query specific index<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><span lang=EN-US>Hi,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>I’d like to query a couple of OpenCms search indices (on an 8.5.2 instance) “directly” via the handleSolrSelect URI (or equivalent).<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>But: How do I “select” a specific index?<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>I have read the doc and tried the “core” parameter, like this:<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><a href="http://myhost.com:8080/myopencms/opencms/handleSolrSelect?q=something&core=my_index">http://myhost.com:8080/myopencms/opencms/handleSolrSelect?q=something&core=my_index</a><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>But that just results in a NPE: “No Solr index named: my_index configured.” <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US>PS: The handleSolrSelect URI works, but so far I can’t use it to query anything but the default index.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p> </o:p></span></p><div><p class=MsoNormal><span style='font-size:10.0pt;color:#365F91'>Med vennlig hilsen,<o:p></o:p></span></p><p class=MsoNormal><b><span style='font-size:10.0pt;color:#365F91'>Paul-Inge Flakstad<o:p></o:p></span></b></p><p class=MsoNormal><i><span style='font-size:8.0pt;color:#365F91'>Webutvikler, Norsk Polarinstitutt<o:p></o:p></span></i></p><p class=MsoNormal><span style='font-size:8.0pt;color:#365F91'><a href="mailto:flakstad@npolar.no"><span style='color:#365F91'>flakstad@npolar.no</span></a> | 777 50 639<o:p></o:p></span></p></div><p class=MsoNormal><o:p> </o:p></p></div></body></html>