mirror of https://github.com/apache/lucene.git
SOLR-9074: solrj CloudSolrClient.directUpdate tweak
Defer two NamedList allocations and initialCapacity one of them.
This commit is contained in:
parent
d95a91a9cc
commit
49b3eee4c8
|
@ -618,14 +618,14 @@ public class CloudSolrClient extends SolrClient {
|
|||
return null;
|
||||
}
|
||||
|
||||
NamedList<Throwable> exceptions = new NamedList<>();
|
||||
NamedList<NamedList> shardResponses = new NamedList<>();
|
||||
|
||||
Map<String, LBHttpSolrClient.Req> routes = updateRequest.getRoutes(router, col, urlMap, routableParams, this.idField);
|
||||
if (routes == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
final NamedList<Throwable> exceptions = new NamedList<>();
|
||||
final NamedList<NamedList> shardResponses = new NamedList<>(routes.size()+1); // +1 for deleteQuery
|
||||
|
||||
long start = System.nanoTime();
|
||||
|
||||
if (parallelUpdates) {
|
||||
|
|
Loading…
Reference in New Issue