Differences between revisions 3 and 4
Revision 3 as of 2007-07-05 10:29:34
Size: 1910
Editor: 213
Comment:
Revision 4 as of 2007-07-05 10:31:35
Size: 1926
Editor: 213
Comment:
Deletions are marked like this. Additions are marked like this.
Line 9: Line 9:
Edit JBoss's "server/default/deploy/jbossweb-tomcat55.sar/server.xml" and add the following attribute to the correct Connector element: URIEncoding="UTF-8". Edit JBoss's ''server/default/deploy/jbossweb-tomcat55.sar/server.xml'' and add the following attribute to the correct Connector element: URIEncoding="UTF-8".
Line 23: Line 23:
You can configure the Solr home directory globally via "-Dsolr.solr.home" in the file "bin/run.bat". But that is often not desired because you potentially want more than one Solr installation deployed. You can configure the Solr home directory globally via ''-Dsolr.solr.home'' in the file ''bin/run.bat''. But that is often not desired because you potentially want more than one Solr installation deployed.
Line 26: Line 26:
You can configure the Solr home directory to use per webapp in the "web.xml" file. Add following snippet to the web.xml: You can configure the Solr home directory to use per webapp in Solr's ''web.xml'' file. Add following snippet to the web.xml:
Line 36: Line 36:
If you encounter the error "statements are only available if source level is 5.0" then you have to edit the file "server/default/deploy/jbossweb-tomcat55.sar/conf/web.xml". Comment in the block If you encounter the error "statements are only available if source level is 5.0" then you have to edit the file ''server/default/deploy/jbossweb-tomcat55.sar/conf/web.xml''.

Comment in the block

Solr with JBoss

  • Solr runs fine with [http://www.jboss.org/ JBoss], see the instructions in the generic [wiki:SolrInstall Solr installation] page

  • The latest version of JBoss is recommended

Optional Configuration

URI Charset Config

If you are going to query Solr using international characters (>127) using HTTP-GET, you must configure JBoss to conform to the URI standard by accepting percent-encoded UTF-8.

Edit JBoss's server/default/deploy/jbossweb-tomcat55.sar/server.xml and add the following attribute to the correct Connector element: URIEncoding="UTF-8".

<Server ...>
 <Service ...>
   <Connector ... URIEncoding="UTF-8"/>
     ...
   </Connector>
 </Service>
</Server>

This is only an issue when sending non-ascii characters in a query request... no configuration is needed for Solr/Tomcat to return non-ascii chars in a response, or accept non-ascii chars in an HTTP-POST body.

Configuring Solr Home

You can configure the Solr home directory globally via -Dsolr.solr.home in the file bin/run.bat. But that is often not desired because you potentially want more than one Solr installation deployed.

Solr Home via web.xml

You can configure the Solr home directory to use per webapp in Solr's web.xml file. Add following snippet to the web.xml:

  <env-entry>
    <env-entry-name>solr/home</env-entry-name>
    <env-entry-value>C:\Projects\solr-trunk\example\solr</env-entry-value>
    <env-entry-type>java.lang.String</env-entry-type>
  </env-entry>

Troubleshooting

If you encounter the error "statements are only available if source level is 5.0" then you have to edit the file server/default/deploy/jbossweb-tomcat55.sar/conf/web.xml.

Comment in the block

<init-param>
   <param-name>compilerSourceVM</param-name>
   <param-value>1.5</param-value>
</init-param

SolrJBoss (last edited 2013-01-06 15:52:56 by UweSchindler)