[
https://issues.apache.org/jira/browse/HDFS-8195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Zhe Zhang updated HDFS-8195:
----------------------------
Affects Version/s: HDFS-7285
Status: Patch Available (was: Open)
Thanks for working on this Fukudome-san! The overall logic looks good to me.
Attaching v2 patch which is a minor rebase to make it compile. Also triggering
Jenkins.
{code}
+ final long actualBlockGroupSize =
+ (commitBlock.getNumBytes() / ecSchema.getNumDataUnits()) * numBlocks;
{code}
We should use the {{BlockInfoStriped#spaceConsumed}} logic from HDFS-7949.
> Erasure coding: Fix file quota change when we complete/commit the striped
> blocks
> --------------------------------------------------------------------------------
>
> Key: HDFS-8195
> URL: https://issues.apache.org/jira/browse/HDFS-8195
> Project: Hadoop HDFS
> Issue Type: Sub-task
> Affects Versions: HDFS-7285
> Reporter: Takuya Fukudome
> Assignee: Takuya Fukudome
> Attachments: HDFS-8195-HDFS-7285.2.patch, HDFS-8195.1.patch
>
>
> Fix file quota change when converting a file with striped blocks from
> complete/under-construction to under-construction/complete state. When we add
> a new block (FSDirectory#addBlock) we update the quota using the full block
> size (since we do not know how much data the user will write to
> the new block), and when we complete/commit the block, the quota is updated
> based on the block's real size (FSNamesystem#commitOrCompleteLastBlock).
> Currently these two places only support contiguous blocks (using
> INodeFile#getPreferredBlockSize as the full block size). We should update
> them for striped blocks.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)