暫無描述
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

solr-schema.xml 2.9KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!--
  3. For fts-solr:
  4. This is the Solr schema file, place it into solr/conf/schema.xml. You may
  5. want to modify the tokenizers and filters.
  6. -->
  7. <schema name="dovecot" version="1.4">
  8. <types>
  9. <!-- IMAP has 32bit unsigned ints but java ints are signed, so use longs -->
  10. <fieldType name="string" class="solr.StrField" omitNorms="true"/>
  11. <fieldType name="long" class="solr.LongField" omitNorms="true"/>
  12. <fieldType name="slong" class="solr.SortableLongField" omitNorms="true"/>
  13. <fieldType name="float" class="solr.FloatField" omitNorms="true"/>
  14. <fieldType name="boolean" class="solr.BoolField" omitNorms="true"/>
  15. <fieldType name="text" class="solr.TextField" positionIncrementGap="100">
  16. <analyzer type="index">
  17. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  18. <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
  19. <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="1" catenateNumbers="1" catenateAll="0"/>
  20. <filter class="solr.LowerCaseFilterFactory"/>
  21. <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
  22. <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
  23. </analyzer>
  24. <analyzer type="query">
  25. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  26. <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
  27. <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
  28. <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0"/>
  29. <filter class="solr.LowerCaseFilterFactory"/>
  30. <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
  31. <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
  32. </analyzer>
  33. </fieldType>
  34. </types>
  35. <fields>
  36. <field name="id" type="string" indexed="true" stored="true" required="true" />
  37. <field name="uid" type="slong" indexed="true" stored="true" required="true" />
  38. <field name="box" type="string" indexed="true" stored="true" required="true" />
  39. <field name="user" type="string" indexed="true" stored="true" required="true" />
  40. <field name="hdr" type="text" indexed="true" stored="false" />
  41. <field name="body" type="text" indexed="true" stored="false" />
  42. <field name="from" type="text" indexed="true" stored="false" />
  43. <field name="to" type="text" indexed="true" stored="false" />
  44. <field name="cc" type="text" indexed="true" stored="false" />
  45. <field name="bcc" type="text" indexed="true" stored="false" />
  46. <field name="subject" type="text" indexed="true" stored="false" />
  47. </fields>
  48. <uniqueKey>id</uniqueKey>
  49. <defaultSearchField>body</defaultSearchField>
  50. <solrQueryParser defaultOperator="AND" />
  51. </schema>