Skip to content

Commit

Permalink
Implemented #159: Upgrade Solr from 9.6.1 to 9.7.0
Browse files Browse the repository at this point in the history
  • Loading branch information
m-i-l committed Nov 3, 2024
1 parent 9a6e707 commit 82452bb
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/search/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM solr:9.6.1
FROM solr:9.7.0

# Copy the custom config files in. Note that in order to create the collection with this config,
# we need to do a docker run with "solr-precreate content /opt/solr/server/solr/configsets/content"
Expand Down
30 changes: 24 additions & 6 deletions src/search/content/conf/solrconfig.xml
Original file line number Diff line number Diff line change
Expand Up @@ -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>9.10</luceneMatchVersion>
<luceneMatchVersion>9.11</luceneMatchVersion>

<!-- <lib/> directives can be used to instruct Solr to load any Jars
identified and use them to resolve any "plugins" specified in
Expand Down Expand Up @@ -360,6 +360,21 @@
-->
<maxBooleanClauses>${solr.max.booleanClauses:1024}</maxBooleanClauses>

<!-- Minimum acceptable prefix-size for prefix-based queries.
Prefix-based queries consume memory in proportion to the number of terms in the index
that start with that prefix. Short prefixes tend to match many many more indexed-terms
and consume more memory as a result, sometimes causing stability issues on the node.
This setting allows administrators to require that prefixes meet or exceed a specified
minimum length requirement. Prefix queries that don't meet this requirement return an
error to users. The limit may be overridden on a per-query basis by specifying a
'minPrefixQueryTermLength' local-param value.
The flag value of '-1' can be used to disable enforcement of this limit.
-->
<minPrefixQueryTermLength>${solr.query.minPrefixLength:-1}</minPrefixQueryTermLength>

<!-- Solr Internal Query Caches
Starting with Solr 9.0 the default cache implementation used is CaffeineCache.
-->
Expand Down Expand Up @@ -657,7 +672,7 @@
<str name="pf">title^1.1 description^1.05 author^1.05 tags url content</str>
<str name="boost">product( sum(1, log(sum(1, product(indexed_inlink_domains_count, 1.8)))), if(contains_adverts,0.5,1), if(owner_verified,1.1,1) )</str>
<!-- end searchmysite change -->

</lst>
</requestHandler>

Expand Down Expand Up @@ -911,6 +926,10 @@
<str name="pattern">[^\w-\.]</str>
<str name="replacement">_</str>
</updateProcessor>
<updateProcessor class="solr.NumFieldLimitingUpdateRequestProcessorFactory" name="max-fields">
<int name="maxFields">1000</int>
<bool name="warnOnly">true</bool>
</updateProcessor>
<updateProcessor class="solr.ParseBooleanFieldUpdateProcessorFactory" name="parse-boolean"/>
<updateProcessor class="solr.ParseLongFieldUpdateProcessorFactory" name="parse-long"/>
<updateProcessor class="solr.ParseDoubleFieldUpdateProcessorFactory" name="parse-double"/>
Expand Down Expand Up @@ -954,12 +973,11 @@
<str name="fieldType">pdoubles</str>
</lst>
</updateProcessor>


<!-- The update.autoCreateFields property can be turned to false to disable schemaless mode -->
<!-- start searchmysite change -->
<updateRequestProcessorChain name="add-unknown-fields-to-the-schema" default="${update.autoCreateFields:false}"
processor="uuid,remove-blank,field-name-mutating,parse-boolean,parse-long,parse-double,parse-date,add-schema-fields">
<!-- end searchmysite change -->
<updateRequestProcessorChain name="add-unknown-fields-to-the-schema" default="${update.autoCreateFields:true}"
processor="uuid,remove-blank,field-name-mutating,max-fields,parse-boolean,parse-long,parse-double,parse-date,add-schema-fields">
<processor class="solr.LogUpdateProcessorFactory"/>
<processor class="solr.DistributedUpdateProcessorFactory"/>
<processor class="solr.RunUpdateProcessorFactory"/>
Expand Down

0 comments on commit 82452bb

Please sign in to comment.