elasticSearch 2.3 delete-by-query plugin
The delete-by-query plugin adds support for deleteing all of the documents which match the specified query.
It is a replacement for the problematic delete-by-query functionality which has been removed from the Elasticsearch core.
Internally, it uses Scolle and Bluk APIs to delete documents in an efficient and safe manner. It is slower than the old delete-by-query functionality, but fixes the problems with the previous implementation.
TIP:
Queries which match large numbers of documents may run for a long time, as every document had to be deleted individually. Don't use delete-by-query to clean out all or most documents in an index. Rather create a new index and perhaps reindex the document you want to keep.
Installation:
This plugin can be installed by the plugin manager:
bin/plugin install delete-by-query
The plugin must be installed on every node in the cluster, and each node must be restarted after installation.
Removal:
This plugin can be removed with the following command:
bin/plugin remove delete-by-query
The node must be stoped before removing the plugin.
Using delete-by-query
The query can be provided using a simple query string as a paremeter.
curl -XDELETE 'localhost:9200/twitter/tweet/_query?q=user:kimchy&pretty'
Delete-by-query supports deletion accoss multiple indics and multiple types.
IMPORTANT:
Delete by query will only delete the version of the document that was visible to search at the time the request was executed. Any documents that have been reindexed or updated during executiong will not be deleted.
The response record some counters for each index, the counters are as follows:
-found:
-deleted:
-missing: The number of documents that were missing when the plugin tried to delete them. Missing documents were percent when the original query was run, but have already been deleted by another process.
-failed:
Scroll Docs
While a search request returns a single page of results, the scroll API can be used to get large numbers of results from a single search request, in much the same way as you would use a cursor on a traditional database.
= =!
学英语系列
elasticSearch 2.3 delete-by-query plugin的更多相关文章
- elasticsearch 5.x Delete By Query API(根据条件删除)
之前在 2.X版本里 这个Delete By Query功能被去掉了 因为官方认为会引发一些错误 如需使用 需要自己安装插件. bin/plugin install delete-by-query 需 ...
- Elasticsearch学习笔记-Delete By Query API
记录关于Elasticsearch的文档删除API的学习 首先官网上Document APIs介绍了 Delete API 和Delete By Query API. Delete API可以通过指定 ...
- elasticsearch 2.4在head删除数据(使用Delete By Query插件)
之所以说明是2.4版,是因为不同版本删除的语法不一样(例如跟5.x就不同) 首先安装Delete By Query插件,方式跟安装head插件差不多,安装命令:plugin install delet ...
- elasticsearch 基础 —— Delete By Query API
Delete By Query API _delete_by_query 的简单用法,就是在查询匹配到的每个文档上执行删除.例如: POST twitter/_delete_by_query { &q ...
- elasticsearch6.7 05. Document APIs(5)Delete By Query API
4.Delete By Query API _delete_by_query API可以删除某个匹配条件的文档: POST twitter/_delete_by_query { "query ...
- Delete PeopleSoft Query From the Database
There could be different reasons why a PeopleSoft developer would like to delete a query from the da ...
- ElasticSearch query_string vs multi_match cross_fields query
ElasticSearch query_string vs multi_match cross_fields query 本文记录以字段为中心的查询和以词为中心的查询这两种查询方式的区别以及在Elas ...
- How to delete the eclipse plugin.
click Help-->installation Details 2. choose the plugin that you want to delete.Then click uninst ...
- Elasticsearch查询——布尔查询Bool Query
Elasticsearch在2.x版本的时候把filter查询给摘掉了,因此在query dsl里面已经找不到filter query了.其实es并没有完全抛弃filter query,而是它的设计与 ...
- Unity Dx9 Occlusion Query plugin
//Occlusion Unity plugin #include "UnityPluginInterface.h" #include <math.h>#include ...
随机推荐
- int 转double , 转float
Integer log = 21424344;Double log1 = log.doubleValue() / 1000000;System.out.println(log1);BigDecimal ...
- 使用Selenium进行浏览器自动化操作记录
一位经验丰富的同事交给了我一个任务:将20个IP地址添加到公司系统对应的目录下. 这个任务之前做过,并且数量是远不止20个,当时就学习Selenium并且使用Python3.6写了一个脚本用来自动化地 ...
- mathematics of deep learning (paper reading)
1.数学上,不变性 2.信息论上
- Python3.7和数据库MySQL 8.0.12 数据库数据驱动mysql-connector安装(四)
安装mysql-connector驱动 在系统CMD输入命令: pip install mysql-connector 示例: 创建数据库 # 导入驱动 import mysql.connector ...
- java.lang.UnsupportedClassVersionError: JVMCFRE003解决方法--jdk 1.6 中switch的参数无法使用String类型
在jdk 1.6版本中,switch的参数无法使用String类型,只支持int,char,enum类型. 1.6版本之前不支持switch语句存在字符串的判断,升级到1.7或1.8及以上版本即可.
- vue 基础重要组件 模板指令 事件绑定
组件:data methods watch new vue({ data:{ a:1, b:[] }, methods:{ dosomething:function(){ this.a++; } }, ...
- python_ 基本语法
一.基础知识: 1.鸡汤 摘抄至 :简明 python 教程 在人生中取得成功,与其说靠天才与机会,不如说靠专注与毅力! Python 特点:简单.易于学习(简单得语法体系).自由且开发.高级语言.跨 ...
- fdsafdsafds
name1 = input('请输入一个名字:') name2 = input('请输入一个名字: ') animal = input('请输入一个名字 :') print('刚按完摩的{}出门看见{ ...
- what are you 弄啥嘞!!!!!!!!!!!!!!!!泛型
1.为什么需要泛型 泛型在Java中有很重要的地位,网上很多文章罗列各种理论,不便于理解,本篇将立足于代码介绍.总结了关于泛型的知识.希望能给你带来一些帮助. 先看下面的代码: List list = ...
- java————数组 简单写出一个管理系统
数组的特点 1, 数组是一块连续的空间,下标描述空间的位置. 2, 下标从0开始,最大下标为数组长度—1.(*.length-1) 3, 数组元素都是变量.(就是每个下标对应的内容).变量的类型 ...