lucidworks / spark-solr

Tools for reading data from Solr as a Spark RDD and indexing objects from Spark into Solr using SolrJ.
Apache License 2.0
446 stars 251 forks source link

How to send request vis POST method. #308

Open alisheykhi opened 3 years ago

alisheykhi commented 3 years ago

I have a Facet with long quey. ّI got an error (URI too long) when I run this query inside spark executors. as I searched, Solrj sends requests via the GET method. I'm wondering who can I change the request method to POST in the solr option Map?

new QueryRequest(solrParams, SolrRequest.METHOD.POST);

I'm looking for something like this:

val option = Map( "zkhost" -> zkhost, "collection" -> collection, "expr" -> facetExpr, "method" -> POST )