[
https://issues.apache.org/jira/browse/HADOOP-12508?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Chris Nauroth updated HADOOP-12508:
-----------------------------------
Attachment: HADOOP-12508.06.patch
On further review, I see we don't have the right hooks in place to avoid sleep
times in this test completely. Trying to introduce those hooks would be a very
intrusive refactoring.
However, we can still limit our reliance on sleep times and provide a more
predictable test by using {{CountDownLatch}}. I'm attaching patch v06. The
main code is the same, but I've changed the test code to use {{CountDownLatch}}
for coordination between the 2 threads. There is still some sleep time on the
background thread, which is required to make sure we cover the lease
acquisition retry logic during the delete. In addition to making the test more
predictable, this is also faster. The patch v05 test ran in ~65 seconds. The
patch v06 test runs in ~9 seconds.
[~xyao], could we please get your help with a code review on this? I am +1 on
the main code portion of this, but I can't commit this based on my own +1,
because I've touched the test code portion of the patch. Thanks!
> delete fails with exception when lease is held on blob
> ------------------------------------------------------
>
> Key: HADOOP-12508
> URL: https://issues.apache.org/jira/browse/HADOOP-12508
> Project: Hadoop Common
> Issue Type: Bug
> Reporter: Gaurav Kanade
> Assignee: Gaurav Kanade
> Priority: Blocker
> Attachments: HADOOP-12508.01.patch, HADOOP-12508.02.patch,
> HADOOP-12508.03.patch, HADOOP-12508.04.patch, HADOOP-12508.05.patch,
> HADOOP-12508.06.patch
>
>
> The delete function as implemented by AzureNativeFileSystem store attempts
> delete without a lease. In most cases this works but in the case of a
> dangling lease resulting out of say a process killed and leaving a lease
> dangling for a small period a delete attempted during this period simply
> crashes. This fix addresses the situation by re-attempting the delete after a
> lease acqusition in this case
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)