悟空,拿我的打狗棒来

query_string 两个特定关键词,诡异的返回10s以上问题?

Elasticsearch | 作者 laoyang360 | 发布于2017年09月14日 | 阅读数:3229


ES配置:3节点docker集群,24核处理器、共享132GB内存。
待检索document行数:178537行。
数据量:11.3GB

检索方式:
POST windex/wtype/_search
{
"from" : 0,
"size" : 10,
"query" : {
"query_string" : {
"query" : "列表 返回",
"fields" : [ ],
"use_dis_max" : true,
"tie_breaker" : 0.0,
"default_operator" : "or",
"auto_generate_phrase_queries" : false,
"max_determinized_states" : 10000,
"enable_position_increments" : true,
"fuzziness" : "AUTO",
"fuzzy_prefix_length" : 0,
"fuzzy_max_expansions" : 50,
"phrase_slop" : 0,
"escape" : false,
"split_on_whitespace" : true,
"boost" : 1.0
}
},
"highlight" : {
"pre_tags" : [
"<span style=\"color:red\">"
],
"post_tags" : [
"</span>"
],
"fragment_size" : 100,
"number_of_fragments" : 5,
"require_field_match" : false,
"fields" : {
"*" : { },
"title" : { },
"content" : { }
}
}
}

单独检索“列表”或者“返回”,耗时:0.1——0.2s左右;
检索“列表 返回 处理” 3个关键词 或者 “列表 返回 处理 可以” 四个关键词,耗时:1.4s—2s之间。

但是,检索“列表 返回”两个关键词,耗时达到10s左右?(注意其他任意两组关键词都能确保2s能内返回结果)。

很诡异的问题?想看看大家的排查思路。一起讨论下。
已邀请:

rockybean - Elastic Certified Engineer, ElasticStack Fans,公众号:ElasticTalk

赞同来自: laoyang360

用 profile api 看下 到底做了什么
https://www.elastic.co/guide/e ... .html

要回复问题请先登录注册