Class TableOptionsMetadata
- java.lang.Object
-
- com.datastax.driver.core.TableOptionsMetadata
-
public class TableOptionsMetadata extends Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object other)StringgetAdditionalWritePolicy()The threshold at which a cheap quorum write will be upgraded to include transient replicas.doublegetBloomFilterFalsePositiveChance()Returns the false positive chance for the Bloom filter of this table.Map<String,String>getCaching()Returns the caching options for this table.StringgetComment()Returns the commentary set for this table.Map<String,String>getCompaction()Returns the compaction options for this table.Map<String,String>getCompression()Returns the compression options for this table.DoublegetCrcCheckChance()When compression is enabled, this option defines the probability with which checksums for compressed blocks are checked during reads.intgetDefaultTimeToLive()Returns the default TTL for this table.Map<String,ByteBuffer>getExtensions()Returns the extension options for this table.intgetGcGraceInSeconds()Returns the tombstone garbage collection grace time in seconds for this table.IntegergetIndexInterval()Returns the index interval option for this table.doublegetLocalReadRepairChance()Returns the cluster local read repair chance set for this table.Map<String,Map<String,String>>getMapExtensions()Returns the extension options for this table, but only those represented byMap<String, String>.IntegergetMaxIndexInterval()Returns the maximum index interval option for this table.intgetMemtableFlushPeriodInMs()IntegergetMinIndexInterval()Returns the minimum index interval option for this table.booleangetPopulateIOCacheOnFlush()Whether the populate I/O cache on flush is set on this table.StringgetReadRepair()Returns the read_repair option for this table.doublegetReadRepairChance()Returns the chance with which a read repair is triggered for this table.booleangetReplicateOnWrite()Returns whether replicateOnWrite is set for this table.Map<String,String>getScyllaAlternatorTags()Returns the DynamoDB tags associated with this table if this is a valid Scylla Alternator table or @{code null} otherwise.Map<String,String>getScyllaCDCOptions()Returns the options of Scylla Change Data Capture (CDC) for this table or @{code null} if CDC is disabled on this table.Map<String,String>getScyllaEncryptionOptions()Returns the options of Scylla Encryption at Rest for this table or @{code null} if Scylla Encryption at Rest is disabled on this table.StringgetSpeculativeRetry()Returns the speculative retry option for this table.inthashCode()booleanisCDC()Returns whether or not change data capture is enabled for this table.booleanisCompactStorage()Returns whether the table uses theCOMPACT STORAGEoption.booleanisScyllaCDC()Returns whether or not Scylla change data capture is enabled for this table.
-
-
-
Method Detail
-
isCompactStorage
public boolean isCompactStorage()
Returns whether the table uses theCOMPACT STORAGEoption.- Returns:
- whether the table uses the
COMPACT STORAGEoption.
-
getComment
public String getComment()
Returns the commentary set for this table.- Returns:
- the commentary set for this table, or
nullif noe has been set.
-
getReadRepairChance
public double getReadRepairChance()
Returns the chance with which a read repair is triggered for this table.- Returns:
- the read repair chance set for table (in [0.0, 1.0]).
-
getReadRepair
public String getReadRepair()
Returns the read_repair option for this table. NOTE: this is a Cassandra® 4.0 and newer option (described here: http://cassandra.apache.org/doc/latest/operating/read_repair.html). Possible values areBLOCKINGorNONE, with the default beingBLOCKING.- Returns:
- the read repair option (either
BLOCKINGorNONE).
-
getLocalReadRepairChance
public double getLocalReadRepairChance()
Returns the cluster local read repair chance set for this table.- Returns:
- the local read repair chance set for table (in [0.0, 1.0]).
-
getReplicateOnWrite
public boolean getReplicateOnWrite()
Returns whether replicateOnWrite is set for this table.This is only meaningful for tables holding counters.
- Returns:
- whether replicateOnWrite is set for this table.
-
getGcGraceInSeconds
public int getGcGraceInSeconds()
Returns the tombstone garbage collection grace time in seconds for this table.- Returns:
- the tombstone garbage collection grace time in seconds for this table.
-
getBloomFilterFalsePositiveChance
public double getBloomFilterFalsePositiveChance()
Returns the false positive chance for the Bloom filter of this table.- Returns:
- the Bloom filter false positive chance for this table (in [0.0, 1.0]).
-
getCaching
public Map<String,String> getCaching()
Returns the caching options for this table.- Returns:
- an immutable map containing the caching options for this table.
-
getPopulateIOCacheOnFlush
public boolean getPopulateIOCacheOnFlush()
Whether the populate I/O cache on flush is set on this table.- Returns:
- whether the populate I/O cache on flush is set on this table.
-
getMemtableFlushPeriodInMs
public int getMemtableFlushPeriodInMs()
-
getDefaultTimeToLive
public int getDefaultTimeToLive()
Returns the default TTL for this table.Note: this option is not available in Cassandra 1.2 and will return 0 (no default TTL) when connected to 1.2 nodes.
- Returns:
- the default TTL for this table or 0 if no default TTL is configured.
-
getSpeculativeRetry
public String getSpeculativeRetry()
Returns the speculative retry option for this table.Note: this option is not available in Cassandra 1.2 and will return "NONE" (no speculative retry) when connected to 1.2 nodes.
- Returns:
- the speculative retry option this table.
-
getIndexInterval
public Integer getIndexInterval()
Returns the index interval option for this table.Note: this option is not available in Cassandra 1.2 (more precisely, it is not configurable per-table) and will return 128 (the default index interval) when connected to 1.2 nodes. It is deprecated in Cassandra 2.1 and above, and will therefore return
nullfor 2.1 nodes.- Returns:
- the index interval option for this table.
-
getMinIndexInterval
public Integer getMinIndexInterval()
Returns the minimum index interval option for this table.Note: this option is available in Cassandra 2.1 and above, and will return
nullfor earlier versions.- Returns:
- the minimum index interval option for this table.
-
getMaxIndexInterval
public Integer getMaxIndexInterval()
Returns the maximum index interval option for this table.Note: this option is available in Cassandra 2.1 and above, and will return
nullfor earlier versions.- Returns:
- the maximum index interval option for this table.
-
getCrcCheckChance
public Double getCrcCheckChance()
When compression is enabled, this option defines the probability with which checksums for compressed blocks are checked during reads. The default value for this options is 1.0 (always check).Note that this option is available in Cassandra 3.0.0 and above, when it became a "top-level" table option, whereas previously it was a suboption of the
compressionoption.For Cassandra versions prior to 3.0.0, this method always returns
null.- Returns:
- the probability with which checksums for compressed blocks are checked during reads
-
getCompaction
public Map<String,String> getCompaction()
Returns the compaction options for this table.- Returns:
- an immutable map containing the compaction options for this table.
-
getCompression
public Map<String,String> getCompression()
Returns the compression options for this table.- Returns:
- an immutable map containing the compression options for this table.
-
getExtensions
public Map<String,ByteBuffer> getExtensions()
Returns the extension options for this table.For Cassandra versions prior to 3.0.0, this method always returns an empty map.
- Returns:
- an immutable map containing the extension options for this table.
-
getMapExtensions
public Map<String,Map<String,String>> getMapExtensions()
Returns the extension options for this table, but only those represented byMap<String, String>.- Returns:
- an immutable map containing the extension options for this table, but only those
represented by
Map<String, String>.
-
isCDC
public boolean isCDC()
Returns whether or not change data capture is enabled for this table.For Cassandra versions prior to 3.8.0, this method always returns false.
- Returns:
- whether or not change data capture is enabled for this table.
-
isScyllaCDC
public boolean isScyllaCDC()
Returns whether or not Scylla change data capture is enabled for this table.- Returns:
- whether or not Scylla change data capture is enabled for this table.
-
getScyllaCDCOptions
public Map<String,String> getScyllaCDCOptions()
Returns the options of Scylla Change Data Capture (CDC) for this table or @{code null} if CDC is disabled on this table.- Returns:
- the options of Scylla Change Data Capture (CDC) for this table or @{code null} if CDC is disabled on this table.
- See Also:
- Scylla CDC Parameters
-
getScyllaEncryptionOptions
public Map<String,String> getScyllaEncryptionOptions()
Returns the options of Scylla Encryption at Rest for this table or @{code null} if Scylla Encryption at Rest is disabled on this table.- Returns:
- the options of Scylla Encryption at Rest for this table or @{code null} if Scylla Encryption at Rest is disabled on this table.
- See Also:
- Scylla Encryption at Rest
-
getScyllaAlternatorTags
public Map<String,String> getScyllaAlternatorTags()
Returns the DynamoDB tags associated with this table if this is a valid Scylla Alternator table or @{code null} otherwise.- Returns:
- the DynamoDB tags associated with this table if this is a valid Scylla Alternator table or @{code null} otherwise.
- See Also:
- Scylla Alternator, Tagging Resources in DynamoDB
-
getAdditionalWritePolicy
public String getAdditionalWritePolicy()
The threshold at which a cheap quorum write will be upgraded to include transient replicas.This option is only available in Cassandra® 4.0 and above. Default value is
99p.- Returns:
- The additional write policy for this table (ex. '99p').
-
-