Gargi-jais11 commented on code in PR #10109:
URL: https://github.com/apache/ozone/pull/10109#discussion_r3240181171
##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/keyvalue/KeyValueHandler.java:
##########
@@ -2293,24 +2306,33 @@ private boolean logBlocksFoundOnDisk(Container
container) throws IOException {
private void deleteInternal(Container container, boolean force)
throws StorageContainerException {
+ final long containerId = container.getContainerData().getContainerID();
long startTime = clock.millis();
- container.writeLock();
+ Container<?> containerLocked =
containerSet.acquireContainerLock(containerId);
+ if (containerLocked == null) {
+ // null means container locking retries exhausted ;
+ // container not-found throws StorageContainerException.
+ LOG.info("Exceeded {} retries to lock container {}; Now DN will resend
for delete with " +
Review Comment:
Yes
--
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]