Update configuration to use custom update processor chain instead of copyField to...
[lui-solr.git] / conf / solrconfig-master.xml
index ccde565..86e9e9e 100644 (file)
@@ -35,7 +35,7 @@
        that you fully re-index after changing this setting as it can
        affect both how text is indexed and queried.
   -->
-  <luceneMatchVersion>4.4</luceneMatchVersion>
+  <luceneMatchVersion>5.5</luceneMatchVersion>
 
   <!-- <lib/> directives can be used to instruct Solr to load an Jars
        identified and use them to resolve any "plugins" specified in
        replication is in use, this should match the replication
        configuration.
     -->
-  <dataDir>${solr.data.dir:/var/lib/masterkey/lui/solr4/master}</dataDir>
+  <dataDir>${solr.data.dir:/var/lib/masterkey/lui/solr5/master}</dataDir>
 
 
   <!-- The DirectoryFactory to use for indexes.
        <lst name="defaults">
          <str name="update.chain">dedupe</str>
        </lst>
-       -->
+    -->
+    <lst name="defaults">
+      <str name="update.chain">cloneFields</str>
+    </lst>
   </requestHandler>
 
-  <!-- for back compat with clients using /update/json and /update/csv -->  
+  <!-- for back compat with clients using /update/json and /update/csv -->
+  <!-- no longer works in 5.5
   <requestHandler name="/update/json" class="solr.JsonUpdateRequestHandler">
         <lst name="defaults">
          <str name="stream.contentType">application/json</str>
         <lst name="defaults">
          <str name="stream.contentType">application/csv</str>
        </lst>
-  </requestHandler>
+       </requestHandler>
+  -->
 
   <!-- Solr Cell Update Request Handler
 
       <str name="captureAttr">true</str>
       <str name="fmap.a">links</str>
       <str name="fmap.div">ignored_</str>
+      <str name="update.chain">cloneFields</str>
     </lst>
   </requestHandler>
 
       <processor class="solr.RunUpdateProcessorFactory" />
     </updateRequestProcessorChain>
   -->
+  <!-- Clone fields processor
+       Hooks in a CloneFieldUpdateProcessor to copy all fields
+       except for binaries to the "text" (default search) field
+  -->
+  <updateRequestProcessorChain name="cloneFields">
+     <processor class="solr.CloneFieldUpdateProcessorFactory">
+       <lst name="source">
+         <str name="fieldRegex">.*</str>
+         <lst name="exclude">
+           <str name="fieldRegex">.*_binary$</str>
+         </lst>
+       </lst>
+       <str name="dest">text</str>
+     </processor>
+     <processor class="solr.LogUpdateProcessorFactory" />
+     <processor class="solr.RunUpdateProcessorFactory" />
+  </updateRequestProcessorChain>    
  
   <!-- Response Writers