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 "Eli Collins (JIRA)" <ji...@apache.org> on 2010/11/14 06:07:13 UTC
[jira] Created: (HDFS-1498) FSDirectory#unprotectedConcat calls
setModificationTime on a file
FSDirectory#unprotectedConcat calls setModificationTime on a file
-----------------------------------------------------------------
Key: HDFS-1498
URL: https://issues.apache.org/jira/browse/HDFS-1498
Project: Hadoop HDFS
Issue Type: Bug
Components: name-node
Reporter: Eli Collins
Assignee: Eli Collins
Priority: Minor
Fix For: 0.22.0
The HDFSConcat test fails when asserts are enabled because FSDirectory#unprotectedConcat calls INode#setModificationTime on a file, this method asserts that the argument is a directory. It should use setModificationTimeForce since we know the target is a file, it's mod time should be set to now unconditionally since we know we're modifying it. The behavior should be equivalent.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HDFS-1498) FSDirectory#unprotectedConcat calls
setModificationTime on a file
Posted by "Eli Collins (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HDFS-1498?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Eli Collins updated HDFS-1498:
------------------------------
Affects Version/s: 0.22.0
Status: Patch Available (was: Open)
> FSDirectory#unprotectedConcat calls setModificationTime on a file
> -----------------------------------------------------------------
>
> Key: HDFS-1498
> URL: https://issues.apache.org/jira/browse/HDFS-1498
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: name-node
> Affects Versions: 0.22.0
> Reporter: Eli Collins
> Assignee: Eli Collins
> Priority: Minor
> Fix For: 0.22.0
>
> Attachments: hdfs-1498-1.patch
>
>
> The HDFSConcat test fails when asserts are enabled because FSDirectory#unprotectedConcat calls INode#setModificationTime on a file, this method asserts that the argument is a directory. It should use setModificationTimeForce since we know the target is a file, it's mod time should be set to now unconditionally since we know we're modifying it. The behavior should be equivalent.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HDFS-1498) FSDirectory#unprotectedConcat calls
setModificationTime on a file
Posted by "Eli Collins (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HDFS-1498?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Eli Collins updated HDFS-1498:
------------------------------
Resolution: Fixed
Hadoop Flags: [Reviewed]
Status: Resolved (was: Patch Available)
Thanks Cos. I've committed this.
> FSDirectory#unprotectedConcat calls setModificationTime on a file
> -----------------------------------------------------------------
>
> Key: HDFS-1498
> URL: https://issues.apache.org/jira/browse/HDFS-1498
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: name-node
> Affects Versions: 0.22.0
> Reporter: Eli Collins
> Assignee: Eli Collins
> Priority: Minor
> Fix For: 0.22.0
>
> Attachments: hdfs-1498-1.patch
>
>
> The HDFSConcat test fails when asserts are enabled because FSDirectory#unprotectedConcat calls INode#setModificationTime on a file, this method asserts that the argument is a directory. It should use setModificationTimeForce since we know the target is a file, it's mod time should be set to now unconditionally since we know we're modifying it. The behavior should be equivalent.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (HDFS-1498) FSDirectory#unprotectedConcat calls
setModificationTime on a file
Posted by "Eli Collins (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HDFS-1498?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Eli Collins updated HDFS-1498:
------------------------------
Attachment: hdfs-1498-1.patch
Patched attached. One-liner. TestHDFSConcat now passes with asserts enabled.
> FSDirectory#unprotectedConcat calls setModificationTime on a file
> -----------------------------------------------------------------
>
> Key: HDFS-1498
> URL: https://issues.apache.org/jira/browse/HDFS-1498
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: name-node
> Reporter: Eli Collins
> Assignee: Eli Collins
> Priority: Minor
> Fix For: 0.22.0
>
> Attachments: hdfs-1498-1.patch
>
>
> The HDFSConcat test fails when asserts are enabled because FSDirectory#unprotectedConcat calls INode#setModificationTime on a file, this method asserts that the argument is a directory. It should use setModificationTimeForce since we know the target is a file, it's mod time should be set to now unconditionally since we know we're modifying it. The behavior should be equivalent.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HDFS-1498) FSDirectory#unprotectedConcat calls
setModificationTime on a file
Posted by "Konstantin Boudnik (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HDFS-1498?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12931886#action_12931886 ]
Konstantin Boudnik commented on HDFS-1498:
------------------------------------------
+1 patch looks good.
> FSDirectory#unprotectedConcat calls setModificationTime on a file
> -----------------------------------------------------------------
>
> Key: HDFS-1498
> URL: https://issues.apache.org/jira/browse/HDFS-1498
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: name-node
> Affects Versions: 0.22.0
> Reporter: Eli Collins
> Assignee: Eli Collins
> Priority: Minor
> Fix For: 0.22.0
>
> Attachments: hdfs-1498-1.patch
>
>
> The HDFSConcat test fails when asserts are enabled because FSDirectory#unprotectedConcat calls INode#setModificationTime on a file, this method asserts that the argument is a directory. It should use setModificationTimeForce since we know the target is a file, it's mod time should be set to now unconditionally since we know we're modifying it. The behavior should be equivalent.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (HDFS-1498) FSDirectory#unprotectedConcat calls
setModificationTime on a file
Posted by "Konstantin Boudnik (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/HDFS-1498?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12931898#action_12931898 ]
Konstantin Boudnik commented on HDFS-1498:
------------------------------------------
BTW, it has been discussed a few times - there's no need to add numerical modifier to a patch file: JIRA takes care about this automatically.
> FSDirectory#unprotectedConcat calls setModificationTime on a file
> -----------------------------------------------------------------
>
> Key: HDFS-1498
> URL: https://issues.apache.org/jira/browse/HDFS-1498
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: name-node
> Affects Versions: 0.22.0
> Reporter: Eli Collins
> Assignee: Eli Collins
> Priority: Minor
> Fix For: 0.22.0
>
> Attachments: hdfs-1498-1.patch
>
>
> The HDFSConcat test fails when asserts are enabled because FSDirectory#unprotectedConcat calls INode#setModificationTime on a file, this method asserts that the argument is a directory. It should use setModificationTimeForce since we know the target is a file, it's mod time should be set to now unconditionally since we know we're modifying it. The behavior should be equivalent.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.