I was working on the POC of accessing the solr via the microservices using spring boot. I am using the Rest template to connect the solr . My query is can we customize the response that solr returns ?.
For Example:
solrUri="http://localhost:8983/solr/microServicesPOC/select?q=:&wt=json"
When we access the above url, the response solr returns has the docuemnts of fields. I need to get the results in the format of my Product pojo.
Snippet:
resEntity = solrConfig.getRestTemplate().exchange(solrUri,HttpMethod.POST,entity , Product.class);
To achieve from the above way of rest template, I need the solr to return response in Product format. Is it possible from SOlr?
I am not using the solrTemplate or the solrJ. I want the customization from the solr side not on the service side .
Tried customizing the searchHandler ,Writing DocTransformer but none of the methods worked .