看,灰机...

聚合搜索 size: Integer.MAX_VALUE 报错 elasticsearch 7.1.1

匿名 | 发布于2021年07月26日 | 阅读数:893

聚合terms搜索时候想显示结果的所有字段,设置size: Integer.MAX_VALUE时候报错 elasticsearch 7.1.1

{
"size": 2147483647,
"aggs":
{
    "eventSid":{
        "terms":{
            "field":"eventSid.keyword",                       
},
        "aggs": {
          "accountId": {
            "terms": {
      "field":"accountId",                     
},
"aggs": {
"hit_result": {
"top_hits": {
"size": 20,         
"sort": {
                "eventStartTime": {
                  "order": "desc"  
  }
}
}
}
}
}
}
}
}
}

已邀请:

tongchuan1992 - 学无止境、学以致用

赞同来自:

您好,你的mappin可以发下看看嘛,是不是没有设置成2147483647这么大。

要回复问题请先登录注册