1
我想索引只有我明確寫入映射模板的字段。我沒有興趣在其他領域,所以我試圖用在所有領域和所有mapping_type匹配dynamic_template選項index:no
,但我不能這樣達到我的期望,因爲我仍然能夠在不必要的字段進行搜索:跳過索引並跳過存儲未映射的字段
"dynamic_templates": [
{
"not_indexed": {
"match": "*",
"match_mapping_type": "*",
"mapping": {
"index": "no"
}
}
}
]
解決您可以打印您的映射? GET//_mapping –
Bax
這似乎違背了無模式數據庫的思想。 – jhilden
你是完全正確的。但我對節省磁盤空間感興趣 – tyranitar