一、安装包7.3.2
镜像地址:
https://thans.cn/mirror/elasticsearch.html
elasticsearch-7.3.2-windows-x86_64.zip
链接:https://pan.baidu.com/s/1opn3W5YJ4hANSwYVDqx8xA
提取码:atok
elasticsearch-head-master.zip
链接:https://pan.baidu.com/s/1-Jj-ueZzXvfqCINM0yqOPg
提取码:oi2a
node.js
链接:https://pan.baidu.com/s/1ga2QxLbE_eBBDPrdCKNlxQ
提取码:ow1p
使用ali镜像cnpm
npm install cnpm -g --registry=https://registry.npm.taobao.org
按装 phantomjs
cnpm install -g phantomjs-prebuilt --ignore-scripts
再解压后文件elasticsearch-head-master中启动
安装ik 分词器
链接:https://pan.baidu.com/s/1dsjcNIcFe0Nma2FPLKLqvw
提取码:p68w
postman:
成功:
2、创建mappings
{
"properties": {
"createTime": {
"type": "date",
"format":"yyyy-MM-dd HH:mm:ss"
},
"updateTime": {
"type": "date",
"format":"yyyy-MM-dd HH:mm:ss"
},
"dynamicId": {
"type": "text"
},
"createBy": {
"type": "text"
},
"updateBy": {
"type": "text"
},
"userAccount": {
"type": "text"
},
"userNickName": {
"type": "text"
},
"userPhone": {
"type": "text"
},
"headUrl": {
"type": "text"
},
"textContent": {
"analyzer": "ik_smart",
"type": "text"
},
"fileId": {
"type": "text"
},
"cover": {
"type": "text"
},
"coverSize": {
"type": "text"
},
"contentAddress": {
"type": "text"
},
"contentUrl": {
"type": "text"
},
"issueDynamicScore": {
"type": "text"
},
"id": {
"type": "long"
},
"contentType": {
"type": "long"
},
"thumbsNum": {
"type": "long"
},
"maxThumbsNum": {
"type": "long"
},
"browseNum": {
"type": "long"
},
"shareNum": {
"type": "long"
},
"auditStatus": {
"type": "long"
},
"dynamicScore": {
"type": "long"
}
}
}
成功