ElasticSearch别名可以指向的索引数量有限吗? [英] Is there a limit to the number of indexes an ElasticSearch alias can point to?

查看:162
本文介绍了ElasticSearch别名可以指向的索引数量有限吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这个别名,我想指向60个索引。在21个索引中,我开始获得执行拒绝的异常。



这是因为别名API中的20个索引限制吗?

解决方案

假设每个索引有5个碎片,对21个索引的请求可能会产生大约105个分片请求,其中32个请求被发送到池中的线程,73个请求进入队列在这一刻,你只剩下约27个元素。因此,如果有6个或更多索引(30个碎片)的另一个请求到达,那么一些shardsrequests将被执行拒绝异常拒绝。我在这里过度简化了这种情况,实际使用的线程数量取决于许多因素,包括碎片位置,搜索设置等。但是,我希望你可以在这里看到主要的想法:如果你想搜索一个大量碎片,您需要确保您的线程池中有足够的容量来处理峰值负载。


I have this alias that I want to point to 60 indexes. At 21 indexes, I start getting Execution Rejected exceptions.

Is this because of a 20 index limit in the alias API?

解决方案

Assuming that you have 5 shards per index, a request against 21 indices may generates about 105 shard requests, 32 of these requests are sent to threads in the pool and 73 request go into the queue. At this moment you have only about 27 elements in the queue left. So, if another request against 6 or more indices (30 shards) arrives, some shardsrequests are going to be rejected with Execution Rejected Exception. I am oversimplifying the situation here quite a bit and the actual number of threads used depends on many factors including where shards are located, search settings, etc. However, I hope you can see the main idea here: if you want to search against a large number of shards, you need to make sure you have enough capacity in the thread pool to handle the peak load.

这篇关于ElasticSearch别名可以指向的索引数量有限吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆