|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.cassandra.db.commitlog.CommitLogSegment
public class CommitLogSegment
Field Summary | |
---|---|
long |
id
|
Method Summary | |
---|---|
void |
close()
Close the segment file. |
boolean |
contains(ReplayPosition context)
Check to see if a certain ReplayPosition is contained by this segment file. |
java.lang.String |
dirtyString()
|
void |
discard(boolean deleteFile)
Completely discards a segment file by deleting it. |
static CommitLogSegment |
freshSegment()
|
ReplayPosition |
getContext()
|
java.util.Collection<java.lang.Integer> |
getDirtyCFIDs()
|
java.lang.String |
getName()
|
java.lang.String |
getPath()
|
boolean |
hasCapacityFor(RowMutation mutation)
|
static long |
idFromFilename(java.lang.String filename)
Extracts the commit log ID from filename |
boolean |
isUnused()
|
void |
markClean(java.lang.Integer cfId,
ReplayPosition context)
Marks the ColumnFamily specified by cfId as clean for this log segment. |
int |
position()
|
static boolean |
possibleCommitLogFile(java.lang.String filename)
|
CommitLogSegment |
recycle()
Recycle processes an unneeded segment file for reuse. |
void |
sync()
Forces a disk flush for this segment file. |
java.lang.String |
toString()
|
ReplayPosition |
write(RowMutation rowMutation)
Appends a row mutation onto the commit log. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public final long id
Method Detail |
---|
public static CommitLogSegment freshSegment()
public static long idFromFilename(java.lang.String filename)
filename
- the filename of the commit log file
public static boolean possibleCommitLogFile(java.lang.String filename)
filename
- the filename to check
public void discard(boolean deleteFile)
public CommitLogSegment recycle()
public boolean hasCapacityFor(RowMutation mutation)
public ReplayPosition write(RowMutation rowMutation) throws java.io.IOException
rowMutation
- the mutation to append to the commit log.
java.io.IOException
public void sync() throws java.io.IOException
java.io.IOException
public ReplayPosition getContext()
public java.lang.String getPath()
public java.lang.String getName()
public void close()
public void markClean(java.lang.Integer cfId, ReplayPosition context)
cfId
- the column family ID that is now cleancontext
- the optional clean offsetpublic java.util.Collection<java.lang.Integer> getDirtyCFIDs()
public boolean isUnused()
public boolean contains(ReplayPosition context)
context
- the replay position to be checked
public java.lang.String dirtyString()
public java.lang.String toString()
toString
in class java.lang.Object
public int position()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |