solr
solr copied to clipboard
SOLR-17792: Fix deadlocks in ParallelHttpShardHandler
https://issues.apache.org/jira/browse/SOLR-17792
This is a WIP but we really should be able to get rid of the synchronization and make this logic so much simpler.
Here I'm making responseFutureMap a ConcurrentMap, so it doesn't need to be synchronized. Synchronization blocks also won't be necessary because we won't be using pending anymore. We will consider ourselves pending if responseFutureMap or responses is not empty. (previously pending was increased if either something was added to responseFutureMap, or a no-shard-response was added to responses).
This is a blocker for 9.9, because the ParallelHttpShardHandler is unusable without fixing this.