Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,12 @@ public void markContainerForClose(final long containerId)
public void markContainerUnhealthy(final long containerId)
throws IOException {
Container container = containerSet.getContainer(containerId);
getHandler(container).markContainerUnhealthy(container);
if (container != null) {
getHandler(container).markContainerUnhealthy(container);
} else {
LOG.warn("Container {} not found, may be deleted, skip mark UNHEALTHY",
containerId);
}
}

/**
Expand Down Expand Up @@ -206,7 +211,12 @@ public Iterator<Container<?>> getContainers(HddsVolume volume) {
void updateDataScanTimestamp(long containerId, Instant timestamp)
throws IOException {
Container container = containerSet.getContainer(containerId);
container.updateDataScanTimestamp(timestamp);
if (container != null) {
container.updateDataScanTimestamp(timestamp);
} else {
LOG.warn("Container {} not found, may be deleted, " +
"skip update DataScanTimestamp", containerId);
}
}

}