Details
Description
When NN deletes a large directory, it will hold the write lock long time. For improving this, we remove the blocks in a batch way. So that other waiters have a chance to get the lock. But right now, the batch number is a hard-coded value.
static int BLOCK_DELETION_INCREMENT = 1000;
We can make this value configurable, so that we can control the frequency of other waiters to get the lock chance.
Attachments
Attachments
Issue Links
- is related to
-
HDFS-15994 Deletion should sleep some time, when there are too many pending deletion blocks.
- Patch Available