jdyer1 commented on code in PR #2259: URL: https://github.com/apache/solr/pull/2259#discussion_r1511219624
########## solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpSolrJdkClient.java: ########## @@ -287,6 +278,64 @@ private HttpResponse<InputStream> doPutOrPost( return response; } + private volatile boolean headRequested; + private volatile boolean headSucceeded; Review Comment: I think these booleans need to go away anyhow. My reasoning here is we cannot guarantee the client will behave the same every time with this 1-shot try with a HEAD request. What if there is a network issue? Then that client instance is stuck on Http/1.1 for its lifetime for these requests. I think it is probably best to issue the HEAD request every time, to guarantee consistency. This only affects POST requests with a chunked body (updates, not queries). It only will be needed if not TLS, and if the user does not force Http/1.1. I do not think it adds anymore overhead than if it always issued an upgrade request with no body (as the Eclipse maintainers seem to think it ought to.) We can put a note about this in the Javadoc and if none of these options are workable for any user, they always have `Http2SolrClient` to fall back on. Progress, not Perfection, eh? -- 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