[ https://issues.apache.org/jira/browse/HDFS-15505?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17632720#comment-17632720 ]
Xing Lin commented on HDFS-15505: --------------------------------- There is no update from [~hangc] on the PR. I am not sure whether he still plans to fix/finish his PR. [~jianghuazhu], do you have bandwidth to pick this up? > Fix NullPointerException when call getAdditionalDatanode method with null > extendedBlock parameter > ------------------------------------------------------------------------------------------------- > > Key: HDFS-15505 > URL: https://issues.apache.org/jira/browse/HDFS-15505 > Project: Hadoop HDFS > Issue Type: Bug > Components: dfsclient > Affects Versions: 3.0.0, 3.1.0, 3.0.1, 3.0.2, 3.2.0, 3.1.1, 3.0.3, 3.1.2, > 3.3.0, 3.2.1, 3.1.3 > Reporter: hang chen > Priority: Major > > When client call getAdditionalDatanode method, it will initialize > GetAdditionalDatanodeRequestProto and send RPC request to Router/namenode. > However, if we call getAdditionalDatanode method with null extendedBlock > parameter, it will set GetAdditionalDatanodeRequestProto's blk field with > null, which will cause NullPointerException. The code show as follow. > {code:java} > // code placeholder > GetAdditionalDatanodeRequestProto req = GetAdditionalDatanodeRequestProto > .newBuilder() > .setSrc(src) > .setFileId(fileId) > .setBlk(PBHelperClient.convert(blk)) > .addAllExistings(PBHelperClient.convert(existings)) > .addAllExistingStorageUuids(Arrays.asList(existingStorageIDs)) > .addAllExcludes(PBHelperClient.convert(excludes)) > .setNumAdditionalNodes(numAdditionalNodes) > .setClientName(clientName) > .build();{code} > -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org