【发布时间】:2018-01-16 01:20:50
【问题描述】:
我正在尝试通过将 JSON 格式的查询发布到 /query 请求处理程序来使用 Solr 的 result grouping(例如,通过 Solr 管理 UI 中的 Documents 选项卡;使用设置请求处理程序到 /query)
查询很简单:
{
"query":"Description:keyword",
"offset":0,
"limit":20
}
我找到的所有示例都使用 HTTP GET,例如:
http://localhost:8983/solr/techproducts/select?wt=json&indent=true&fl=id,name&q=solr+memory&group=true&group.field=manu_exact
当我尝试添加 JSON 字段 group、groups、grouping 或其他内容时,错误消息始终相同:
Unknown top-level key in JSON request : group...
我知道这里提供的方法:POST json request to Solr with cursorMark in request(发布 url 编码数据而不是 JSON)。但是,我想避免这种情况。有什么想法可以做到吗?
【问题讨论】: