我有弹性搜索的问题。 我只是添加了function_score部分,然后才能正常工作
此请求有什么问题:
{
"index":"appartoo",
"body":{
"from":"0",
"size":"30",
"sort":[
],
"_source":{
"exclude":"user"
},
"query":{
"bool":{ ... }, #This part works well
"function_score":{
"query":{
"bool":{
"must_not":[
{
"term":{
"images.0.contentUrl":"images\/profile.png"
}
},
{
"term":{
"images.0.contentUrl":"images\/no-image.png"
}
}
]
}
},
"boost":"5",
"boost_mode":"multiply"
}
}
}
}
错误是:
parse_exception:无法解析搜索源。预期字段名称 但得到了[START_OBJECT]
我使用ES 2.4