From 45dfe9abb60b3eb7ba567866e160b7ea2fe3b739 Mon Sep 17 00:00:00 2001 From: David Pilato Date: Wed, 28 May 2014 10:14:57 +0200 Subject: [PATCH] Update to elasticsearch 1.3.0 Closes #21. (cherry picked from commit a1b37f6) --- README.md | 5 +++-- .../analysis/SimpleSmartChineseIntegrationTests.java | 11 +++++++++++ 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 11978c84638..439bc5fa1ac 100644 --- a/README.md +++ b/README.md @@ -3,10 +3,11 @@ Smart Chinese Analysis for Elasticsearch The Smart Chinese Analysis plugin integrates Lucene Smart Chinese analysis module into elasticsearch. -In order to install the plugin, simply run: `bin/plugin -install elasticsearch/elasticsearch-analysis-smartcn/2.0.0`. +In order to install the plugin, simply run: `bin/plugin -install elasticsearch/elasticsearch-analysis-smartcn/2.1.0`. * For master elasticsearch versions, look at [master branch](https://github.com/elasticsearch/elasticsearch-analysis-smartcn/tree/master). -* For 1.2.x elasticsearch versions, look at [es-1.1 branch](https://github.com/elasticsearch/elasticsearch-analysis-smartcn/tree/es-1.2). +* For 1.3.x elasticsearch versions, look at [es-1.3 branch](https://github.com/elasticsearch/elasticsearch-analysis-smartcn/tree/es-1.3). +* For 1.2.x elasticsearch versions, look at [es-1.2 branch](https://github.com/elasticsearch/elasticsearch-analysis-smartcn/tree/es-1.2). * For 1.1.x elasticsearch versions, look at [es-1.1 branch](https://github.com/elasticsearch/elasticsearch-analysis-smartcn/tree/es-1.1). * For 1.0.x elasticsearch versions, look at [es-1.0 branch](https://github.com/elasticsearch/elasticsearch-analysis-smartcn/tree/es-1.0). * For 0.90.x elasticsearch versions, look at [es-0.90 branch](https://github.com/elasticsearch/elasticsearch-analysis-smartcn/tree/es-0.90). diff --git a/src/test/java/org/elasticsearch/index/analysis/SimpleSmartChineseIntegrationTests.java b/src/test/java/org/elasticsearch/index/analysis/SimpleSmartChineseIntegrationTests.java index 292da7b4b27..7c5e7bb17d3 100644 --- a/src/test/java/org/elasticsearch/index/analysis/SimpleSmartChineseIntegrationTests.java +++ b/src/test/java/org/elasticsearch/index/analysis/SimpleSmartChineseIntegrationTests.java @@ -20,6 +20,9 @@ package org.elasticsearch.index.analysis; import org.elasticsearch.action.admin.indices.analyze.AnalyzeResponse; +import org.elasticsearch.common.settings.ImmutableSettings; +import org.elasticsearch.common.settings.Settings; +import org.elasticsearch.plugins.PluginsService; import org.elasticsearch.test.ElasticsearchIntegrationTest; import org.junit.Test; @@ -30,6 +33,14 @@ import static org.hamcrest.CoreMatchers.*; @ElasticsearchIntegrationTest.ClusterScope(numDataNodes = 1, scope = ElasticsearchIntegrationTest.Scope.SUITE) public class SimpleSmartChineseIntegrationTests extends ElasticsearchIntegrationTest { + @Override + protected Settings nodeSettings(int nodeOrdinal) { + return ImmutableSettings.builder() + .put(super.nodeSettings(nodeOrdinal)) + .put("plugins." + PluginsService.LOAD_PLUGIN_FROM_CLASSPATH, true) + .build(); + } + @Test public void testSmartcnAnalyzer() throws ExecutionException, InterruptedException { AnalyzeResponse response = client().admin().indices()