es 实战练习
作者:互联网
准备工作,启动es , 打开postman--》body- row-json
增加数据 注意put 方法
PUT /megacorp/employee/1
{
"first_name" : "John",
"last_name" : "Smith",
"age" : 25,
"about" : "I love to go rock climbing",
"interests": [ "sports", "music" ]
}
PUT /megacorp/employee/2
{
"first_name" : "Jane",
"last_name" : "Smith",
"age" : 32,
"about" : "I like to collect rock albums",
"interests": [ "music" ]
}
PUT /megacorp/employee/3
{
"first_name" : "Douglas",
"last_name" : "Fir",
"age" : 35,
"about": "I like to build cabinets",
"interests": [ "forestry" ]
}
查询数据 注意是get方法
http://localhost:9200/megacorp/employee/1
标签:实战,interests,about,last,name,练习,megacorp,employee,es 来源: https://blog.csdn.net/qq_35306443/article/details/100273749