elasticsearch - Elasticsearch 仅主节点工作
问题描述
我正在尝试Index A
从 python(aggs 查询)代码到 ES 服务器执行一些查询。
我的配置:
Index A
分片node-superman-1
->node-superman-4
node-superman-1
->node-superman-4
是数据和主节点。
node.master: true
node.data: true
node.ingest: true
node-superman-client-41
只是一个节点,我试图调用这个节点。
node.master: false
node.data: false
node.ingest: false
但只能node-superman-3
工作(我试图运行多线程,必须等待以后的线程)。
Python代码:
我曾经elasticsearch
连接到node-superman-client-41
使用搜索功能elasticsearch.search
:
data = elasticsearch.search(index='Index_A', body=query,
request_timeout=120)
query
就像普通查询一样{ query: { ... }, aggs: { ... } }
我创建了多连接并在多线程中使用:
所以为什么?如何共享另一个节点(1、2、4)?
谢谢!
解决方案
推荐阅读
- bash - .gitignore 默认情况下将全部黑名单和手动白名单模式不起作用
- git - git-lfs:如何强制安装 git lfs?
- visual-studio - UWP 商店应用程序过期证书未由“将应用程序与商店关联”更新
- shell - 如果其他条件匹配语句在 jenkinsfile 的外壳中不起作用
- c - “__schedule”函数中的“current”和“prev”有什么区别,为什么不直接使用current呢?
- node.js - 如何在 .ejs 模板中显示错误
- php - 为什么 Jetstream 无法在我的 PC 上的 laravel 8 上安装
- javascript - 尝试使用 rpc.query 将数据从 javascript 发送到 python POS odoo
- firebase - 如何使用 ListView.builder 获取某个集合的特定 Firestore 文档
- python-3.x - 简单代码中的 type() 函数 SyntaxError