Hi all, In my team we're migrating to Cloudera hosted Solr version 7.4.0 to 8.11.2. For the interim period we would like to have two instances of CloudSolrClient in our app, one pointing to the v7.4.0 cluster and the other pointing to the 8.11.2.
Our app is a SpringBoot one and we use the SolrJ client. The current config that produces a single instance of CloudSolrClient looks somewhat like this @Bean public SolrClient getCloudSolrClient() { System.setProperty("zookeeper.sasl.client", "false"); SolrHttpClientBuilder solrClientBuilder = new Krb5HttpClientBuilder().getBuilder(); HttpClientUtil.setHttpClientBuilder(solrClientBuilder); CloudSolrClient client = new CloudSolrClient.Builderr(asList(properties.getZkHosts().split(",")), Optional.empty()) .withConnectionTimeout((int)properties.getConnectionTimeout().toMillis()) .withSocketTimeout((int) properties.getTimeout().toMillis()) .build() return client; } We figured that for two client instances authenticating with cluster members using Kerberos we would obviously need jaas.conf with two realms and all that, but after exploring the SolrJ client code a bit we fear that because the JaasConfig is static we fear that we may run into multi threaded related issues like race conditions etc. Has anyone here faced a similar requirement and perhaps arrived at an acceptable and working solution? Any hints and pointers will be greatly appreciated! Chris