File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
server/src/main/java/org/elasticsearch/snapshots Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change
1
+ pr : 111524
2
+ summary : Fix `NullPointerException` in shard snapshot code
3
+ area : Snapshot/Restore
4
+ type : bug
5
+ issues : []
Original file line number Diff line number Diff line change @@ -360,7 +360,7 @@ private void snapshot(
360
360
ActionListener <ShardSnapshotResult > listener
361
361
) {
362
362
try {
363
- final IndexShard indexShard = indicesService .indexServiceSafe (shardId .getIndex ()).getShardOrNull (shardId .id ());
363
+ final IndexShard indexShard = indicesService .indexServiceSafe (shardId .getIndex ()).getShard (shardId .id ());
364
364
if (indexShard .routingEntry ().primary () == false ) {
365
365
throw new IndexShardSnapshotFailedException (shardId , "snapshot should be performed only on primary" );
366
366
}
You can’t perform that action at this time.
0 commit comments