You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Chris Hostetter <ho...@fucit.org> on 2011/11/02 00:19:31 UTC
Re: Newbie question
: If using CommonsHttpSolrServer query() method with parameter wt=json, when
: retrieving QueryResponse, how to do to get JSON result output stream ?
when you are using the CommonsHttpSolrServer level of API, the client
takes care of parsing the response (which is typically in an efficient
binary representation) into the basic data structures.
if you just want the raw response (in json or xml, or whatever) as a java
String, then it may not be the API you really want: just use a basic
HttpClient.
Alternately: you could consider writing your own subclass of
ResponseParser that just slurps the InputStream that CommonsHttpSolrServer
fetches for you.
-Hoss