public class CustomAuthPolicy extends LaunchUserGroupAuthPolicy
mFileSystem, mFuseFileSystem, mFuseOptions
Modifier and Type | Method and Description |
---|---|
static CustomAuthPolicy |
create(FileSystem fileSystem,
AlluxioFuseFileSystemOpts fuseFsOpts,
Optional<FuseFileSystem> fuseFileSystem)
Creates a new custom auth policy.
|
Optional<Long> |
getGid(String group)
Gets the gid based on the auth policy and file group.
|
Optional<Long> |
getUid(String owner)
Gets the uid based on the auth policy and file owner.
|
void |
setUserGroupIfNeeded(AlluxioURI uri)
Sets user and group based on authentication policy.
|
init, setUserGroup
public static CustomAuthPolicy create(FileSystem fileSystem, AlluxioFuseFileSystemOpts fuseFsOpts, Optional<FuseFileSystem> fuseFileSystem)
fileSystem
- file systemfuseFsOpts
- fuse optionsfuseFileSystem
- fuse file systempublic void setUserGroupIfNeeded(AlluxioURI uri)
AuthPolicy
setUserGroupIfNeeded
in interface AuthPolicy
setUserGroupIfNeeded
in class LaunchUserGroupAuthPolicy
uri
- the path uripublic Optional<Long> getUid(String owner)
AuthPolicy
getUid
in interface AuthPolicy
getUid
in class LaunchUserGroupAuthPolicy
owner
- the owner of the filepublic Optional<Long> getGid(String group)
AuthPolicy
getGid
in interface AuthPolicy
getGid
in class LaunchUserGroupAuthPolicy
group
- the file groupCopyright © 2023. All Rights Reserved.