当前位置: 首页 > news >正文

包装设计案例电脑优化软件排行榜

包装设计案例,电脑优化软件排行榜,南京建设信息网站,wordpress ping通告索引 创建索引 创建索引 PUT index_test创建索引 并 修改分片信息 # 创建索引 并 修改分片信息 PUT index_test2 { # 必须换行, PUT XXX 必须独占一行,类似的 其他请求也需要独占一行 "settings": {"number_of_shards": 1, # 主分片"…

索引

创建索引

创建索引

PUT index_test

创建索引 并 修改分片信息

# 创建索引 并 修改分片信息
PUT index_test2
{ # 必须换行, PUT XXX 必须独占一行,类似的 其他请求也需要独占一行 "settings": {"number_of_shards": 1,  # 主分片"number_of_replicas": 2 # 副分片}
}

修改索引

# 只能修改副分片,不能修改主分片
PUT index_test2/_settings
{  "number_of_replicas": 5 }

删除索引

DELETE index_test2

Document

新增

_doc/ID , 新增 or 替换

# 索引名/_doc/唯一ID
# {"key": "value", ...  }
# 如果存在,全量替换;否则,新增
PUT index_test3/_doc/100
{"name": "张三","desc": "法外狂徒"
}

_create/ID , 强制新增

# 索引名/_create/唯一ID
# {"key": "value", ...  }
# 强制新增,如果存在,报错;否则,新增, 必须指定 ID ,不指定ID 报错
PUT index_test3/_create/200
{"name": "张三","desc": "法外狂徒"
}

_doc , 自动生成ID

# 索引名/_doc
# 新增, 自动生成主键
POST index_test3/_doc
{"name": "华为Mate20","desc": "HUAWEI Mate 20搭载7纳米制程AI芯片麒麟980"
}

查询

_search , 查询全部

# 索引名/_search
# 查询全部
GET  index_test3/_search

_doc/id , 单条查询

# 索引名/_doc/id
# 根据 ID 查询单条记录
GET  index_test3/_doc/100

_mget , 批量查询

# 索引名/_mget
# {"docs": [{"_id":100},{"_id":200}]}
# 批量查询
GET index_test3/_mget
{"docs": [{"_id":100},{"_id":200}]
}

更新

_update/id

# 索引名/_update/id
# {"doc":{"key":"value" ,... }}
# 更新, 只更新指定 key;key 不在指定id 中,新增 key
POST index_test3/_update/2ESVL4oB5It7JfWJLnSl
{"doc":{"cpu": 8,"memory": 16}
}

删除

_doc/id

# 索引名/_doc/id
# 删除指定 id 
DELETE index_test3/_doc/200

批量操作

_mget,查询

# 索引名/_mget
# {"docs": [{"_id":100},{"_id":200}]}
# 批量查询
GET index_test3/_mget
{"docs": [{"_id":100},{"_id":200}]
}

_bulk,新增

create , 强制创建

# create 强制创建,如果指定 ID 已存在,则报错;可以不指定 ID, 则ID 自动生成
POST _bulk
{"create":{"_index": "index_test3", "_id": "0826_1301_0001"}}
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}
{"create":{"_index": "index_test3", "_id": "0826_1301_0001"}}
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}
{"create":{"_index": "index_test3"}} 
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}

index , 创建或者全量替换

# index 创建或者全量替换,指定ID 存在,则全量替换;不存在,则创建;不指定 ID, 则ID 自动生成
POST _bulk
{"index":{"_index": "index_test3", "_id": "0826_1301_0002"}}
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}
{"index":{"_index": "index_test3", "_id": "0826_1301_0002"}}
{ "品牌": "华为", "华为型号":"P60 Pro"}
{"index":{"_index": "index_test3"}}
{ "品牌": "华为", "华为型号":"MATE 50"}

混合 , create and index

# 混合,_bulk 允许多个不同行为一起执行,这里是 create index ,
# 也可以和后续的 更新&&删除 一起使用
POST _bulk
{"create":{"_index": "index_test3", "_id": "0826_1301_0001"}}
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}
{"create":{"_index": "index_test3", "_id": "0826_1301_0001"}}
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}
{"create":{"_index": "index_test3"}} 
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}
{"index":{"_index": "index_test3", "_id": "0826_1301_0002"}}
{ "品牌": "华为", "华为型号":"P50 Pro(麒麟版)"}
{"index":{"_index": "index_test3", "_id": "0826_1301_0002"}}
{ "品牌": "华为", "华为型号":"P60 Pro"}
{"index":{"_index": "index_test3"}}
{ "品牌": "华为", "华为型号":"MATE 50"}

_bulk,更新

update , 局部更新

# update 局部更新,指定 ID 存在的字段更新,不存在的字添加
POST _bulk 
{"update":{"_index": "index_test3", "_id": "0826_1301_0002"}}
{ "doc": {"华为型号":"MATE 20", "机身颜色": "曜金黑 冰霜银 流光紫"}}

_bulk,删除

POST _bulk
{"delete": {"_index": "index_test3", "_id": "30RKMIoB5It7JfWJdXRp"}}
{"delete": {"_index": "index_test3", "_id": "4ERKMIoB5It7JfWJdXRp"}}

到此结 DragonFangQy 2023.8.26

http://www.wangmingla.cn/news/158573.html

相关文章:

  • 网站开发语言怎么查百度搜索排名与点击有关吗
  • 做网站策划计划书时空seo助手
  • 怎么查询一个网站从哪做的官网seo怎么做
  • 郑州网络建站公司nba最新排行榜
  • 中港海通网站是谁做的网络营销公司注册找哪家
  • 去哪里找空间做网站推广一单500
  • 要维护公司的网站该怎么做最好的bt种子搜索神器
  • 沈阳市城乡建设局网站游戏优化大师手机版
  • 江苏扬州工程建设信息网站免费建站网站
  • 建设企业网站公连云港seo公司
  • 外贸商城网站系统加速游戏流畅的软件
  • 深圳网站建设公司设计seo广告投放
  • 打开一个不良网站提示创建成功关键词优化怎么弄
  • b2b网站制作seo的优化策略有哪些
  • 网站建设考虑哪些因素百度识图在线入口
  • 株洲做网站需要多少钱淘宝的17种免费推广方法
  • 广州哪里做网站廊坊网站设计
  • 2018年网站优化怎么做外贸营销系统
  • 域名那个网站最靠谱郑州网站制作工具
  • 网站重新备案怎么做深圳seo技术
  • 企业网站每天更新如何自己制作一个网站
  • 如何判断网站程序使用asp还是php杭州优化外包
  • 网站建设自己在家接单优化网站结构一般包括
  • 有谁会设制网站智能营销系统
  • 广州有哪些做网站的公司百度竞价优缺点
  • 做泵阀生意到哪个网站下载谷歌浏览器并安装
  • 上海营销网站建设公司网络推广应该怎么做啊
  • 通信工程建设网站网店推广的作用是什么
  • wordpress广告昆明网站seo服务
  • 大良网站建设基本流程现在有哪些网址