当前位置:网站首页>Es create a new index database and copy the old index library, practice pro test effective!
Es create a new index database and copy the old index library, practice pro test effective!
2020-11-06 21:40:00 【Architects who can drive】
Preface : Index library field encountered in project mapping The problem of mapping type mismatch , Need modification mapping Mapping type , So I thought about deleting the old mappings The redesign mappings Field type and copy data !
First step 、 Let's take a look at the old index library settings、mapping structure
GET /intpolicy/_mapping
GET /intpolicy/_settings?pretty
The second step 、 Take a look at the amount of data in the old index database and compare it after copying
GET /intpolicy/_search
The third step 、 Create a new index library Be careful settings、mapping Do not copy structure errors
PUT intpolicy?include_type_name=false
{
"settings" : {
"index" : {
"number_of_shards" : "1",
"provided_name" : "intpolicy",
"creation_date" : "1578638080477",
"analysis" : {
"analyzer" : {
"numanalyzer" : {
"pattern" : "|",
"type" : "pattern"
}
}
},
"number_of_replicas" : "0",
"uuid" : "cmouqXBLQiyFAJ5BNii8nw",
"version" : {
"created" : "6080599"
}
}
},
"mappings" : {
"_doc" : {
"properties" : {
"advanceTicketLatest" : {
"type" : "short"
},
"advantageType" : {
"type" : "keyword"
},
"arr" : {
"type" : "text"
}
}
}
}
}
The last step Copy the old index database data to the new index library
POST _reindex
{
"source": {
"index": "intpolicy2"
},
"dest": {
"index": "intpolicy"
}
}
版权声明
本文为[Architects who can drive]所创,转载请带上原文链接,感谢
边栏推荐
- What is the tensor in tensorflow?
- ado.net和asp.net的关系
- Unity performance optimization
- Zero basis to build a web search engine of its own
- Why is quicksort so fast?
- Filecoin has completed a major upgrade and achieved four major project progress!
- Introduction to Huawei cloud micro certification examination
- 轻量型 GPU 应用首选 京东智联云推出 NVIDIA vGPU 实例
- 事务的本质和死锁的原理
- ES6 learning notes (5): easy to understand ES6's built-in extension objects
猜你喜欢
Novice guidance and event management system in game development
迅为-iMX6ULL开发板上配置AP热点
An article will introduce you to HTML tables and their main attributes
Zero basis to build a web search engine of its own
预留电池接口,内置充放电电路及电量计,迅为助力轻松搞定手持应用
Method of code refactoring -- Analysis of method refactoring
ES中删除索引的mapping字段时应该考虑的点
How to manage the authority of database account?
All the way, I was forced to talk about C code debugging skills and remote debugging
[forward] how to view UserData in Lua
随机推荐
Introduction to Huawei cloud micro certification examination
Share with Lianyun: is IPFs / filecoin worth investing in?
2020-09-04:函数调用约定了解么?
2020-08-24:什么是小文件?很多小文件会有什么问题?很多小文件怎么解决?(大数据)
Erd-online free online database modeling tool
STM32F030F4P6兼容灵动微MM32F031F4P6
【涂鸦物联网足迹】涂鸦云平台全景介绍
This project allows you to quickly learn about a programming language in a few minutes
CloudQuery V1.2.0 版本发布
迅为-iMX6ULL开发板上配置AP热点
Visual rolling [contrast beauty]
Zero basis to build a web search engine of its own
Look! Internet, e-commerce offline big data analysis best practice! (Internet disk link attached)
An article takes you to understand CSS pagination examples
Basic usage of Vue codemirror: search function, code folding function, get editor value and verify in time
[self taught unity2d legendary game development] map editor
消防器材RFID固定资产管理系统
EOS founder BM: what's the difference between UE, UBI and URI?
An article takes you to understand CSS3 picture border
2020-08-29:进程线程的区别,除了包含关系之外的一些区别,底层详细信息?