sadanand48 commented on code in PR #9129:
URL: https://github.com/apache/ozone/pull/9129#discussion_r2453944259
##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/snapshot/SnapshotCache.java:
##########
@@ -351,6 +351,8 @@ private synchronized void cleanup(boolean force) {
LOG.debug("Closing SnapshotId {}. It is not being referenced
anymore.", k);
// Close the instance, which also closes its DB handle.
try {
+ // we need to explicitly flush here, close does not explicitly
do a flush
+ v.get().getMetadataManager().getStore().flushDB();
Review Comment:
> Can you add some test for this?
The test testContentsOfTarballWithSnapshot fails due to this missing fix and
I've been trying to clarify this point throughout the PR.
If WAL is present in the DB we are good but to be on safer side should we
flush it to an "sst" file ? The flush call here explicitly flushes the
remaining content in memtable to an "sst" file. Without this flush we are
going to have updates in the .log file (WAL) which is copied too.
I will remove it and modify testcase not to deleteWAL. I hope my point is
clear
--
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]