[ 
https://issues.apache.org/jira/browse/HDFS-12235?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16144856#comment-16144856
 ] 

Weiwei Yang commented on HDFS-12235:
------------------------------------

Hi [~yuanbo]

Please see my comments below

*BackgroundService.java*

This change seems only useful for debug, please remove them.

*BlockManagerImpl.java*

# Please add isOutOfNodeChillMode check back.
# Lock code is missing.
# line 488: add more java doc, introduce how this API is used. We want to have 
multiple blocks to be atomically deleted if they are from same object key.
# line 505 - 511 move to ContainerUtils for reuse, suggest to use name 
addOrUpdate(...)

*DeletedBlockLogImpl.java*

# line 213 - rename method to constructNewTransaction as this always sets count 
to 0.
# line 315: can we move 315 line to after 317? So we can get consistent txid.

*FileUtils.java*

# Please move changes to TestOzoneHelper, we want to constrain changes in side 
of ozone package as much as possible.
# Use {{RandomStringutils}}, it provides some utility methods to get random 
strings.

*KeyManagerImpl.java*

# Can we reuse properties {{ozone.block.deleting.service.timeout}}, 
{{ozone.block.deleting.service.interval.ms}}? Though KSM, SCM and DN both have 
their back ground services, but they all serve for block deleting.

*ScmBlockLocationProtocol.java*

Please revise following API from

{code}
List<DeleteBlocksResult> deleteBlocks(Map<String, List<String>> keyBlocks)
      throws IOException;
{code}

to

{code}
List<DeleteBlocksResult> deleteBlocks(Set<String> blockKeys)
      throws IOException;
{code}

from SCM layer, we only need to know block keys, there will be a bunch of more 
changes based on this change. Look forward to your v3 patch.

Thanks


> Ozone: DeleteKey-3: KSM SCM block deletion message and ACK interactions
> -----------------------------------------------------------------------
>
>                 Key: HDFS-12235
>                 URL: https://issues.apache.org/jira/browse/HDFS-12235
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: ozone
>    Affects Versions: HDFS-7240
>            Reporter: Weiwei Yang
>            Assignee: Yuanbo Liu
>         Attachments: HDFS-12235-HDFS-7240.001.patch, 
> HDFS-12235-HDFS-7240.002.patch
>
>
> KSM and SCM interaction for delete key operation, both KSM and SCM stores key 
> state info in a backlog, KSM needs to scan this log and send block-deletion 
> command to SCM, once SCM is fully aware of the message, KSM removes the key 
> completely from namespace. See more from the design doc under HDFS-11922, 
> this is task break down 2.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to