Package org.apache.cassandra.io.sstable
Interface SSTableId
-
- All Known Implementing Classes:
SequenceBasedSSTableId,UUIDBasedSSTableId
public interface SSTableIdRepresents a unique identifier in the sstable descriptor filename. This ensures each sstable file uniqueness for the certain table on a single node. However, new implementations should ensure the uniqueness across the entire cluster. The legacy implementation which does not satisfy cluster-wide uniqueness will be deprecated and eventually removed.A new implementation must adhere to the following invariants: - Must be locally sortable - that is, the comparison must reflect the comparison of generation times of identifiers generated on the same node - String representation must *not* include the
Descriptor.FILENAME_SEPARATORcharacter, seeDescriptor.fromFilenameWithComponent(File)- must be case-insensitive because the sstables can be stored on case-insensitive file system
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceSSTableId.Builder<T extends SSTableId>Builder that can create instances of certain implementation ofSSTableId.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.nio.ByteBufferasBytes()Creates a byte format of the identifier that can be parsed bySSTableId.Builder.fromBytes(ByteBuffer)java.lang.StringtoString()Creates a String format of the identifier that can be parsed bySSTableId.Builder.fromString(String)
-
-
-
Method Detail
-
asBytes
java.nio.ByteBuffer asBytes()
Creates a byte format of the identifier that can be parsed bySSTableId.Builder.fromBytes(ByteBuffer)
-
toString
java.lang.String toString()
Creates a String format of the identifier that can be parsed bySSTableId.Builder.fromString(String)Must not contain any
Descriptor.FILENAME_SEPARATORcharacter as it is used in the Descriptor seeDescriptor.fromFilenameWithComponent(File)- Overrides:
toStringin classjava.lang.Object
-
-