关于source-store实验结果
2016-07-22 00:00
302 查看
分别建立,两类索引,用来开启和关闭_source
浏览链接:http://172.16.71.241:9200/_plugin/head/
1. 开启_source字段
curl -XPUT localhost:9200/test -d '{
"settings" : {
"number_of_shards" : 3
},
"mappings":{
"source":{
"_all":{"enabled":false},
"_ttl":{"enabled":true},
"_source":{"enabled":true},
"properties":{
"id":{"type":"long","store":false,"doc_values":true},
"name":{"type":"string","store":false,"index":"not_analyzed"},
"alis":{"type":"string","store":true,"index":"not_analyzed"},
"runTime":{"type":"string","store":false,"index":"not_analyzed"},
"number":{"type":"string","store":false,"index":"not_analyzed"}
}}}
}'
实验结果:都可以搜索
2. 关闭_source字段
curl -XPUT localhost:9200/store -d '{
"settings" : {
"number_of_shards" : 3
},
"mappings":{
"test":{
"_all":{"enabled":false},
"_ttl":{"enabled":true},
"_source":{"enabled":false},
"properties":{
"id":{"type":"long","store":false,"doc_values":true},
"name":{"type":"string","store":true,"index":"not_analyzed"},
"alis":{"type":"string","store":false,"index":"not_analyzed"},
"runTime":{"type":"string","store":true,"index":"not_analyzed"},
"number":{"type":"string","store":true,"index":"not_analyzed"}
}}}
}'
实验结果:有待验证
浏览链接:http://172.16.71.241:9200/_plugin/head/
1. 开启_source字段
curl -XPUT localhost:9200/test -d '{
"settings" : {
"number_of_shards" : 3
},
"mappings":{
"source":{
"_all":{"enabled":false},
"_ttl":{"enabled":true},
"_source":{"enabled":true},
"properties":{
"id":{"type":"long","store":false,"doc_values":true},
"name":{"type":"string","store":false,"index":"not_analyzed"},
"alis":{"type":"string","store":true,"index":"not_analyzed"},
"runTime":{"type":"string","store":false,"index":"not_analyzed"},
"number":{"type":"string","store":false,"index":"not_analyzed"}
}}}
}'
实验结果:都可以搜索
2. 关闭_source字段
curl -XPUT localhost:9200/store -d '{
"settings" : {
"number_of_shards" : 3
},
"mappings":{
"test":{
"_all":{"enabled":false},
"_ttl":{"enabled":true},
"_source":{"enabled":false},
"properties":{
"id":{"type":"long","store":false,"doc_values":true},
"name":{"type":"string","store":true,"index":"not_analyzed"},
"alis":{"type":"string","store":false,"index":"not_analyzed"},
"runTime":{"type":"string","store":true,"index":"not_analyzed"},
"number":{"type":"string","store":true,"index":"not_analyzed"}
}}}
}'
实验结果:有待验证
相关文章推荐
- Making the best use of caches
- Allocation awareness分配意识
- Balancing JVM heap size and OS caches
- html5兼容ie8 ie9
- UVa 116
- Android应用逆向——最好用的两个无源码调试器
- 提高项目41-命令行加法器
- Unity初识iTween
- CodeForces Gym 100646C LCR
- java中集合的分类
- 套接字描述符的理解
- OSI七层与TCP/IP五层网络架构详解
- java中有关内部类的相关问题
- MSP430单片机外围晶振设计选型及参考方案
- [SPI]如何确定和设定spi传输的时序
- 西安微信网站建设教您如何选择微信开发公司
- Bootstrap-路径导航源码摘记
- Centos 使用yum安装及卸载软件
- 学习Git
- 本地代码仓库push时:error: failed to push some refs to