Configure free-text search for JBoss
Before you begin
Procedure
-
Add a JBoss deployment descriptor file to the
pc-gwsolr.warfile.- In the Studio Project window, expand .
-
Create a file named jboss-deployment-structure.xml, with the following content.
<?xml version='1.0' encoding='UTF-8'?> <jboss-deployment-structure xmlns="urn:jboss:deployment-structure:1.1"> <deployment> <dependencies> <module name="org.slf4j"/> <module name="org.slf4j.ext"/> <module name="org.slf4j.slf4j-jdk14"/> <module name="org.slf4j.jcl-over-slf4j"/> <module name="org.slf4j.log4j-over-slf4j"/> </dependencies> </deployment> </jboss-deployment-structure>You safely can ignore the warning in the Studio XML editor that the value for the
xmlnsattribute is not a URI registered with Studio.
-
Repackage the Guidewire Solr Extension by running the following command from the PolicyCenter
installation directory:
- gwb packageSolr
-
On the host on which the JBoss instance for free-text search resides, create an installation directory for the
Guidewire Solr Extension.
For example:Unix – /opt/gwsolr/pcWindows – C:\opt\gwsolr\pc
This topic uses /opt/gwsolr/pc as the directory name.
- Extract the file PolicyCenter/solr/pc-gwsolr.zip from the host on which your PolicyCenter application resides to the folder you created on the host on which JBoss resides.
-
Perform the steps in procedure Update the Guidewire Solr extension installation directory on JBoss if either the following are true:
- You extracted
pc-gwsolr.zip to a directory other than /opt/gwsolr/pc in step 3 of this procedure. - You are using the Microsoft Windows operating system.
- You extracted
- (Optional) Perform the steps in procedure Change the default Solr port number on JBoss.
-
Start JBoss by running the following command from the
JBOSS_HOME/bin/ directory:
- standalone
-
Open a separate command window in the JBOSS_HOME/bin directory and do the following:
-
Start the JBoss command line interface by running the following command:
- jboss-cli -c
-
Add logging modules to JBoss:
Unix
module add --name=org.slf4j.slf4j-jdk14 --resources=/opt/gwsolr/pc/logging_jars/slf4j-jdk14-1.7.12.jar --dependencies=org.slf4j module add --name=org.slf4j.log4j-over-slf4j --resources=/opt/gwsolr/pc/logging_jars/log4j-over-slf4j-1.7.12.jar --dependencies=org.slf4j,org.slf4j.slf4j-jdk14Windows
module add --name=org.slf4j.slf4j-jdk14 --resources=C:\opt\gwsolr\pc\logging_jars\slf4j-jdk14-1.7.12.jar --dependencies=org.slf4j module add --name=org.slf4j.log4j-over-slf4j --resources=C:\opt\gwsolr\pc\logging_jars\log4j-over-slf4j-1.7.12.jar --dependencies=org.slf4j,org.slf4j.slf4j-jdk14 -
Execute one of the following commands to deploy the Guidewire Solr Extension:
- Unix – Deploy /opt/gwsolr/pc/pc-gwsolr.war
- Windows – Deploy c:\opt\gwsolr\pc\pc-gwsolr.war
- Exit the command prompt by typing q.
-
Start the JBoss command line interface by running the following command:
-
Examine the log file JBOSS_HOME
/standalone/log/server.logto verify that the Guidewire Solr Extension started successfully.The application started successfully if you see a number of log entries related to the directory on which you installed the Guidewire Solr Extension in step 3. -
In a browser, open the administrative user interface for the Guidewire Solr Extension by entering the
following URL:
http://hostName:8983/pc-gwsolr -
Verify that you see links to administrative pages for each entity type that is searchable in PolicyCenter with
free-text search.
For example, click Core Admin to see information for the pc_policy_active core.
What to do next
After completing this procedure, proceed to About the free-text batch load command.
