Skip to content

Commit da28201

Browse files
committed
Add missing FieldInfo null check
1 parent b325699 commit da28201

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

server/src/main/java/org/elasticsearch/cluster/metadata/DataStream.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public static boolean isFailureStoreFeatureFlagEnabled() {
8888
public static final Comparator<LeafReader> TIMESERIES_LEAF_READERS_SORTER = Comparator.comparingLong((LeafReader r) -> {
8989
try {
9090
FieldInfo info = r.getFieldInfos().fieldInfo(TIMESTAMP_FIELD_NAME);
91-
if (info.docValuesSkipIndexType() == DocValuesSkipIndexType.RANGE) {
91+
if (info != null && info.docValuesSkipIndexType() == DocValuesSkipIndexType.RANGE) {
9292
DocValuesSkipper skipper = r.getDocValuesSkipper(TIMESTAMP_FIELD_NAME);
9393
return skipper.maxValue();
9494
}

0 commit comments

Comments
 (0)