首页 > 其他分享 >es设置max_result_window

es设置max_result_window

时间:2023-01-11 09:45:18浏览次数:31  
标签:max 索引 window result 设置 datasmart es

es设置index.max_result_window(就是from+size,默认大小10000),可通过如下方式修改:

curl -XPUT 192.168.40.31:9200/datasmart/_settings -d '{ "index.max_result_window" :"1000000"}'

成功返回

{"acknowledged":true}

  

这个请求只会对datasmart这个索引起作用,如果是设置所有索引,把datasmart改成_all即可

查询当前max_result_window把PUT改成GET,如:

curl -XGET 192.168.40.31:9200/datasmart/_settings

返回:

{
    "datasmart": {
        "settings": {
            "index": {
                "number_of_shards": "3",
                "provided_name": "datasmart",
                "max_result_window": "1000000",
                "creation_date": "1506303097464",
                "analysis": {
                    "analyzer": {
                        "default": {
                            "type": "smartcn"
                        }
                    }
                },
                "number_of_replicas": "1",
                "uuid": "84ufzn8nQ1-InuxYGHj_IA",
                "version": {
                    "created": "5050199"
                }
            }
        }
    }
}

 这个设置是索引层的,即便是使用_all设置了,看日志也是对逐个索引加这个配置,后续新加的索引,max_result_window默认还是1w

标签:max,索引,window,result,设置,datasmart,es
From: https://www.cnblogs.com/chenzhi2023/p/17042877.html

相关文章

  • Serverless 奇点已来,下一个十年将驶向何方?
    本文整理自QCon上海站2022丁宇(叔同)的演讲内容。以前构建应用,需要买ECS实例,搭建开源软件体系然后维护它,流量大了扩容,流量小了缩容,整个过程非常复杂繁琐。用了Serve......
  • Codeforces Round #843 (Div. 2) 做题记录
    CodeforcesRound#843(Div.2)做题记录A1&A2.GardenerandtheCapybarasProblemCF1775A2GardenerandtheCapybaras题目大意:给你一个由a和b组成的字符串,要......
  • ES6 中 Promise对象使用学习
    转载请注明出处:Promise 对象是JavaScript的异步操作解决方案,为异步操作提供统一接口。它起到代理作用(proxy),充当异步操作与回调函数之间的中介,使得异步操作具备同步......
  • 资源跳转方式2--Respones重定向
    Respones重定向:一种资源跳转方式。(1)浏览器发送给请求服务器,服务器中对应的资源A接受到请求(2)资源A现在无法处理该请求,就会给浏览器响应一个302的状态码+location的一个访......
  • Codeforces 1335E2 Three Blocks Palindrome (hard version)
    链接难度:\(\texttt{1800}\)\(T\)组数据。一个序列\(a_{1\simn}\)。定义\([\underbrace{a,a,\dots,a}_{x},\underbrace{b,b,\dots,b}_{y},\underbrace{a,......
  • [LeetCode] 2272. Substring With Largest Variance
    Thevarianceofastringisdefinedasthelargestdifferencebetweenthenumberofoccurrencesofany2characterspresentinthestring.Notethetwochara......
  • Codeforces Round #843 (Div. 2) C【思维】
    https://codeforces.com/contest/1775/problem/C题意题意是说,给你n和x,你要求出最小的满足要求的m,使得\(n\)&\((n+1)\)&\((n+2)\)&\(...\)&\(m=x\)若没有满足的输出-1......
  • Codeforces Round #843 (Div. 2) A~E
    A.GardenerandtheCapybaras这道题目就是想让我们输出三个字符串,然后又一个要求就是中间这个字符串具有最值(最大或最小)的字典序这里需要注意一下,这个字符串里面只有a......
  • Dubbo-kubernetes 基于 Informer 服务发现优化之路
    作者:丛国庆在Kubernetes(简称K8s,一个可移植容器的编排管理工具)体系中,etcd存储集群的数据信息,kube-apiserver作为统一入口,任何对数据的操作都必须经过kube-apiserver。......
  • Error resolving template [index], template might not exist or might not be acces
    1.thymeleaf依赖<!--thymeleaf--><dependency><groupId>org.springframework.boot</groupId><artifactId>spring-b......