Skip to content

Commit b0cd954

Browse files
committed
No need to check the stale ids
1 parent b29f850 commit b0cd954

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

server/src/main/java/org/elasticsearch/cluster/routing/allocation/IndexMetaDataUpdater.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -239,11 +239,7 @@ public static ClusterState removeStaleIdsWithoutRoutings(ClusterState clusterSta
239239
}
240240
indexMetaDataBuilder.putInSyncAllocationIds(shardNumber, remainingInSyncAllocations);
241241
}
242-
// Only log the stale shards which have been actually removed.
243-
if (oldInSyncAllocations.size() != remainingInSyncAllocations.size()) {
244-
logger.warn("{} remove stale shards [{}] without routing", shardEntry.getKey(),
245-
Sets.difference(oldInSyncAllocations, remainingInSyncAllocations));
246-
}
242+
logger.warn("{} marking unavailable shards as stale: {}", shardEntry.getKey(), idsToRemove);
247243
}
248244

249245
if (indexMetaDataBuilder != null) {

0 commit comments

Comments
 (0)