On 11/1/2017 4:22 PM, Phil Scadden wrote:
Except that I am using solrj in an intermediary proxy and passing the response 
directly to a javascript client. It is expect json or csv depending on what it 
passes in wt=

That's a different use case than I had imagined.  Thanks for the detail.

My statement about SolrJ is correct if the code that will handle the response is Java. Sounds like it's not -- you've just said that the code that will actually decode and use the response is javascript.

When the code that will handle the response is Java, SolrJ is a perfect fit, because SolrJ will handle decoding the response and the programmer doesn't need to worry about the format, they are given an object that contains the full response, where information can easily be extracted by someone familiar with typical Java objects.

There probably is a way to access the full response "text" with SolrJ, rather than the decoded object, but I do not know enough about the low-level details to tell you how that might be accomplished. If you can figure that part out, then you could use SolrJ and have access to its methods for constructing the query.

With your Java code simply acting as a proxy, the way you're going about it might be the best option -- build the http request with a particular wt parameter, get the response, and pass the response on unmodified.

Thanks,
Shawn

Reply via email to