spark-solr icon indicating copy to clipboard operation
spark-solr copied to clipboard

Support for basic authentication (collection control)

Open pigeon-geng opened this issue 5 years ago • 2 comments

@kiranchitturi I see the #118 . Why not like this

val options = Map(
  "collection" -> "{solr_collection_name}",
  "zkhost" -> "{zk_connect_string}",
  "httpBasicAuthUser" -> "{httpBasicAuthUser}",
  "httpBasicAuthPassword" -> "{httpBasicAuthPassword}",
)
val df = spark.read.format("solr")
  .options(options)
  .load

This seems to be more friendly to multi-permission support. It can be controlled by spark options.

pigeon-geng avatar Sep 29 '19 06:09 pigeon-geng

We didn't add this due to the auth being exposed but if the opts are controlled via external variable, then this does make sense. Patches are welcome

kiranchitturi avatar Mar 15 '20 05:03 kiranchitturi

I was looking for this feature as well. I use the solr-operator in k8s and have a lot of solr instances and right now I have to have a Spark cluster designated for each instance of solr. I'd like to be able to switch on the fly. The patch implemented looked good to me.

washcycle avatar Mar 24 '22 18:03 washcycle