数据从 mongo 同步到 es, 有张 document 的 field 数量有几百个, 如何使用template为所有字段指定分词器,下面是我的例子:
the data is syncronized from mongo to es, and there is a document which has hunderds of fields, so i want to know how can i create a template to spicify analyzer for all fields, below is my example :
{
"order": 0,
"template": "*",
"settings": {
"index": {
"number_of_shards": "1",
"number_of_replicas": "0"
}
},
"mappings": {
"T_CF_FormInst_Custom": {
"_all": {
"search_analyzer": "ik_max_word",
"analyzer": "ik_max_word",
"term_vector": "no",
"store": "false"
}
}
},
"aliases": {}
}
the data is syncronized from mongo to es, and there is a document which has hunderds of fields, so i want to know how can i create a template to spicify analyzer for all fields, below is my example :
{
"order": 0,
"template": "*",
"settings": {
"index": {
"number_of_shards": "1",
"number_of_replicas": "0"
}
},
"mappings": {
"T_CF_FormInst_Custom": {
"_all": {
"search_analyzer": "ik_max_word",
"analyzer": "ik_max_word",
"term_vector": "no",
"store": "false"
}
}
},
"aliases": {}
}
1 个回复
medcl - 今晚打老虎。
赞同来自: