[ 
https://issues.apache.org/jira/browse/SOLR-1123?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12789998#action_12789998
 ] 

Noble Paul commented on SOLR-1123:
----------------------------------

bq. I always had the impression that the main idea behind the response writers 
is that all they need to know is how to marshal a NamedList ...

That is the problem. the NamedList is a weird datastructure for those who are 
not so used to Solr. You don't know what is included in that unless you do an 
instanceof. Most of the users are happy to write out the documents . 
understanding a SolrDocument is far easier than figuring outhow to handle a 
DocList .So it is an attempt to cater to those needs .  

If you know how to handle the NamedList beast then you can do that also ( but 
only if you wish to). 

> Change the JSONResponseWriter content type
> ------------------------------------------
>
>                 Key: SOLR-1123
>                 URL: https://issues.apache.org/jira/browse/SOLR-1123
>             Project: Solr
>          Issue Type: Improvement
>            Reporter: Uri Boness
>             Fix For: 1.5
>
>         Attachments: JSON_contentType_incl_tests.patch
>
>
> Currently the jSON content type is not used. Instead the palin/text content 
> type is used. The reason for this as I understand is to enable viewing the 
> json response as as text in the browser. While this is valid argument, I do 
> believe that there should at least be an option to configure this writer to 
> use the JSON content type. According to 
> [RFC4627|http://www.ietf.org/rfc/rfc4627.txt] the json content type needs to 
> be application/json (and not text/x-json). The reason this can be very 
> helpful is that today you have plugins for browsers (e.g. 
> [JSONView|http://brh.numbera.com/software/jsonview]) that can render any page 
> with application/json content type in a user friendly manner (just like xml 
> is supported).

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to