stillalex commented on code in PR #1835: URL: https://github.com/apache/solr/pull/1835#discussion_r1291835016
########## solr/solrj-streaming/src/java/org/apache/solr/client/solrj/io/stream/Facet2DStream.java: ########## @@ -325,13 +322,7 @@ public void open() throws IOException { if (cache != null) { cloudSolrClient = cache.getCloudSolrClient(zkHost); } else { - final List<String> hosts = new ArrayList<>(); - hosts.add(zkHost); - cloudSolrClient = - new CloudLegacySolrClient.Builder(hosts, Optional.empty()) - .withSocketTimeout(30000, TimeUnit.MILLISECONDS) - .withConnectionTimeout(15000, TimeUnit.MILLISECONDS) - .build(); + cloudSolrClient = SolrClientCache.newCloudHttp2SolrClient(zkHost, null); Review Comment: yes I agree with your concern. but I added it to replace all manual builder use from across the streaming module. there is no way to define visibility to module only, so this is what I ended up with. I prefer this single point of entry because it handles the timeout setting correctly, rather than repeating this code all over. the inconsistency was that some of the builders have increased timeouts, some don't, it's hard to understand what goes where in the streaming module. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org