1
我有7M文件我的索引。与NEST客户端,我正在用此代码搜索“*”查询。Elasticsearch NEST搜索查询太慢
var node = new Uri("http://localhost:9200");
var settings = new ConnectionSettings(
node,
defaultIndex: "evaluation"
);
var client = new ElasticClient(settings);
var result = client.Search<FtsResult>(s => s
.From(0)
.Fields(new[] { "id" })
.Indices(indexName)
.Size(Int32.MaxValue)
.Query(q => q
.QueryString(qs => qs.OnFields(new[] { "agentText", "customerText" }).Query("*"))
)
而且结果elapsedtime是59.6秒。 在Kibana中,相同的查询结果经过时间仅为4秒。根据Kibana为什么Nest搜索查询速度太慢?