@ThreadSafe public class CephFSUnderFileSystem extends ConsistentUnderFileSystem implements AtomicFileOutputStreamCallback
UnderFileSystem implementation.UnderFileSystem.Factory, UnderFileSystem.SpaceTypeEMPTY_ACL, mUfsConf, mUri| Constructor and Description |
|---|
CephFSUnderFileSystem(AlluxioURI ufsUri,
com.ceph.fs.CephMount mount,
UnderFileSystemConfiguration conf)
Constructs a new CephFS
UnderFileSystem. |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanup() |
void |
close() |
void |
connectFromMaster(java.lang.String host) |
void |
connectFromWorker(java.lang.String host) |
java.io.OutputStream |
create(java.lang.String path,
CreateOptions options) |
java.io.OutputStream |
createDirect(java.lang.String path,
CreateOptions options) |
static CephFSUnderFileSystem |
createInstance(AlluxioURI ufsUri,
UnderFileSystemConfiguration conf)
Factory method to constructs a new CephFS
UnderFileSystem instance. |
boolean |
deleteDirectory(java.lang.String path,
DeleteOptions options) |
boolean |
deleteFile(java.lang.String path) |
boolean |
exists(java.lang.String path) |
long |
getBlockSizeByte(java.lang.String path) |
UfsDirectoryStatus |
getDirectoryStatus(java.lang.String path) |
java.util.List<java.lang.String> |
getFileLocations(java.lang.String path) |
java.util.List<java.lang.String> |
getFileLocations(java.lang.String path,
FileLocationOptions options) |
UfsFileStatus |
getFileStatus(java.lang.String path)
Gets stat information on a file.
|
long |
getSpace(java.lang.String path,
UnderFileSystem.SpaceType type) |
UfsStatus |
getStatus(java.lang.String path) |
java.lang.String |
getUnderFSType() |
boolean |
isDirectory(java.lang.String path) |
boolean |
isFile(java.lang.String path) |
boolean |
isSeekable() |
UfsStatus[] |
listStatus(java.lang.String path)
Each string is a name rather than a complete path.
|
boolean |
mkdirs(java.lang.String path,
MkdirsOptions options) |
java.io.InputStream |
open(java.lang.String path,
OpenOptions options) |
boolean |
renameDirectory(java.lang.String src,
java.lang.String dst) |
boolean |
renameFile(java.lang.String src,
java.lang.String dst) |
boolean |
renameRenamableDirectory(java.lang.String src,
java.lang.String dst) |
boolean |
renameRenamableFile(java.lang.String src,
java.lang.String dst) |
void |
setMode(java.lang.String path,
short mode) |
void |
setOwner(java.lang.String path,
java.lang.String user,
java.lang.String group) |
boolean |
supportsFlush() |
createNonexistingFile, createNonexistingFile, deleteExistingDirectory, deleteExistingDirectory, deleteExistingFile, getExistingDirectoryStatus, getExistingFileStatus, getExistingStatus, isExistingDirectory, openExistingFile, openExistingFilecreate, deleteDirectory, getAclPair, getActiveSyncInfo, getConfiguration, getFingerprint, getOperationMode, getParsedFingerprint, getParsedFingerprint, getPhysicalStores, isObjectStorage, listStatus, mkdirs, open, resolveUri, setAclEntries, startActiveSyncPolling, startSync, stopActiveSyncPolling, stopSync, supportsActiveSync, validatePathclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcreate, createNonexistingFile, createNonexistingFile, deleteDirectory, deleteExistingDirectory, deleteExistingDirectory, deleteExistingFile, getAclPair, getActiveSyncInfo, getConfiguration, getExistingDirectoryStatus, getExistingFileStatus, getExistingStatus, getFingerprint, getOperationMode, getParsedFingerprint, getParsedFingerprint, getPhysicalStores, isExistingDirectory, isObjectStorage, listStatus, mkdirs, open, openExistingFile, openExistingFile, resolveUri, setAclEntries, startActiveSyncPolling, startSync, stopActiveSyncPolling, stopSync, supportsActiveSyncpublic CephFSUnderFileSystem(AlluxioURI ufsUri, com.ceph.fs.CephMount mount, UnderFileSystemConfiguration conf)
UnderFileSystem.ufsUri - the AlluxioURI for this UFSmount - CephMount instanceconf - the configuration for this UFSpublic static CephFSUnderFileSystem createInstance(AlluxioURI ufsUri, UnderFileSystemConfiguration conf) throws java.io.IOException
UnderFileSystem instance.ufsUri - the AlluxioURI for this UFSconf - the configuration for HadoopUnderFileSystem instancejava.io.IOExceptionpublic java.lang.String getUnderFSType()
getUnderFSType in interface UnderFileSystempublic void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseablejava.io.IOExceptionpublic java.io.OutputStream create(java.lang.String path,
CreateOptions options)
throws java.io.IOException
create in interface UnderFileSystemjava.io.IOExceptionpublic void cleanup()
throws java.io.IOException
cleanup in interface UnderFileSystemjava.io.IOExceptionpublic java.io.OutputStream createDirect(java.lang.String path,
CreateOptions options)
throws java.io.IOException
createDirect in interface AtomicFileOutputStreamCallbackjava.io.IOExceptionpublic boolean deleteDirectory(java.lang.String path,
DeleteOptions options)
throws java.io.IOException
deleteDirectory in interface UnderFileSystemjava.io.IOExceptionpublic boolean deleteFile(java.lang.String path)
throws java.io.IOException
deleteFile in interface UnderFileSystemjava.io.IOExceptionpublic boolean exists(java.lang.String path)
throws java.io.IOException
exists in interface UnderFileSystemexists in class BaseUnderFileSystemjava.io.IOExceptionpublic long getBlockSizeByte(java.lang.String path)
throws java.io.IOException
getBlockSizeByte in interface UnderFileSystemjava.io.IOExceptionpublic UfsDirectoryStatus getDirectoryStatus(java.lang.String path) throws java.io.IOException
getDirectoryStatus in interface UnderFileSystemjava.io.IOExceptionpublic UfsStatus getStatus(java.lang.String path) throws java.io.IOException
getStatus in interface UnderFileSystemjava.io.IOExceptionpublic java.util.List<java.lang.String> getFileLocations(java.lang.String path)
throws java.io.IOException
getFileLocations in interface UnderFileSystemjava.io.IOException@Nullable
public java.util.List<java.lang.String> getFileLocations(java.lang.String path,
FileLocationOptions options)
throws java.io.IOException
getFileLocations in interface UnderFileSystemjava.io.IOExceptionpublic UfsFileStatus getFileStatus(java.lang.String path) throws java.io.IOException
getFileStatus in interface UnderFileSystempath - The path to statjava.io.FileNotFoundException - if the path could not be resolvedjava.io.IOExceptionpublic long getSpace(java.lang.String path,
UnderFileSystem.SpaceType type)
throws java.io.IOException
getSpace in interface UnderFileSystemjava.io.IOExceptionpublic boolean isDirectory(java.lang.String path)
throws java.io.IOException
isDirectory in interface UnderFileSystemjava.io.IOExceptionpublic boolean isFile(java.lang.String path)
throws java.io.IOException
isFile in interface UnderFileSystemjava.io.IOException@Nullable public UfsStatus[] listStatus(java.lang.String path) throws java.io.IOException
listStatus in interface UnderFileSystempath - the path to listjava.io.IOExceptionpublic void connectFromMaster(java.lang.String host)
throws java.io.IOException
connectFromMaster in interface UnderFileSystemjava.io.IOExceptionpublic void connectFromWorker(java.lang.String host)
throws java.io.IOException
connectFromWorker in interface UnderFileSystemjava.io.IOExceptionpublic boolean mkdirs(java.lang.String path,
MkdirsOptions options)
throws java.io.IOException
mkdirs in interface UnderFileSystemjava.io.IOExceptionpublic java.io.InputStream open(java.lang.String path,
OpenOptions options)
throws java.io.IOException
open in interface UnderFileSystemjava.io.IOExceptionpublic boolean renameDirectory(java.lang.String src,
java.lang.String dst)
throws java.io.IOException
renameDirectory in interface UnderFileSystemjava.io.IOExceptionpublic boolean renameFile(java.lang.String src,
java.lang.String dst)
throws java.io.IOException
renameFile in interface UnderFileSystemjava.io.IOExceptionpublic boolean renameRenamableDirectory(java.lang.String src,
java.lang.String dst)
throws java.io.IOException
renameRenamableDirectory in interface UnderFileSystemrenameRenamableDirectory in class ConsistentUnderFileSystemjava.io.IOExceptionpublic boolean renameRenamableFile(java.lang.String src,
java.lang.String dst)
throws java.io.IOException
renameRenamableFile in interface UnderFileSystemrenameRenamableFile in class ConsistentUnderFileSystemjava.io.IOExceptionpublic void setOwner(java.lang.String path,
java.lang.String user,
java.lang.String group)
throws java.io.IOException
setOwner in interface UnderFileSystemjava.io.IOExceptionpublic void setMode(java.lang.String path,
short mode)
throws java.io.IOException
setMode in interface UnderFileSystemjava.io.IOExceptionpublic boolean supportsFlush()
supportsFlush in interface UnderFileSystempublic boolean isSeekable()
isSeekable in interface UnderFileSystemisSeekable in class BaseUnderFileSystemCopyright © 2023. All Rights Reserved.