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

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

Hi [~vagarychen]

Thanks for your comments, they are really helpful.

bq. Maybe throw the exception after the rollback is done?

This makes sense to me. I have added the code to throw an exception to tell the 
caller the delete blocks operation fails. Thanks for pointing this out to avoid 
a hidden bug.

bq. but maybe we should at least log a LOG.error message or something hereā€¦

Makes sense. This code path is handling a corner case, I don't think it will 
happen often. But it is helpful to add an error log with informative message to 
explain this failure. I have added that in latest patch.

bq. This may not be a valid case, but since deleteBlocks does not have 
synchronized

Fixed. Add the lock/unlock code back as they were accidentally removed.

bq. some TODO comments get removed

Fixed. Added required TODO items back. The space related TODOs are still 
required.

bq. is it missing a db.get() call or something?

Good catch, yes get call was missing and I added it back.

Thanks a lot.

> 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: Weiwei Yang
>         Attachments: HDFS-12235-HDFS-7240.001.patch, 
> HDFS-12235-HDFS-7240.002.patch, HDFS-12235-HDFS-7240.003.patch, 
> HDFS-12235-HDFS-7240.004.patch, HDFS-12235-HDFS-7240.005.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: hdfs-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org

Reply via email to