hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kan Zhang (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HDFS-592) Allow client to get a new generation stamp from NameNode
Date Wed, 16 Sep 2009 19:13:57 GMT

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

Kan Zhang commented on HDFS-592:

Thanks for adding a test case for clientName==NULL.

+1 for the patch. Some nits.

- you don't have to test for clientName==NULL in the following. If it is NULL, the "+" operator
will append NULL. 
+      throw new LeaseExpiredException("Lease mismatch: " + block + " owned by "
+          + pendingFile.getClientName() + " but is accessed by " + 
+          (clientName==null?"null":clientName));
There is also a subtle security/privacy concern there. That is whether we want to tell the
client who actually owns the pendingFile in the error msg. Is there any inconveniences if
we don't tell?

- I'd use !clientName.equals(pendingFile.getClientName()) since you know clientName won't
be NULL at this point.
+    if (clientName == null || !pendingFile.getClientName().equals(clientName)) {

> Allow client to get a new generation stamp from NameNode
> --------------------------------------------------------
>                 Key: HDFS-592
>                 URL: https://issues.apache.org/jira/browse/HDFS-592
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: name-node
>    Affects Versions: Append Branch
>            Reporter: Hairong Kuang
>            Assignee: Hairong Kuang
>             Fix For: Append Branch
>         Attachments: newGS.patch, newGS1.patch, newGS2.patch, newGS3.patch
> This issue aims to  add an API to ClientProtocol that fetches a new generation stamp
and an access token from NameNode to support append or pipeline recovery.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message