Arrays 如果在文档数组中插入新元素,则重新索引elasticsearch
我是新来的Arrays 如果在文档数组中插入新元素,则重新索引elasticsearch,arrays,
elasticsearch,Arrays,
elasticsearch,我是新来的elasticsearch。我的ES中有以下类型的结构 PUT /my_index/blogpost/1 { "title": "Nest eggs", "body": "Making your money work...", "tags": [ "cash", "shares" ], "comments": [ { "name": "John Smith", "comment": "Great article", "age":
elasticsearch
。我的ES中有以下类型的结构
PUT /my_index/blogpost/1
{
"title": "Nest eggs",
"body": "Making your money work...",
"tags": [ "cash", "shares" ],
"comments": [
{
"name": "John Smith",
"comment": "Great article",
"age": 28,
"stars": 4,
"date": "2014-09-01"
},
{
"name": "Alice White",
"comment": "More like this please",
"age": 31,
"stars": 5,
"date": "2014-10-22"
}
]
}
我发现文档是不可变的:它们不能更改,只能替换。所以我想知道当我从“评论”数组中推拉任何对象时,会发生什么?my_index
是否将重新编制索引或1
文档是否将重新编制索引?您所说的“拉”是什么意思,尤其是从Elasticsearch中拉取数据将涉及如何重新编制索引?您打算如何进行“推送”,是使用update\u by\u query
?你能举个例子吗?最后,正如reindex所暗示的,索引被重新索引,那么“1个文档将被重新索引”是什么意思呢?