HDFS-15627. Log delete audits before collecting blocks.

This commit is contained in:
Kihwal Lee 2020-10-16 11:13:41 -05:00
parent cc57eebe45
commit 740a2c4635

View File

@ -3321,10 +3321,10 @@ boolean delete(String src, boolean recursive, boolean logRetryCache)
throw e; throw e;
} }
getEditLog().logSync(); getEditLog().logSync();
logAuditEvent(true, operationName, src);
if (toRemovedBlocks != null) { if (toRemovedBlocks != null) {
removeBlocks(toRemovedBlocks); // Incremental deletion of blocks removeBlocks(toRemovedBlocks); // Incremental deletion of blocks
} }
logAuditEvent(true, operationName, src);
return ret; return ret;
} }