mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-25 22:36:20 +00:00
Core: Use the provided cluster state instead of fetching a new cluster state from cluster service.
Close #7013
This commit is contained in:
parent
5483c62de6
commit
297a97cd23
@ -170,7 +170,7 @@ public class TransportUpdateAction extends TransportInstanceSingleOperationActio
|
||||
return clusterState.routingTable().index(request.index()).shard(request.shardId()).primaryShardIt();
|
||||
}
|
||||
ShardIterator shardIterator = clusterService.operationRouting()
|
||||
.indexShards(clusterService.state(), request.index(), request.type(), request.id(), request.routing());
|
||||
.indexShards(clusterState, request.index(), request.type(), request.id(), request.routing());
|
||||
ShardRouting shard;
|
||||
while ((shard = shardIterator.nextOrNull()) != null) {
|
||||
if (shard.primary()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user