[
https://issues.apache.org/jira/browse/HDFS-11695?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16003150#comment-16003150
]
Rakesh R commented on HDFS-11695:
---------------------------------
Thanks [~surendrasingh] for the good work. Adding few comments on the patch,
# Please add {{assert fsn.hasWriteLock();}} in
FSDirSatisfyStoragePolicyOp#satisfyStoragePolicy()
# Can we move the following code into
{{FSDirSatisfyStoragePolicyOp.unprotectedRemoveSPSXAttr}} and rename this
method to just {{FSDirSatisfyStoragePolicyOp#removeSPSXAttr}}
{code}
try {
this.writeLock();
FSDirSatisfyStoragePolicyOp.unprotectedRemoveSPSXAttr(inode, spsXAttr);
List<XAttr> xAttrs = Lists.newArrayListWithCapacity(1);
xAttrs.add(spsXAttr);
getEditLog().logRemoveXAttrs(inode.getFullPathName(), xAttrs, false);
} finally {
this.writeUnlock();
}
{code}
# Add {{@Test(timeout}}
# Add brief doc for test
{{testNameNodeRestartWhenSPSCalledOnChildFileAndParentDir}},
{{testSPSOnChildAndParentDirectory}} describing the steps.
# Also, please take care style warnings.
> [SPS]: Namenode failed to start while loading SPS xAttrs from the edits log.
> ----------------------------------------------------------------------------
>
> Key: HDFS-11695
> URL: https://issues.apache.org/jira/browse/HDFS-11695
> Project: Hadoop HDFS
> Issue Type: Sub-task
> Components: namenode
> Affects Versions: HDFS-10285
> Reporter: Surendra Singh Lilhore
> Assignee: Surendra Singh Lilhore
> Priority: Blocker
> Attachments: fsimage.xml, HDFS-11695-HDFS-10285.001.patch,
> HDFS-11695-HDFS-10285.002.patch
>
>
> {noformat}
> 2017-04-23 13:27:51,971 ERROR
> org.apache.hadoop.hdfs.server.namenode.NameNode: Failed to start namenode.
> java.io.IOException: Cannot request to call satisfy storage policy on path
> /ssl, as this file/dir was already called for satisfying storage policy.
> at
> org.apache.hadoop.hdfs.server.namenode.FSDirAttrOp.unprotectedSatisfyStoragePolicy(FSDirAttrOp.java:511)
> at
> org.apache.hadoop.hdfs.server.namenode.FSDirXAttrOp.unprotectedSetXAttrs(FSDirXAttrOp.java:284)
> at
> org.apache.hadoop.hdfs.server.namenode.FSEditLogLoader.applyEditLogOp(FSEditLogLoader.java:918)
> at
> org.apache.hadoop.hdfs.server.namenode.FSEditLogLoader.loadEditRecords(FSEditLogLoader.java:241)
> at
> org.apache.hadoop.hdfs.server.namenode.FSEditLogLoader.loadFSEdits(FSEditLogLoader.java:150)
> {noformat}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]