Synonym filter fails to properly load synonyms (since 0.17.7), closes #1392.

This commit is contained in:
Shay Banon 2011-10-13 00:18:01 +02:00
parent 19ff93b09a
commit ffc74260ac
1 changed files with 3 additions and 0 deletions

View File

@ -86,6 +86,9 @@ public class SynonymTokenFilterFactory extends AbstractTokenFilterFactory {
CustomSynonymParser parser = new CustomSynonymParser(true, expand, analyzer);
try {
for (String rule : rules) {
parser.addLine(rule);
}
synonymMap = parser.build();
} catch (IOException e) {
throw new ElasticSearchIllegalArgumentException("failed to build synonyms", e);