Skip to content

Commit

Permalink
Update to Elasticsearch 6.1.2!
Browse files Browse the repository at this point in the history
  • Loading branch information
damienalexandre committed Jan 19, 2018
1 parent 510f657 commit 0d486c9
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
11 changes: 7 additions & 4 deletions esplugin/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ The plugin version must match your Elasticsearch version.
```
bin/elasticsearch-plugin install URL
# For 5.6.6:
bin/elasticsearch-plugin install https://github.com/jolicode/emoji-search/releases/download/5.6.6/analysis-emoji-5.6.6.zip
# For 6.1.2:
bin/elasticsearch-plugin install https://github.com/jolicode/emoji-search/releases/download/6.1.2/analysis-emoji-6.1.2.zip
```

## Versions
Expand All @@ -21,6 +21,7 @@ ICU is always up to date to the latest data in this plugin, so upgrading may req

analysis-emoji version and ES version | Install URL
-----------|-----------
6.1.2 | https://github.com/jolicode/emoji-search/releases/download/6.1.2/analysis-emoji-6.1.2.zip
5.6.6 | https://github.com/jolicode/emoji-search/releases/download/5.6.6/analysis-emoji-5.6.6.zip
5.5.0 | https://github.com/jolicode/emoji-search/releases/download/5.5.0/analysis-emoji-5.5.0.zip
5.4.3 | https://github.com/jolicode/emoji-search/releases/download/5.4.3/analysis-emoji-5.4.3.zip
Expand Down Expand Up @@ -86,14 +87,16 @@ PUT /en-emoji
Try it:

```json
GET /en-emoji/_analyze?analyzer=english_with_emoji
GET /en-emoji/_analyze
{
"analyzer": "english_with_emoji",
"text": "I live in 🇫🇷 and I'm 👩‍🚀"
}
# Result: i live in 🇫🇷 france and i'm 👩‍🚀 astronaut rocket woman

GET /en-emoji/_analyze?analyzer=english_with_emoji
GET /en-emoji/_analyze
{
"analyzer": "english_with_emoji",
"text": "Hi mom :)"
}
# Result: hi mom 😃 face mouth open smile
Expand Down
7 changes: 2 additions & 5 deletions esplugin/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,17 @@ buildscript {
jcenter()
}
dependencies {
classpath "org.elasticsearch.gradle:build-tools:5.6.6"
classpath "org.elasticsearch.gradle:build-tools:6.1.2"
}
}

group = 'org.elasticsearch.plugin'
version = '5.6.6'
version = '6.1.2'

apply plugin: 'java'
apply plugin: 'elasticsearch.esplugin'
apply plugin: 'idea'

// this is temporal and will be fixed in 6.0
ext.projectSubstitutions = [:]

esplugin {
name 'analysis-emoji'
description 'Add support for emoji in Elasticsearch'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public void testSimpleIcuTokenizer() throws IOException {
.put(Environment.PATH_HOME_SETTING.getKey(), createTempDir())
.build();

Environment env = new Environment(nodeSettings);
Environment env = new Environment(nodeSettings, null);

// Build the Tokenizer
TokenizerFactory tokenizerFactory = new EmojiTokenizerFactory(
Expand Down

0 comments on commit 0d486c9

Please sign in to comment.