You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Weiwei Yang (JIRA)" <ji...@apache.org> on 2017/06/01 15:44:04 UTC
[jira] [Commented] (HDFS-11781) Ozone: KSM: Add deleteKey
[ https://issues.apache.org/jira/browse/HDFS-11781?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16033178#comment-16033178 ]
Weiwei Yang commented on HDFS-11781:
------------------------------------
Thanks [~xyao] for the hint and [~yuanbo] for uploading a new patch. V2 patch looks almost good to me. Just some nits
*KeyManager.java*
Minor: can we refactor the annotation from
{code}
/**
* Deletes an existing key. If the key doesn't exist, it
* will throw IOException with NOT_FOUND message.
*
* @param args the args of the key provided by client.
* @throws IOException
*/
{code}
to something like
{code}
Deletes an object by an object key. The key will be immediately removed
from KSM namespace and become invisible to clients. The object data
will be removed in async manner that might retain for some time.
@throws IOException
if specified key doesn't exist or some other I/O errors while deleting an object.
{code}
*KeyManagerImpl.java*
# line 152: The objectKey is a byte array, you can't log it directly in the message
# line 159: Looks like you have omit the return value of {{scmBlockClient.deleteBlocks(keys)}}, even this is (will be) an async operation, it still has chance to fail, we need to handle that. Current patch covers some exceptions up. Please take a look at {{DeleteBlockResult}}.
# line 161: The last element {{ex}} probably cannot print a human readable message in the log
*TestKeySpaceManager.java*
# line 420: Can we remove this line?
# line 414, 415, 416: Can we remove these lines?
# Can we add some test code to make sure the corresponding block is deleted in SCM side?
Thank you.
> Ozone: KSM: Add deleteKey
> -------------------------
>
> Key: HDFS-11781
> URL: https://issues.apache.org/jira/browse/HDFS-11781
> Project: Hadoop HDFS
> Issue Type: Sub-task
> Components: ozone
> Affects Versions: HDFS-7240
> Reporter: Anu Engineer
> Assignee: Yuanbo Liu
> Attachments: HDFS-11781-HDFS-7240.001.patch, HDFS-11781-HDFS-7240.002.patch
>
>
> Add support for removing a key.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-help@hadoop.apache.org