Skip to content

Instantly share code, notes, and snippets.

@devmessias
Created March 23, 2015 16:20
Show Gist options
  • Save devmessias/e3190c6eb4e768768f17 to your computer and use it in GitHub Desktop.
Save devmessias/e3190c6eb4e768768f17 to your computer and use it in GitHub Desktop.
curl -XPOST 'localhost:9200/haystack/_close'
curl -XPUT "http://localhost:9200/haystack/_settings" -d'{
"index": {
"analysis": {
"analyzer": {
"portugues_analyzer": {
"tokenizer": "standard",
"filter": [
"lowercase",
"stemmer_plural_portugues",
"asciifolding"
]
}
},
"filter": {
"stemmer_plural_portugues": {
"type": "stemmer",
"name": "minimal_portuguese"
}
}
}
},
"mappings": {
"modelresult": {
"properties": {
"name": {
"type": "string",
"analyzer": "portugues_analyzer"
},
"description": {
"type": "string",
"analyzer": "portugues_analyzer"
},
"username": {
"type": "string",
"analyzer": "portugues_analyzer"
}
}
}
}
}'
curl -XPOST 'localhost:9200/haystack/_open'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment