hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kurtis Heimerl (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HADOOP-1298) adding user info to file
Date Thu, 10 May 2007 23:26:15 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-1298?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12494911
] 

Kurtis Heimerl commented on HADOOP-1298:
----------------------------------------

New patch.

I use the the binary represenation throughout now, in short form, as a byte won't hold it.
There's some confusion there since the binary operators work on ints. Also, there are no unsigned
integers so there may be some rollover issues. Since I don't do any nonlogical operations,
it's unlikely. A nice benefit is that the binary is easily identified in the code, as shorts
are not commonly used. 

FileSystem.chmod takes a short too, and the javadoc states the format it expects. So I don't
need to reference FileStatus. 

There is little code overlap, Permissions and FileStatus have the same implementation of groupReadable
and such. I think that explicitly coupling these two classes is a bad idea. I've added a PosixConstants
class which holds the binary each accesses. We could move these methods to that class and
have both extend that, but I think the slight cost of having two methods that do roughly the
same thing in two areas is less than the cost of having any meaningful (code) coupling between
fs and dfs. 

FileStatus is now the superclass of DFSFileInfo. So any other file system wishing to create
a permissions model should subclass that as well. 

lastly, the groups and user maps have been seperated into their own class, Users.java. This
is instantiated on a per FSDirectory status. The refactoring of this was difficult, so there's
a high likehood I messed up somewhere. 

Lastly again, TestCheckpoint fails in the ant test. It's a BindingException though, as the
port requested is in use. I think this may be a bug outside of this issue. 

> adding user info to file
> ------------------------
>
>                 Key: HADOOP-1298
>                 URL: https://issues.apache.org/jira/browse/HADOOP-1298
>             Project: Hadoop
>          Issue Type: New Feature
>          Components: dfs, fs
>            Reporter: Kurtis Heimerl
>         Attachments: hadoop-user-munncha.patch, hadoop-user-munncha.patch, hadoop-user-munncha.patch,
hadoop-user-munncha.patch10, hadoop-user-munncha.patch11, hadoop-user-munncha.patch12, hadoop-user-munncha.patch13,
hadoop-user-munncha.patch4, hadoop-user-munncha.patch5, hadoop-user-munncha.patch6, hadoop-user-munncha.patch7,
hadoop-user-munncha.patch8, hadoop-user-munncha.patch9
>
>
> I'm working on adding a permissions model to hadoop's DFS. The first step is this change,
which associates user info with files. Following this I'll assoicate permissions info, then
block methods based on that user info, then authorization of the user info. 
> So, right now i've implemented adding user info to files. I'm looking for feedback before
I clean this up and make it offical. 
> I wasn't sure what release, i'm working off trunk. 

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


Mime
View raw message