public class TachyonFS extends Object
Modifier and Type | Method and Description |
---|---|
void |
accessLocalBlock(long blockId) |
void |
addCheckpoint(int fid) |
boolean |
asyncCheckpoint(int fid) |
void |
cacheBlock(long blockId) |
void |
close() |
void |
completeFile(int fId) |
void |
connect() |
File |
createAndGetUserTempFolder() |
String |
createAndGetUserUnderfsTempFolder() |
int |
createDependency(List<String> parents,
List<String> children,
String commandPrefix,
List<ByteBuffer> data,
String comment,
String framework,
String frameworkVersion,
int dependencyType,
long childrenBlockSizeByte) |
int |
createFile(String path) |
int |
createFile(String path,
long blockSizeByte) |
int |
createFile(String path,
String checkpointPath) |
int |
createRawTable(String path,
int columns) |
int |
createRawTable(String path,
int columns,
ByteBuffer metadata) |
boolean |
delete(int fid,
boolean recursive) |
boolean |
delete(String path,
boolean recursive) |
boolean |
exist(String path) |
static TachyonFS |
get(String tachyonAddress) |
long |
getBlockId(int fId,
int blockIndex) |
long |
getBlockIdBasedOnOffset(int fId,
long offset) |
int |
getBlockLockId() |
long |
getBlockSizeByte(int fId) |
ClientBlockInfo |
getClientBlockInfo(int fId,
int blockIndex) |
ClientDependencyInfo |
getClientDependencyInfo(int did) |
long |
getCreationTimeMs(int fId) |
TachyonFile |
getFile(int fid)
Get
TachyonFile based on the file id. |
TachyonFile |
getFile(String path)
Get
TachyonFile based on the path. |
TachyonFile |
getFile(String path,
boolean useCachedMetadata) |
List<Long> |
getFileBlockIdList(int fId) |
List<ClientBlockInfo> |
getFileBlocks(int fid) |
List<String> |
getFileHosts(int fileId) |
int |
getFileId(String path) |
List<NetAddress> |
getFileNetAddresses(int fileId) |
List<List<String>> |
getFilesHosts(List<Integer> fileIds) |
List<List<NetAddress>> |
getFilesNetAddresses(List<Integer> fileIds) |
int |
getNumberOfFiles(String folderPath) |
RawTable |
getRawTable(int id) |
RawTable |
getRawTable(String path) |
String |
getRootFolder() |
String |
getUnderfsAddress() |
List<ClientWorkerInfo> |
getWorkersInfo() |
boolean |
hasLocalWorker() |
boolean |
isConnected() |
List<Integer> |
listFiles(String path,
boolean recursive) |
List<ClientFileInfo> |
listStatus(String path)
If the
path is a directory, return all the direct entries in it. |
List<String> |
ls(String path,
boolean recursive) |
boolean |
mkdir(String path)
Create a directory if it does not exist.
|
void |
outOfMemoryForPinFile(int fid) |
void |
releaseSpace(long releaseSpaceBytes) |
boolean |
rename(int fId,
String path) |
boolean |
rename(String srcPath,
String dstPath) |
void |
reportLostFile(int fileId) |
void |
requestFilesInDependency(int depId) |
boolean |
requestSpace(long requestSpaceBytes) |
boolean |
unpinFile(int fid) |
void |
updateRawTableMetadata(int id,
ByteBuffer metadata) |
public static TachyonFS get(String tachyonAddress) throws IOException
IOException
public void accessLocalBlock(long blockId)
public void addCheckpoint(int fid) throws IOException
IOException
public void cacheBlock(long blockId) throws IOException
IOException
public void close() throws org.apache.thrift.TException
org.apache.thrift.TException
public void connect()
public void completeFile(int fId) throws IOException
IOException
public File createAndGetUserTempFolder() throws IOException
IOException
public String createAndGetUserUnderfsTempFolder() throws IOException
IOException
public int createRawTable(String path, int columns) throws IOException
IOException
public int createRawTable(String path, int columns, ByteBuffer metadata) throws IOException
IOException
public int createFile(String path) throws IOException
IOException
public int createFile(String path, long blockSizeByte) throws IOException
IOException
public int createFile(String path, String checkpointPath) throws IOException
IOException
public boolean delete(int fid, boolean recursive) throws IOException
IOException
public boolean delete(String path, boolean recursive) throws IOException
IOException
public boolean exist(String path) throws IOException
IOException
public long getBlockId(int fId, int blockIndex) throws IOException
IOException
public long getBlockIdBasedOnOffset(int fId, long offset) throws IOException
IOException
public ClientBlockInfo getClientBlockInfo(int fId, int blockIndex) throws IOException
IOException
public long getBlockSizeByte(int fId)
public long getCreationTimeMs(int fId)
public List<Long> getFileBlockIdList(int fId) throws IOException
IOException
public List<ClientBlockInfo> getFileBlocks(int fid) throws IOException
IOException
public TachyonFile getFile(String path) throws IOException
TachyonFile
based on the path.path
- file path.IOException
public TachyonFile getFile(String path, boolean useCachedMetadata) throws IOException
IOException
public TachyonFile getFile(int fid)
TachyonFile
based on the file id.fid
- file id.public int getFileId(String path) throws IOException
IOException
public int getNumberOfFiles(String folderPath) throws IOException
IOException
public RawTable getRawTable(String path) throws IOException
IOException
public RawTable getRawTable(int id) throws IOException
IOException
public String getRootFolder()
public int getBlockLockId()
public String getUnderfsAddress() throws IOException
IOException
public List<ClientWorkerInfo> getWorkersInfo() throws IOException
IOException
public boolean hasLocalWorker()
public boolean isConnected()
public List<Integer> listFiles(String path, boolean recursive) throws IOException
IOException
public List<ClientFileInfo> listStatus(String path) throws IOException
path
is a directory, return all the direct entries in it. If the
path
is a file, return its ClientFileInfo.path
- the target directory/file pathIOException
public List<String> ls(String path, boolean recursive) throws IOException
IOException
public boolean mkdir(String path) throws IOException
path
- Directory path.IOException
public void outOfMemoryForPinFile(int fid)
public void releaseSpace(long releaseSpaceBytes)
public boolean rename(String srcPath, String dstPath) throws IOException
IOException
public boolean rename(int fId, String path) throws IOException
IOException
public boolean requestSpace(long requestSpaceBytes)
public boolean unpinFile(int fid) throws IOException
IOException
public void updateRawTableMetadata(int id, ByteBuffer metadata) throws IOException
IOException
public int createDependency(List<String> parents, List<String> children, String commandPrefix, List<ByteBuffer> data, String comment, String framework, String frameworkVersion, int dependencyType, long childrenBlockSizeByte) throws IOException
IOException
public void reportLostFile(int fileId) throws IOException
IOException
public void requestFilesInDependency(int depId) throws IOException
IOException
public boolean asyncCheckpoint(int fid) throws IOException
IOException
public ClientDependencyInfo getClientDependencyInfo(int did) throws IOException
IOException
public List<NetAddress> getFileNetAddresses(int fileId) throws IOException
IOException
public List<List<NetAddress>> getFilesNetAddresses(List<Integer> fileIds) throws IOException
IOException
public List<String> getFileHosts(int fileId) throws IOException
IOException
public List<List<String>> getFilesHosts(List<Integer> fileIds) throws IOException
IOException
Copyright © 2014. All rights reserved.