When i added elastic search in my project and test it on the first day it was way too fast.Next day it become too slow.I dont know what is heppening. See Code Bellow.
-
Kibana :Took 264
GET /products/_search
{
"query": { "match_all": {}},
"size":10000
}
There are 106000 records...
2).net
var response = _client.Search(s => s
.Index("products")
.Size(10)
.Query(q => q
.MultiMatch(m => m
.Fields(fields => fields
.Field(
p => p.ManufacturerPartNumber
)
.Field(
p => p.Name,5
)
.Field(
p => p.FullDescription
)
.Field(
p => p.ShortDescription
)
.Field(
p => p.Sku
))
.Query(term)
.Type(TextQueryType.BestFields))));var productIds = (from hits in response.Hits select hits.Source.Id).ToArray(); var models = _productModelFactory.PrepareElasticProductOverviewModels(productIds, false, true, _mediaSettings.AutoCompleteSearchThumbPictureSize).ToList();