@Test public void isInMemoryTest3() throws InvalidPathException, FileAlreadyExistException, IOException { mTfs.mkdir("/pin"); mTfs.pinFile(mTfs.getFileId("/pin")); int fileId = TestUtils.createByteFile(mTfs, "/pin/file", WriteType.MUST_CACHE, USER_QUOTA_UNIT_BYTES); TachyonFile file = mTfs.getFile(fileId); Assert.assertTrue(file.isInMemory()); for (int k = 0; k < MAX_FILES; k ++) { fileId = TestUtils.createByteFile(mTfs, "/file" + k, WriteType.MUST_CACHE, USER_QUOTA_UNIT_BYTES); file = mTfs.getFile(fileId); Assert.assertTrue(file.isInMemory()); } CommonUtils.sleepMs(null, WORKER_TO_MASTER_HEARTBEAT_INTERVAL_MS); file = mTfs.getFile("/pin/file"); Assert.assertTrue(file.isInMemory()); file = mTfs.getFile("/file0"); Assert.assertFalse(file.isInMemory()); for (int k = 1; k < MAX_FILES; k ++) { file = mTfs.getFile("/file" + k); Assert.assertTrue(file.isInMemory()); } }
public boolean isInMemory() throws IOException { return TFS.isInMemory(FID); }
TachyonFile implements Comparable<TachyonFile> { public boolean isInMemory() throws IOException { return TFS.isInMemory(FID); } }
TachyonFile implements Comparable<TachyonFile> { public boolean isInMemory() throws IOException { return TFS.isInMemory(FID); } TachyonFile(TachyonFS tfs, int fid); }
TachyonFile implements Comparable<TachyonFile> { public boolean isInMemory() throws IOException { return TFS.isInMemory(FID); } TachyonFile(TachyonFS tfs, int fid); @Override int compareTo(TachyonFile o); @Override boolean equals(Object obj); long getBlockId(int blockIndex); long getBlockSizeByte(); long getCreationTimeMs(); int getDiskReplication(); InStream getInStream(ReadType readType); String getLocalFilename(int blockIndex); List<String> getLocationHosts(); int getNumberOfBlocks(); OutStream getOutStream(WriteType writeType); String getPath(); Object getUFSConf(); @Override int hashCode(); boolean isComplete(); boolean isDirectory(); boolean isFile(); boolean isInLocalMemory(); boolean isInMemory(); long length(); boolean needPin(); TachyonByteBuffer readByteBuffer(); boolean recache(); boolean rename(String path); void setUFSConf(Object conf); @Override String toString(); }
TachyonFile implements Comparable<TachyonFile> { public boolean isInMemory() throws IOException { return TFS.isInMemory(FID); } TachyonFile(TachyonFS tfs, int fid); @Override int compareTo(TachyonFile o); @Override boolean equals(Object obj); long getBlockId(int blockIndex); long getBlockSizeByte(); long getCreationTimeMs(); int getDiskReplication(); InStream getInStream(ReadType readType); String getLocalFilename(int blockIndex); List<String> getLocationHosts(); int getNumberOfBlocks(); OutStream getOutStream(WriteType writeType); String getPath(); Object getUFSConf(); @Override int hashCode(); boolean isComplete(); boolean isDirectory(); boolean isFile(); boolean isInLocalMemory(); boolean isInMemory(); long length(); boolean needPin(); TachyonByteBuffer readByteBuffer(); boolean recache(); boolean rename(String path); void setUFSConf(Object conf); @Override String toString();  }