创建索引
s3 索引名称
PUT api 请求方式
body->json
{
"settings": {
"number_of_shards": 5
},
"mappings": {
// "_doc":{
"properties":{
"url":{
"type": "text"
},
"key_zh": {
"type": "text",
"analyzer": "ik_max_word"
},
"key_ug": {
"type": "text",
"analyzer": "ik_max_word"
},
"x_axis":{
"type": "float"
},
"y_axis":{
"type": "float"
},
"have_word":{
"type": "float"
}
}
}
// }
}
查看索引信息
查看所有数据
查看具体数据
1002 是数据id
清空数据
http://192.168.182.130:9200/s2/doc/_delete_by_query?pretty POST
{
"query": {
"match_all": {
}
}
}
注:其他的看 http://www.ruanyifeng.com/blog/2017/08/elasticsearch.html