Commit 45a99cb5e89a1689cb16c7d817aca9634a02ea8c

Authored by Macartur Sousa
Committed by Sergio Oliveira
1 parent ba755a01

Removing solr_confs and adding in .travis.yml to generate a /tmp/schema.xml

@@ -16,8 +16,8 @@ install: @@ -16,8 +16,8 @@ install:
16 - psql -c "CREATE USER colab WITH PASSWORD 'colab' CREATEDB;" -U postgres 16 - psql -c "CREATE USER colab WITH PASSWORD 'colab' CREATEDB;" -U postgres
17 17
18 before_script: 18 before_script:
19 - - colab-admin build_solr_schema > ci/solr_confs/schema.xml  
20 - - cat ci/install_solr.sh | SOLR_VERSION=4.10.3 SOLR_CONFS="ci/solr_confs" bash 19 + - colab-admin build_solr_schema > /tmp/schema.xml
  20 + - cat ci/install_solr.sh | SOLR_VERSION=4.10.3 SOLR_CONFS="/tmp/schema.xml" bash
21 21
22 script: 22 script:
23 - python setup.py test 23 - python setup.py test
ci/solr_confs/schema.xml
@@ -1,225 +0,0 @@ @@ -1,225 +0,0 @@
1 -<?xml version="1.0" ?>  
2 -<!--  
3 - Licensed to the Apache Software Foundation (ASF) under one or more  
4 - contributor license agreements. See the NOTICE file distributed with  
5 - this work for additional information regarding copyright ownership.  
6 - The ASF licenses this file to You under the Apache License, Version 2.0  
7 - (the "License"); you may not use this file except in compliance with  
8 - the License. You may obtain a copy of the License at  
9 -  
10 - http://www.apache.org/licenses/LICENSE-2.0  
11 -  
12 - Unless required by applicable law or agreed to in writing, software  
13 - distributed under the License is distributed on an "AS IS" BASIS,  
14 - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  
15 - See the License for the specific language governing permissions and  
16 - limitations under the License.  
17 --->  
18 -  
19 -<schema name="default" version="1.5">  
20 - <types>  
21 - <fieldtype name="string" class="solr.StrField" sortMissingLast="true" omitNorms="true"/>  
22 - <fieldType name="boolean" class="solr.BoolField" sortMissingLast="true" omitNorms="true"/>  
23 - <fieldtype name="binary" class="solr.BinaryField"/>  
24 -  
25 - <!-- Numeric field types that manipulate the value into  
26 - a string value that isn't human-readable in its internal form,  
27 - but with a lexicographic ordering the same as the numeric ordering,  
28 - so that range queries work correctly. -->  
29 - <fieldType name="int" class="solr.TrieIntField" precisionStep="0" omitNorms="true" sortMissingLast="true" positionIncrementGap="0"/>  
30 - <fieldType name="float" class="solr.TrieFloatField" precisionStep="0" omitNorms="true" sortMissingLast="true" positionIncrementGap="0"/>  
31 - <fieldType name="long" class="solr.TrieLongField" precisionStep="0" omitNorms="true" sortMissingLast="true" positionIncrementGap="0"/>  
32 - <fieldType name="double" class="solr.TrieDoubleField" precisionStep="0" omitNorms="true" sortMissingLast="true" positionIncrementGap="0"/>  
33 - <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>  
34 - <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>  
35 - <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>  
36 - <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>  
37 -  
38 - <fieldType name="tint" class="solr.TrieIntField" precisionStep="8" omitNorms="true" positionIncrementGap="0"/>  
39 - <fieldType name="tfloat" class="solr.TrieFloatField" precisionStep="8" omitNorms="true" positionIncrementGap="0"/>  
40 - <fieldType name="tlong" class="solr.TrieLongField" precisionStep="8" omitNorms="true" positionIncrementGap="0"/>  
41 - <fieldType name="tdouble" class="solr.TrieDoubleField" precisionStep="8" omitNorms="true" positionIncrementGap="0"/>  
42 -  
43 - <fieldType name="date" class="solr.TrieDateField" omitNorms="true" precisionStep="0" positionIncrementGap="0"/>  
44 - <!-- A Trie based date field for faster date range queries and date faceting. -->  
45 - <fieldType name="tdate" class="solr.TrieDateField" omitNorms="true" precisionStep="6" positionIncrementGap="0"/>  
46 -  
47 - <fieldType name="point" class="solr.PointType" dimension="2" subFieldSuffix="_d"/>  
48 - <fieldType name="location" class="solr.LatLonType" subFieldSuffix="_coordinate"/>  
49 - <fieldtype name="geohash" class="solr.GeoHashField"/>  
50 -  
51 - <fieldType name="text_general" class="solr.TextField" positionIncrementGap="100">  
52 - <analyzer type="index">  
53 - <tokenizer class="solr.StandardTokenizerFactory"/>  
54 - <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />  
55 - <!-- in this example, we will only use synonyms at query time  
56 - <filter class="solr.SynonymFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true" expand="false"/>  
57 - -->  
58 - <filter class="solr.LowerCaseFilterFactory"/>  
59 - </analyzer>  
60 - <analyzer type="query">  
61 - <tokenizer class="solr.StandardTokenizerFactory"/>  
62 - <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />  
63 - <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>  
64 - <filter class="solr.LowerCaseFilterFactory"/>  
65 - </analyzer>  
66 - </fieldType>  
67 -  
68 - <fieldType name="text_en" class="solr.TextField" positionIncrementGap="100">  
69 - <analyzer type="index">  
70 - <tokenizer class="solr.StandardTokenizerFactory"/>  
71 - <filter class="solr.StopFilterFactory"  
72 - ignoreCase="true"  
73 - words="lang/stopwords_en.txt"  
74 - enablePositionIncrements="true"  
75 - />  
76 - <filter class="solr.LowerCaseFilterFactory"/>  
77 - <filter class="solr.EnglishPossessiveFilterFactory"/>  
78 - <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>  
79 - <!-- Optionally you may want to use this less aggressive stemmer instead of PorterStemFilterFactory:  
80 - <filter class="solr.EnglishMinimalStemFilterFactory"/>  
81 - -->  
82 - <filter class="solr.PorterStemFilterFactory"/>  
83 - </analyzer>  
84 - <analyzer type="query">  
85 - <tokenizer class="solr.StandardTokenizerFactory"/>  
86 - <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>  
87 - <filter class="solr.StopFilterFactory"  
88 - ignoreCase="true"  
89 - words="lang/stopwords_en.txt"  
90 - enablePositionIncrements="true"  
91 - />  
92 - <filter class="solr.LowerCaseFilterFactory"/>  
93 - <filter class="solr.EnglishPossessiveFilterFactory"/>  
94 - <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>  
95 - <!-- Optionally you may want to use this less aggressive stemmer instead of PorterStemFilterFactory:  
96 - <filter class="solr.EnglishMinimalStemFilterFactory"/>  
97 - -->  
98 - <filter class="solr.PorterStemFilterFactory"/>  
99 - </analyzer>  
100 - </fieldType>  
101 -  
102 - <fieldType name="text_ws" class="solr.TextField" positionIncrementGap="100">  
103 - <analyzer>  
104 - <tokenizer class="solr.WhitespaceTokenizerFactory"/>  
105 - </analyzer>  
106 - </fieldType>  
107 -  
108 - <fieldType name="ngram" class="solr.TextField" >  
109 - <analyzer type="index">  
110 - <tokenizer class="solr.KeywordTokenizerFactory"/>  
111 - <filter class="solr.LowerCaseFilterFactory"/>  
112 - <filter class="solr.NGramFilterFactory" minGramSize="3" maxGramSize="15" />  
113 - </analyzer>  
114 - <analyzer type="query">  
115 - <tokenizer class="solr.KeywordTokenizerFactory"/>  
116 - <filter class="solr.LowerCaseFilterFactory"/>  
117 - </analyzer>  
118 - </fieldType>  
119 -  
120 - <fieldType name="edge_ngram" class="solr.TextField" positionIncrementGap="1">  
121 - <analyzer type="index">  
122 - <tokenizer class="solr.WhitespaceTokenizerFactory" />  
123 - <filter class="solr.LowerCaseFilterFactory" />  
124 - <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="1"/>  
125 - <filter class="solr.EdgeNGramFilterFactory" minGramSize="2" maxGramSize="15" side="front" />  
126 - </analyzer>  
127 - <analyzer type="query">  
128 - <tokenizer class="solr.WhitespaceTokenizerFactory" />  
129 - <filter class="solr.LowerCaseFilterFactory" />  
130 - <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="1"/>  
131 - </analyzer>  
132 - </fieldType>  
133 - </types>  
134 -  
135 - <fields>  
136 - <!-- general -->  
137 - <field name="id" type="string" indexed="true" stored="true" multiValued="false" required="true"/>  
138 - <field name="django_ct" type="string" indexed="true" stored="true" multiValued="false"/>  
139 - <field name="django_id" type="string" indexed="true" stored="true" multiValued="false"/>  
140 - <field name="_version_" type="long" indexed="true" stored ="true"/>  
141 -  
142 - <dynamicField name="*_i" type="int" indexed="true" stored="true"/>  
143 - <dynamicField name="*_s" type="string" indexed="true" stored="true"/>  
144 - <dynamicField name="*_l" type="long" indexed="true" stored="true"/>  
145 - <dynamicField name="*_t" type="text_en" indexed="true" stored="true"/>  
146 - <dynamicField name="*_b" type="boolean" indexed="true" stored="true"/>  
147 - <dynamicField name="*_f" type="float" indexed="true" stored="true"/>  
148 - <dynamicField name="*_d" type="double" indexed="true" stored="true"/>  
149 - <dynamicField name="*_dt" type="date" indexed="true" stored="true"/>  
150 - <dynamicField name="*_p" type="location" indexed="true" stored="true"/>  
151 - <dynamicField name="*_coordinate" type="tdouble" indexed="true" stored="false"/>  
152 -  
153 -  
154 - <field name="username" type="text_en" indexed="true" stored="false" multiValued="false" />  
155 -  
156 - <field name="google_talk" type="text_en" indexed="true" stored="false" multiValued="false" />  
157 -  
158 - <field name="description" type="text_en" indexed="true" stored="true" multiValued="false" />  
159 -  
160 - <field name="title" type="text_en" indexed="true" stored="true" multiValued="false" />  
161 -  
162 - <field name="webpage" type="text_en" indexed="true" stored="false" multiValued="false" />  
163 -  
164 - <field name="text" type="text_en" indexed="true" stored="false" multiValued="false" />  
165 -  
166 - <field name="institution" type="text_en" indexed="true" stored="true" multiValued="false" />  
167 -  
168 - <field name="message_count" type="long" indexed="true" stored="false" multiValued="false" />  
169 -  
170 - <field name="url" type="string" indexed="false" stored="true" multiValued="false" />  
171 -  
172 - <field name="icon_name" type="text_en" indexed="true" stored="true" multiValued="false" />  
173 -  
174 - <field name="role" type="text_en" indexed="true" stored="true" multiValued="false" />  
175 -  
176 - <field name="contribution_count" type="long" indexed="true" stored="false" multiValued="false" />  
177 -  
178 - <field name="type" type="text_en" indexed="true" stored="true" multiValued="false" />  
179 -  
180 - <field name="email" type="text_en" indexed="true" stored="false" multiValued="false" />  
181 -  
182 - <field name="name" type="text_en" indexed="true" stored="true" multiValued="false" />  
183 -  
184 - <field name="fullname_and_username" type="text_en" indexed="true" stored="false" multiValued="false" />  
185 -  
186 - <field name="modified_by_url" type="text_en" indexed="true" stored="true" multiValued="false" />  
187 -  
188 - <field name="collaborators" type="text_en" indexed="true" stored="false" multiValued="false" />  
189 -  
190 - <field name="tag" type="text_en" indexed="true" stored="true" multiValued="false" />  
191 -  
192 - <field name="fullname" type="text_en" indexed="true" stored="true" multiValued="false" />  
193 -  
194 - <field name="mailinglist_url" type="string" indexed="false" stored="true" multiValued="false" />  
195 -  
196 - <field name="latest_description" type="string" indexed="false" stored="true" multiValued="false" />  
197 -  
198 - <field name="hits" type="long" indexed="true" stored="true" multiValued="false" />  
199 -  
200 - <field name="modified_by" type="text_en" indexed="true" stored="true" multiValued="false" />  
201 -  
202 - <field name="created" type="date" indexed="true" stored="true" multiValued="false" />  
203 -  
204 - <field name="modified" type="date" indexed="true" stored="true" multiValued="false" />  
205 -  
206 - <field name="latest_message_pk" type="long" indexed="false" stored="true" multiValued="false" />  
207 -  
208 - <field name="score" type="long" indexed="true" stored="true" multiValued="false" />  
209 -  
210 - <field name="author_url" type="string" indexed="false" stored="true" multiValued="false" />  
211 -  
212 - <field name="author" type="text_en" indexed="true" stored="true" multiValued="false" />  
213 -  
214 - </fields>  
215 -  
216 - <!-- field to use to determine and enforce document uniqueness. -->  
217 - <uniqueKey>id</uniqueKey>  
218 -  
219 - <!-- field for the QueryParser to use when an explicit fieldname is absent -->  
220 - <defaultSearchField>text</defaultSearchField>  
221 -  
222 - <!-- SolrQueryParser configuration: defaultOperator="AND|OR" -->  
223 - <solrQueryParser defaultOperator="AND"/>  
224 -</schema>  
225 -  
ci/solr_confs/stopwords_en.txt
@@ -1,54 +0,0 @@ @@ -1,54 +0,0 @@
1 -# Licensed to the Apache Software Foundation (ASF) under one or more  
2 -# contributor license agreements. See the NOTICE file distributed with  
3 -# this work for additional information regarding copyright ownership.  
4 -# The ASF licenses this file to You under the Apache License, Version 2.0  
5 -# (the "License"); you may not use this file except in compliance with  
6 -# the License. You may obtain a copy of the License at  
7 -#  
8 -# http://www.apache.org/licenses/LICENSE-2.0  
9 -#  
10 -# Unless required by applicable law or agreed to in writing, software  
11 -# distributed under the License is distributed on an "AS IS" BASIS,  
12 -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  
13 -# See the License for the specific language governing permissions and  
14 -# limitations under the License.  
15 -  
16 -# a couple of test stopwords to test that the words are really being  
17 -# configured from this file:  
18 -stopworda  
19 -stopwordb  
20 -  
21 -# Standard english stop words taken from Lucene's StopAnalyzer  
22 -a  
23 -an  
24 -and  
25 -are  
26 -as  
27 -at  
28 -be  
29 -but  
30 -by  
31 -for  
32 -if  
33 -in  
34 -into  
35 -is  
36 -it  
37 -no  
38 -not  
39 -of  
40 -on  
41 -or  
42 -such  
43 -that  
44 -the  
45 -their  
46 -then  
47 -there  
48 -these  
49 -they  
50 -this  
51 -to  
52 -was  
53 -will  
54 -with