[
https://issues.apache.org/jira/browse/SOLR-7530?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16839242#comment-16839242
]
Munendra S N commented on SOLR-7530:
------------------------------------
[~mkhludnev]
{quote}f we consider array format. I wouldn't say ttf makes it more ugly. eg {{
"FileType": [ "EMAIL",20060,..]}} is equally odd/ugly/reasonable than
{{"FileType": [ "EMAIL", {"df":8,"ttf":1}
, "TEXT",
{"df":7,"ttf":2}{quote}
So, Fieldtype response would be an array and when terms.ttf=true then, values
would be object
{code:java}
{
"type_s": [
"review",
{
"df": 8,
"ttf": 0
},
"book",
{
"df": 4,
"ttf": 0
},
"comment",
{
"df": 4,
"ttf": 0
}
],
"id": [
"book4",
{
"df": 1,
"ttf": 0
},
"book4_c1",
{
"df": 1,
"ttf": 0
},
"book4_c2",
{
"df": 1,
"ttf": 0
},
"book4_c3",
{
"df": 1,
"ttf": 0
},
"book5",
{
"df": 1,
"ttf": 0
},
"book5_c1",
{
"df": 1,
"ttf": 0
},
"book5_c2",
{
"df": 1,
"ttf": 0
},
"book5_c3",
{
"df": 1,
"ttf": 0
},
"book6",
{
"df": 1,
"ttf": 0
},
"book6_c1",
{
"df": 1,
"ttf": 0
}
]
}
{code}
and when terms.ttf=false, then response would be
{code:java}
{
"type_s": [
"review",
8,
"book",
4,
"comment",
4
],
"id": [
"book4",
1,
"book4_c1",
1,
"book4_c2",
1,
"book4_c3",
1,
"book5",
1
]
}
{code}
Is my understanding correct??
Once you confirm and SOLR-13333 is resolved(just trying to avoid rebasing), I
will pick this up. Hope, that is okay
> Wrong JSON response using Terms Component with distrib=true
> -----------------------------------------------------------
>
> Key: SOLR-7530
> URL: https://issues.apache.org/jira/browse/SOLR-7530
> Project: Solr
> Issue Type: Bug
> Components: Response Writers, SearchComponents - other, SolrCloud
> Affects Versions: 4.9
> Reporter: Raúl Grande
> Assignee: Mikhail Khludnev
> Priority: Major
> Fix For: master (9.0)
>
>
> When using TermsComponent in SolrCloud there are differences in the JSON
> response if parameter distrib is true or false. If distrib=true JSON is not
> well formed (please note at the [ ] marks)
> JSON Response when distrib=false. Correct response:
> {"responseHeader":{
> "status":0,
> "QTime":3
> },
> "terms":{
> "FileType":
> [
> "EMAIL",20060,
> "PDF",7051,
> "IMAGE",5108,
> "OFFICE",4912,
> "TXT",4405,
> "OFFICE_EXCEL",4122,
> "OFFICE_WORD",2468
> ]
> } }
> JSON Response when distrib=true. Incorrect response:
> {
> "responseHeader":{
> "status":0,
> "QTime":94
> },
> "terms":{
> "FileType":{
> "EMAIL":31923,
> "PDF":11545,
> "IMAGE":9807,
> "OFFICE_EXCEL":8195,
> "OFFICE":5147,
> "OFFICE_WORD":4820,
> "TIFF":1156,
> "XML":851,
> "HTML":821,
> "RTF":303
> }
> } }
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]