From a375f53c4633745cb462e771d7f63faef77d4394 Mon Sep 17 00:00:00 2001 From: Vincenzo De Naro Papa Date: Fri, 13 Sep 2019 11:45:28 +0200 Subject: [PATCH] Updated config to support search_api_solr 8.x-3.x --- .../solr-drupal/solr7.5/conf/accents_en.txt | 164 +++++++++++ .../solr-drupal/solr7.5/conf/accents_und.txt | 148 ++++++++++ .../solr7.5/conf/mapping-ISOLatin1Accent.txt | 14 - images/solr-drupal/solr7.5/conf/protwords.txt | 7 - .../solr-drupal/solr7.5/conf/protwords_en.txt | 1 + .../solr7.5/conf/protwords_und.txt | 1 + images/solr-drupal/solr7.5/conf/schema.xml | 266 ++--------------- .../solr7.5/conf/schema_extra_fields.xml | 102 ++++++- .../solr7.5/conf/schema_extra_types.xml | 271 ++++++++++++++---- .../solr7.5/conf/schema_legacy_fields.xml | 61 ---- .../solr7.5/conf/schema_legacy_types.xml | 14 - .../solr-drupal/solr7.5/conf/solrconfig.xml | 53 +--- .../solr7.5/conf/solrconfig_extra.xml | 64 ++++- .../solr7.5/conf/solrconfig_spellcheck.xml | 89 ------ .../solr7.5/conf/solrcore.properties | 13 +- images/solr-drupal/solr7.5/conf/stopwords.txt | 4 - .../solr-drupal/solr7.5/conf/stopwords_en.txt | 35 +++ .../solr7.5/conf/stopwords_und.txt | 1 + images/solr-drupal/solr7.5/conf/synonyms.txt | 3 - .../solr-drupal/solr7.5/conf/synonyms_en.txt | 1 + .../solr-drupal/solr7.5/conf/synonyms_und.txt | 1 + 21 files changed, 751 insertions(+), 562 deletions(-) create mode 100644 images/solr-drupal/solr7.5/conf/accents_en.txt create mode 100644 images/solr-drupal/solr7.5/conf/accents_und.txt delete mode 100644 images/solr-drupal/solr7.5/conf/mapping-ISOLatin1Accent.txt delete mode 100644 images/solr-drupal/solr7.5/conf/protwords.txt create mode 100644 images/solr-drupal/solr7.5/conf/protwords_en.txt create mode 100644 images/solr-drupal/solr7.5/conf/protwords_und.txt delete mode 100644 images/solr-drupal/solr7.5/conf/schema_legacy_fields.xml delete mode 100644 images/solr-drupal/solr7.5/conf/schema_legacy_types.xml delete mode 100644 images/solr-drupal/solr7.5/conf/solrconfig_spellcheck.xml delete mode 100644 images/solr-drupal/solr7.5/conf/stopwords.txt create mode 100644 images/solr-drupal/solr7.5/conf/stopwords_en.txt create mode 100644 images/solr-drupal/solr7.5/conf/stopwords_und.txt delete mode 100644 images/solr-drupal/solr7.5/conf/synonyms.txt create mode 100644 images/solr-drupal/solr7.5/conf/synonyms_en.txt create mode 100644 images/solr-drupal/solr7.5/conf/synonyms_und.txt diff --git a/images/solr-drupal/solr7.5/conf/accents_en.txt b/images/solr-drupal/solr7.5/conf/accents_en.txt new file mode 100644 index 0000000000..bed051477b --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/accents_en.txt @@ -0,0 +1,164 @@ +# À => A +"\u00C0" => "A" +# Á => A +"\u00C1" => "A" +#  => A +"\u00C2" => "A" +# à => A +"\u00C3" => "A" +# Ä => A +"\u00C4" => "A" +# Å => A +"\u00C5" => "A" +# Ą => A +"\u0104" => "A" +# Æ => AE +"\u00C6" => "AE" +# Ç => C +"\u00C7" => "C" +# Ć => C +"\U0106" => "C" +# È => E +"\u00C8" => "E" +# É => E +"\u00C9" => "E" +# Ê => E +"\u00CA" => "E" +# Ë => E +"\u00CB" => "E" +# Ę => E +"\u0118" => "E" +# Ì => I +"\u00CC" => "I" +# Í => I +"\u00CD" => "I" +# Î => I +"\u00CE" => "I" +# Ï => I +"\u00CF" => "I" +# IJ => IJ +"\u0132" => "IJ" +# Ð => D +"\u00D0" => "D" +# Ł => L +"\u0141" => "L" +# Ñ => N +"\u00D1" => "N" +# Ń => N +"\u0143" => "N" +# Ò => O +"\u00D2" => "O" +# Ó => O +"\u00D3" => "O" +# Ô => O +"\u00D4" => "O" +# Õ => O +"\u00D5" => "O" +# Ö => O +"\u00D6" => "O" +# Ø => O +"\u00D8" => "O" +# Œ => OE +"\u0152" => "OE" +# Þ +"\u00DE" => "TH" +# Ù => U +"\u00D9" => "U" +# Ú => U +"\u00DA" => "U" +# Û => U +"\u00DB" => "U" +# Ü => U +"\u00DC" => "U" +# Ý => Y +"\u00DD" => "Y" +# Ÿ => Y +"\u0178" => "Y" +# à => a +"\u00E0" => "a" +# á => a +"\u00E1" => "a" +# â => a +"\u00E2" => "a" +# ã => a +"\u00E3" => "a" +# ä => a +"\u00E4" => "a" +# å => a +"\u00E5" => "a" +# æ => ae +"\u00E6" => "ae" +# ç => c +"\u00E7" => "c" +# è => e +"\u00E8" => "e" +# é => e +"\u00E9" => "e" +# ê => e +"\u00EA" => "e" +# ë => e +"\u00EB" => "e" +# ì => i +"\u00EC" => "i" +# í => i +"\u00ED" => "i" +# î => i +"\u00EE" => "i" +# ï => i +"\u00EF" => "i" +# ij => ij +"\u0133" => "ij" +# ð => d +"\u00F0" => "d" +# ñ => n +"\u00F1" => "n" +# ò => o +"\u00F2" => "o" +# ó => o +"\u00F3" => "o" +# ô => o +"\u00F4" => "o" +# õ => o +"\u00F5" => "o" +# ö => o +"\u00F6" => "o" +# ø => o +"\u00F8" => "o" +# œ => oe +"\u0153" => "oe" +# ß => ss +"\u00DF" => "ss" +# Ś => S +"\u015a" => "S" +# þ => th +"\u00FE" => "th" +# ù => u +"\u00F9" => "u" +# ú => u +"\u00FA" => "u" +# û => u +"\u00FB" => "u" +# ü => u +"\u00FC" => "u" +# ý => y +"\u00FD" => "y" +# ÿ => y +"\u00FF" => "y" +# Ź => Z +"\u0179" => "Z" +# Ż => Z +"\u017b" => "Z" +# ff => ff +"\uFB00" => "ff" +# fi => fi +"\uFB01" => "fi" +# fl => fl +"\uFB02" => "fl" +# ffi => ffi +"\uFB03" => "ffi" +# ffl => ffl +"\uFB04" => "ffl" +# ſt => st +"\uFB05" => "st" +# st => st +"\uFB06" => "st" diff --git a/images/solr-drupal/solr7.5/conf/accents_und.txt b/images/solr-drupal/solr7.5/conf/accents_und.txt new file mode 100644 index 0000000000..7c883f87a3 --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/accents_und.txt @@ -0,0 +1,148 @@ +# À => A +"\u00C0" => "A" +# Á => A +"\u00C1" => "A" +#  => A +"\u00C2" => "A" +# à => A +"\u00C3" => "A" +# Ä => A +"\u00C4" => "A" +# Å => A +"\u00C5" => "A" +# Æ => AE +"\u00C6" => "AE" +# Ç => C +"\u00C7" => "C" +# È => E +"\u00C8" => "E" +# É => E +"\u00C9" => "E" +# Ê => E +"\u00CA" => "E" +# Ë => E +"\u00CB" => "E" +# Ì => I +"\u00CC" => "I" +# Í => I +"\u00CD" => "I" +# Î => I +"\u00CE" => "I" +# Ï => I +"\u00CF" => "I" +# IJ => IJ +"\u0132" => "IJ" +# Ð => D +"\u00D0" => "D" +# Ñ => N +"\u00D1" => "N" +# Ò => O +"\u00D2" => "O" +# Ó => O +"\u00D3" => "O" +# Ô => O +"\u00D4" => "O" +# Õ => O +"\u00D5" => "O" +# Ö => O +"\u00D6" => "O" +# Ø => O +"\u00D8" => "O" +# Œ => OE +"\u0152" => "OE" +# Þ +"\u00DE" => "TH" +# Ù => U +"\u00D9" => "U" +# Ú => U +"\u00DA" => "U" +# Û => U +"\u00DB" => "U" +# Ü => U +"\u00DC" => "U" +# Ý => Y +"\u00DD" => "Y" +# Ÿ => Y +"\u0178" => "Y" +# à => a +"\u00E0" => "a" +# á => a +"\u00E1" => "a" +# â => a +"\u00E2" => "a" +# ã => a +"\u00E3" => "a" +# ä => a +"\u00E4" => "a" +# å => a +"\u00E5" => "a" +# æ => ae +"\u00E6" => "ae" +# ç => c +"\u00E7" => "c" +# è => e +"\u00E8" => "e" +# é => e +"\u00E9" => "e" +# ê => e +"\u00EA" => "e" +# ë => e +"\u00EB" => "e" +# ì => i +"\u00EC" => "i" +# í => i +"\u00ED" => "i" +# î => i +"\u00EE" => "i" +# ï => i +"\u00EF" => "i" +# ij => ij +"\u0133" => "ij" +# ð => d +"\u00F0" => "d" +# ñ => n +"\u00F1" => "n" +# ò => o +"\u00F2" => "o" +# ó => o +"\u00F3" => "o" +# ô => o +"\u00F4" => "o" +# õ => o +"\u00F5" => "o" +# ö => o +"\u00F6" => "o" +# ø => o +"\u00F8" => "o" +# œ => oe +"\u0153" => "oe" +# ß => ss +"\u00DF" => "ss" +# þ => th +"\u00FE" => "th" +# ù => u +"\u00F9" => "u" +# ú => u +"\u00FA" => "u" +# û => u +"\u00FB" => "u" +# ü => u +"\u00FC" => "u" +# ý => y +"\u00FD" => "y" +# ÿ => y +"\u00FF" => "y" +# ff => ff +"\uFB00" => "ff" +# fi => fi +"\uFB01" => "fi" +# fl => fl +"\uFB02" => "fl" +# ffi => ffi +"\uFB03" => "ffi" +# ffl => ffl +"\uFB04" => "ffl" +# ſt => st +"\uFB05" => "st" +# st => st +"\uFB06" => "st" diff --git a/images/solr-drupal/solr7.5/conf/mapping-ISOLatin1Accent.txt b/images/solr-drupal/solr7.5/conf/mapping-ISOLatin1Accent.txt deleted file mode 100644 index b92d03c550..0000000000 --- a/images/solr-drupal/solr7.5/conf/mapping-ISOLatin1Accent.txt +++ /dev/null @@ -1,14 +0,0 @@ -# This file contains character mappings for the default fulltext field type. -# The source characters (on the left) will be replaced by the respective target -# characters before any other processing takes place. -# Lines starting with a pound character # are ignored. -# -# For sensible defaults, use the mapping-ISOLatin1Accent.txt file distributed -# with the example application of your Solr version. -# -# Examples: -# "À" => "A" -# "\u00c4" => "A" -# "\u00c4" => "\u0041" -# "æ" => "ae" -# "\n" => " " diff --git a/images/solr-drupal/solr7.5/conf/protwords.txt b/images/solr-drupal/solr7.5/conf/protwords.txt deleted file mode 100644 index cda8581497..0000000000 --- a/images/solr-drupal/solr7.5/conf/protwords.txt +++ /dev/null @@ -1,7 +0,0 @@ -#----------------------------------------------------------------------- -# This file blocks words from being operated on by the stemmer and word delimiter. -& -< -> -' -" diff --git a/images/solr-drupal/solr7.5/conf/protwords_en.txt b/images/solr-drupal/solr7.5/conf/protwords_en.txt new file mode 100644 index 0000000000..8b13789179 --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/protwords_en.txt @@ -0,0 +1 @@ + diff --git a/images/solr-drupal/solr7.5/conf/protwords_und.txt b/images/solr-drupal/solr7.5/conf/protwords_und.txt new file mode 100644 index 0000000000..8b13789179 --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/protwords_und.txt @@ -0,0 +1 @@ + diff --git a/images/solr-drupal/solr7.5/conf/schema.xml b/images/solr-drupal/solr7.5/conf/schema.xml index fcc662aec5..5c416bc0db 100644 --- a/images/solr-drupal/solr7.5/conf/schema.xml +++ b/images/solr-drupal/solr7.5/conf/schema.xml @@ -49,7 +49,7 @@ that avoids logging every request --> - + - - - - - - + + - - + + @@ -181,28 +175,15 @@ - - + + - - - - - - - - - - - - - - - - + + + - - @@ -212,8 +193,8 @@ - - + + @@ -250,16 +231,9 @@ - - - - - - - @@ -398,220 +372,24 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + diff --git a/images/solr-drupal/solr7.5/conf/schema_extra_fields.xml b/images/solr-drupal/solr7.5/conf/schema_extra_fields.xml index 4cb53eaa68..f5d74188a5 100644 --- a/images/solr-drupal/solr7.5/conf/schema_extra_fields.xml +++ b/images/solr-drupal/solr7.5/conf/schema_extra_fields.xml @@ -1,13 +1,89 @@ - -Don't use the config XML templates directly. Use the config generator to get -your individual config files. Use the "Get config.zip" button in the UI or -drush solr-gsc my_solr_server -See INSTALL.md for details. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/images/solr-drupal/solr7.5/conf/schema_extra_types.xml b/images/solr-drupal/solr7.5/conf/schema_extra_types.xml index 38b90dcb64..8b5e82f035 100644 --- a/images/solr-drupal/solr7.5/conf/schema_extra_types.xml +++ b/images/solr-drupal/solr7.5/conf/schema_extra_types.xml @@ -1,59 +1,228 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - + + diff --git a/images/solr-drupal/solr7.5/conf/schema_legacy_fields.xml b/images/solr-drupal/solr7.5/conf/schema_legacy_fields.xml deleted file mode 100644 index 902bb28e75..0000000000 --- a/images/solr-drupal/solr7.5/conf/schema_legacy_fields.xml +++ /dev/null @@ -1,61 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/images/solr-drupal/solr7.5/conf/schema_legacy_types.xml b/images/solr-drupal/solr7.5/conf/schema_legacy_types.xml deleted file mode 100644 index b46da0485e..0000000000 --- a/images/solr-drupal/solr7.5/conf/schema_legacy_types.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - diff --git a/images/solr-drupal/solr7.5/conf/solrconfig.xml b/images/solr-drupal/solr7.5/conf/solrconfig.xml index 8f668c5b76..8834f220d9 100644 --- a/images/solr-drupal/solr7.5/conf/solrconfig.xml +++ b/images/solr-drupal/solr7.5/conf/solrconfig.xml @@ -1,7 +1,6 @@ ]> @@ -10,7 +9,7 @@ For more details about configurations options that may appear in this file, see http://wiki.apache.org/solr/SolrConfigXml. --> - + + /var/solr/${solr.core.name} @@ -227,7 +224,7 @@ More details on the nuances of each LockFactory... http://wiki.apache.org/lucene-java/AvailableLockFactories --> - ${solr.lock.type:none} + ${solr.lock.type:native} ${solr.selectSearchHandler.timeAllowed:-1} - false - - true - false - - 1 spellcheck @@ -751,7 +742,7 @@ explicit json true - text + id @@ -791,12 +782,8 @@ when performing moreLikeThis requests.--> - content 1 1 - 3 - 15 - 20 false ${solr.mlt.timeAllowed:2000} @@ -806,7 +793,7 @@ - content + id explicit true @@ -814,7 +801,7 @@ - text + id @@ -919,7 +906,7 @@ ${solr.replication.master:false} commit startup - ${solr.replication.confFiles:schema.xml,mapping-ISOLatin1Accent.txt,protwords.txt,stopwords.txt,synonyms.txt,elevate.xml} + ${solr.replication.confFiles:schema.xml,elevate.xml} ${solr.replication.slave:false} @@ -983,16 +970,8 @@ --> - - &spellcheck; + &extra; - spell - - default - wordbreak + id + und on false false @@ -1032,9 +1006,6 @@ - - &extra; - true @@ -1060,7 +1031,7 @@ --> - text + id true @@ -1125,7 +1096,7 @@ explicit - text + id elevator diff --git a/images/solr-drupal/solr7.5/conf/solrconfig_extra.xml b/images/solr-drupal/solr7.5/conf/solrconfig_extra.xml index 0d4102664a..4c71569a02 100644 --- a/images/solr-drupal/solr7.5/conf/solrconfig_extra.xml +++ b/images/solr-drupal/solr7.5/conf/solrconfig_extra.xml @@ -1,12 +1,54 @@ + + + en + spellcheck_en + solr.DirectSolrSpellChecker + internal + 0.5 + 2 + 1 + 5 + 4 + 0.01 + .01 + true + + + + und + spellcheck_und + solr.DirectSolrSpellChecker + internal + 0.5 + 2 + 1 + 5 + 4 + 0.01 + .01 + true + + - - und - AnalyzingInfixLookupFactory - DocumentDictionaryFactory - twm_suggest - text - sm_context_tags - true - false - - + + en + AnalyzingInfixLookupFactory + DocumentDictionaryFactory + twm_suggest + text_en + sm_context_tags + true + false + + + + und + AnalyzingInfixLookupFactory + DocumentDictionaryFactory + twm_suggest + text_und + sm_context_tags + true + false + + diff --git a/images/solr-drupal/solr7.5/conf/solrconfig_spellcheck.xml b/images/solr-drupal/solr7.5/conf/solrconfig_spellcheck.xml deleted file mode 100644 index 5c9d7ad79e..0000000000 --- a/images/solr-drupal/solr7.5/conf/solrconfig_spellcheck.xml +++ /dev/null @@ -1,89 +0,0 @@ - - - - textSpell - - - - - - - default - spell - solr.DirectSolrSpellChecker - - internal - - 0.5 - - 2 - - 1 - - 5 - - 4 - - 0.01 - - - - - - wordbreak - solr.WordBreakSolrSpellChecker - name - true - true - 10 - - - - - - - - - - - diff --git a/images/solr-drupal/solr7.5/conf/solrcore.properties b/images/solr-drupal/solr7.5/conf/solrcore.properties index bec6ba32db..a213961d54 100644 --- a/images/solr-drupal/solr7.5/conf/solrcore.properties +++ b/images/solr-drupal/solr7.5/conf/solrcore.properties @@ -1,20 +1,13 @@ -# Defines Solr properties for this specific core. solr.replication.master=false solr.replication.slave=false solr.replication.pollInterval=00:00:60 -solr.replication.masterUrl=http://localhost:8983/solr -solr.replication.confFiles=schema.xml,mapping-ISOLatin1Accent.txt,protwords.txt,stopwords.txt,synonyms.txt,elevate.xml +solr.replication.masterUrl=http://solr:8983/solr +solr.replication.confFiles=schema.xml,elevate.xml,stopwords_en.txt,synonyms_en.txt,protwords_en.txt,accents_en.txt,stopwords_und.txt,synonyms_und.txt,protwords_und.txt,accents_und.txt solr.mlt.timeAllowed=2000 -# You should not set your luceneMatchVersion to anything lower than your Solr -# Version. -solr.luceneMatchVersion=7.0 +solr.luceneMatchVersion=7.5 solr.selectSearchHandler.timeAllowed=-1 -# don't autoCommit after x docs solr.autoCommit.MaxDocs=-1 -# autoCommit after 15 seconds solr.autoCommit.MaxTime=15000 -# don't autoSoftCommit after x docs solr.autoSoftCommit.MaxDocs=-1 -# don't autoSoftCommit after x seconds solr.autoSoftCommit.MaxTime=-1 solr.install.dir=/opt/solr diff --git a/images/solr-drupal/solr7.5/conf/stopwords.txt b/images/solr-drupal/solr7.5/conf/stopwords.txt deleted file mode 100644 index d7f243e48a..0000000000 --- a/images/solr-drupal/solr7.5/conf/stopwords.txt +++ /dev/null @@ -1,4 +0,0 @@ -# Contains words which shouldn't be indexed for fulltext fields, e.g., because -# they're too common. For documentation of the format, see -# http://wiki.apache.org/solr/AnalyzersTokenizersTokenFilters#solr.StopFilterFactory -# (Lines starting with a pound character # are ignored.) diff --git a/images/solr-drupal/solr7.5/conf/stopwords_en.txt b/images/solr-drupal/solr7.5/conf/stopwords_en.txt new file mode 100644 index 0000000000..6981050710 --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/stopwords_en.txt @@ -0,0 +1,35 @@ +a +an +and +are +as +at +be +but +by +for +if +in +into +is +it +no +not +of +on +or +s +such +t +that +the +their +then +there +these +they +this +to +was +will +with diff --git a/images/solr-drupal/solr7.5/conf/stopwords_und.txt b/images/solr-drupal/solr7.5/conf/stopwords_und.txt new file mode 100644 index 0000000000..8b13789179 --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/stopwords_und.txt @@ -0,0 +1 @@ + diff --git a/images/solr-drupal/solr7.5/conf/synonyms.txt b/images/solr-drupal/solr7.5/conf/synonyms.txt deleted file mode 100644 index 7d22eea6d6..0000000000 --- a/images/solr-drupal/solr7.5/conf/synonyms.txt +++ /dev/null @@ -1,3 +0,0 @@ -# Contains synonyms to use for your index. For the format used, see -# http://wiki.apache.org/solr/AnalyzersTokenizersTokenFilters#solr.SynonymFilterFactory -# (Lines starting with a pound character # are ignored.) diff --git a/images/solr-drupal/solr7.5/conf/synonyms_en.txt b/images/solr-drupal/solr7.5/conf/synonyms_en.txt new file mode 100644 index 0000000000..91689ff92f --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/synonyms_en.txt @@ -0,0 +1 @@ +drupal, durpal diff --git a/images/solr-drupal/solr7.5/conf/synonyms_und.txt b/images/solr-drupal/solr7.5/conf/synonyms_und.txt new file mode 100644 index 0000000000..91689ff92f --- /dev/null +++ b/images/solr-drupal/solr7.5/conf/synonyms_und.txt @@ -0,0 +1 @@ +drupal, durpal