Skip to content

Instantly share code, notes, and snippets.

@sameek
Created January 16, 2012 06:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sameek/1619313 to your computer and use it in GitHub Desktop.
Save sameek/1619313 to your computer and use it in GitHub Desktop.
Custom analyzer Mapping
{"index" : { "_index" : "test1", "_type" : "type1", "_id" : "1", "_analyzer":"myanalyzer" } }
{ "type1" : { "name" : "my name is john" } }
{ "myanalyzer" : {"type" : "custom", "tokenizer" :"whitespace","filter" :["myfilter1"]}}
{"myfilter1":{"type":"stop" "stopwords_path":"D:\resources\stopwords_eng.txt" ,"ignore_case":true}}
{"create" : { "_index" : "test1", "_type" : "type1", "_id" : "1" } }
{ "type1" : { "name" : "my name is john" } }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment