Tejaskriya commented on code in PR #8550:
URL: https://github.com/apache/ozone/pull/8550#discussion_r2200067969
##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/replication/ContainerImporter.java:
##########
@@ -116,13 +116,16 @@ public void importContainer(long containerID, Path
tarFilePath,
}
ContainerUtils.verifyContainerFileChecksum(containerData, conf);
containerData.setVolume(targetVolume);
+ // lastDataScanTime should be cleared for an imported container
+ containerData.setDataScanTimestamp(null);
try (InputStream input = Files.newInputStream(tarFilePath)) {
Container container = controller.importContainer(
containerData, input, packer);
- // After container import is successful, increase used space for the
volume
+ // After container import is successful, increase used space for the
volume and schedule an OnDemand scan for it
targetVolume.incrementUsedSpace(container.getContainerData().getBytesUsed());
containerSet.addContainerByOverwriteMissingContainer(container);
+ containerSet.scanContainer(containerID);
Review Comment:
I have created
[HDDS-13423](https://issues.apache.org/jira/browse/HDDS-13423) for adding a way
to pass the reason of triggering scan to OnDemandContainerDataScanner so that
it can be logged.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]