动态更新热更新同义词此文有讲http://www.cnblogs.com/kaynet/p/6185859.html
基本配置:
index:
analysis:
filter:
my_types:
type: keep_types
types: ["SYNONYM","CN_WORD","LETTER","ENGLISH","ARABIC","COUNT"]
my_synonym:
type: synonym
synonyms_path: synonym.txt
tokenizer:
comma:
type: pattern
pattern: ","
sem:
type: pattern
pattern: ";"
analyzer:
ik_max_word:
type: ik
use_smart: false
ik_smart:
type: ik
use_smart: true
ik_types:
type: custom
tokenizer: ik
filter: [my_types]
ik_syno:
type: custom
tokenizer: ik
filter: [my_synonym]
ik_syno_types:
type: custom
tokenizer: ik
filter: [my_synonym,my_types]
comma:
type: custom
tokenizer: comma
sem:
type: custom
tokenizer: sem
cluster.name: my_search
node.name: host1
network.host: 0.0.0.0
discovery.zen.ping.unicast.hosts: [ "host2", "host3"]
discovery.zen.ping.multicast.enabled: false
threadpool.bulk.type: fixed
threadpool.bulk.size: 500
threadpool.bulk.queue_size: 2000
index.refresh_interval: 30s
index.translog.flush_threshold_ops: 50000
indices.fielddata.cache.size: 15%
indices.fielddata.cache.expire: 6h
indices.cache.filter.size: 15%
indices.cache.filter.expire: 6h
indices.memory.index_buffer_size: 30%
indices.memory.min_shard_index_buffer_size: 12mb
indices.memory.min_index_buffer_size: 96mb
threadpool.search.type: fixed
threadpool.search.size: 20
threadpool.search.queue_size: 100
threadpool.index.type: fixed
threadpool.index.size: 20
threadpool.index.queue_size: 100
bootstrap.mlockall: true
script.engine.groovy.inline.search: on