Hi
I want to define both the index_analyzer and search_analyzer
explicitly using mapping. i have read following documents
Index / Search Analyzers
http://www.elasticsearch.org/guide/reference/mapping/root-object-type.html
Analyzer
http://www.elasticsearch.org/guide/reference/index-modules/analysis/
Core Types
http://www.elasticsearch.org/guide/reference/mapping/core-types.html
for reading this document,i am confuse for explicitly defining both.
after some Google i found following link :
after that i have try following mapping:
{
"settings":{
"analysis": {
"analyzer":
{
"index_analyzer": {
"name":"default",
"type" :"custom",
"tokenizer": "whitespace",
"filter": ["lowercase", "customstopfilter", "asciifolding"]
},
"search_analyzer": {
"name":"default",
"type" :"custom",
"tokenizer": "whitespace" ,
"filter": ["lowercase", "customstopfilter", "asciifolding"]
}
},
{
"filter":{
"customstopfilter":
{
"type":"stop" ,
"stopwords_path" :"F:\resources\stopwords_eng.txt" ,
"ignore_case":true
}
}
}
}
}
}
but again i failed to configured it,please help me.
Thanks
try to search the mailing list before
http://groups.google.com/group/elasticsearch/browse_thread/thread/2c3082a47d10ba41/328970161fdc66a0?lnk=gst&q=custom+analyzer#328970161fdc66a0
Peter.
On 18 Jan., 10:10, shammi mishra mishrashamm...@gmail.com wrote:
Hi
I want to define both the index_analyzer and search_analyzer
explicitly using mapping. i have read following documents
Index / Search Analyzershttp://www.elasticsearch.org/guide/reference/mapping/root-object-type...
Analyzerhttp://www.elasticsearch.org/guide/reference/index-modules/analysis/
Core Typeshttp://www.elasticsearch.org/guide/reference/mapping/core-types.html
for reading this document,i am confuse for explicitly defining both.
after some Google i found following link :ElasticSearch Test Queries · GitHub
after that i have try following mapping:
{
"settings":{
"analysis": {
"analyzer":
{
"index_analyzer": {
"name":"default",
"type" :"custom",
"tokenizer": "whitespace",
"filter": ["lowercase", "customstopfilter", "asciifolding"]
},
"search_analyzer": {
"name":"default",
"type" :"custom",
"tokenizer": "whitespace" ,
"filter": ["lowercase", "customstopfilter", "asciifolding"]
}
},
{
"filter":{
"customstopfilter":
{
"type":"stop" ,
"stopwords_path" :"F:\resources\stopwords_eng.txt" ,
"ignore_case":true
}
}
}
}
}
}
but again i failed to configured it,please help me.
Thanks
I mean use java api or elasticsearch.yml/json like here:
{
"network" : {
"host" : "127.0.0.1"
},
"index" : {
"//provided via API number_of_shards": 4,
"//number_of_replicas": 1,
"//refresh_interval" : "20s",
"analysis" : {
"//standard tokenizer removes all punctuation chars so avoid it to have # and @":"comment",
"analyzer" : {
"index_analyzer" : {
"tokenizer" : "whitespace",
"filter" : ["jetwickfilter", "lowercase", "snowball"]
},
"search_analyzer" : {
"tokenizer" : "whitespace",
"filter" : ["jetwickfilter", "lowercase", "snowball"]
}
},
This file has been truncated. show original
On 18 Jan., 14:11, Karussell tableyourt...@googlemail.com wrote:
try to search the mailing list before
http://groups.google.com/group/elasticsearch/browse_thread/thread/2c3 ...
Peter.
On 18 Jan., 10:10, shammi mishra mishrashamm...@gmail.com wrote:
Hi
I want to define both the index_analyzer and search_analyzer
explicitly using mapping. i have read following documents
Index / Search Analyzershttp://www.elasticsearch.org/guide/reference/mapping/root-object-type...
Analyzerhttp://www.elasticsearch.org/guide/reference/index-modules/analysis/
Core Typeshttp://www.elasticsearch.org/guide/reference/mapping/core-types.html
for reading this document,i am confuse for explicitly defining both.
after some Google i found following link :ElasticSearch Test Queries · GitHub
after that i have try following mapping:
{
"settings":{
"analysis": {
"analyzer":
{
"index_analyzer": {
"name":"default",
"type" :"custom",
"tokenizer": "whitespace",
"filter": ["lowercase", "customstopfilter", "asciifolding"]
},
"search_analyzer": {
"name":"default",
"type" :"custom",
"tokenizer": "whitespace" ,
"filter": ["lowercase", "customstopfilter", "asciifolding"]
}
},
{
"filter":{
"customstopfilter":
{
"type":"stop" ,
"stopwords_path" :"F:\resources\stopwords_eng.txt" ,
"ignore_case":true
}
}
}
}
}
}
but again i failed to configured it,please help me.
Thanks