Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.cassandra.config
Class CFMetaData

    java.lang.Object
      org.apache.cassandra.config.CFMetaData

    public final class CFMetaData

extends java.lang.Object

Field Summary
`java.lang.Integer` | `cfId`
`java.lang.String` | `cfName`
`ColumnFamilyType` | `cfType`
`java.lang.Class<? extends AbstractCompactionStrategy>` | `compactionStrategyClass`
`java.util.Map<java.lang.String,java.lang.String>` | `compactionStrategyOptions`
`AbstractType` | `comparator`
`static java.lang.String` | `DEFAULT_COMPACTION_STRATEGY_CLASS`
`static int` | `DEFAULT_GC_GRACE_SECONDS`
`static int` | `DEFAULT_KEY_CACHE_SAVE_PERIOD_IN_SECONDS`
`static double` | `DEFAULT_KEY_CACHE_SIZE`
`static java.nio.ByteBuffer` | `DEFAULT_KEY_NAME`
`static int` | `DEFAULT_MAX_COMPACTION_THRESHOLD`
`static double` | `DEFAULT_MERGE_SHARDS_CHANCE`
`static int` | `DEFAULT_MIN_COMPACTION_THRESHOLD`
`static double` | `DEFAULT_READ_REPAIR_CHANCE`
`static boolean` | `DEFAULT_REPLICATE_ON_WRITE`
`static int` | `DEFAULT_ROW_CACHE_KEYS_TO_SAVE`
`static IRowCacheProvider` | `DEFAULT_ROW_CACHE_PROVIDER`
`static int` | `DEFAULT_ROW_CACHE_SAVE_PERIOD_IN_SECONDS`
`static double` | `DEFAULT_ROW_CACHE_SIZE`
`static CFMetaData` | `HintsCf`
`static CFMetaData` | `IndexCf`
`java.lang.String` | `ksName`
`static CFMetaData` | `MigrationsCf`
`static CFMetaData` | `NodeIdCf`
`static CFMetaData` | `SchemaCf`
`static CFMetaData` | `StatusCf`
`AbstractType` | `subcolumnComparator`
`static CFMetaData` | `VersionCf`

Constructor Summary
`CFMetaData(java.lang.String keyspace, java.lang.String name, ColumnFamilyType type, AbstractType comp, AbstractType subcc)`

Method Summary
`static void` | `addDefaultIndexNames(CfDef cf_def)` Convert a null index_name to appropriate default name according to column status
`void` | `apply(org.apache.cassandra.db.migration.avro.CfDef cf_def)` updates CFMetaData in-place to match cf_def
`static void` | `applyImplicitDefaults(CfDef cf_def)` applies implicit defaults to cf definition.
`CFMetaData` | `columnMetadata(java.util.Map<java.nio.ByteBuffer,ColumnDefinition> prop)`
`CFMetaData` | `comment(java.lang.String prop)`
`CFMetaData` | `compactionStrategyClass(java.lang.Class<? extends AbstractCompactionStrategy> prop)`
`CFMetaData` | `compactionStrategyOptions(java.util.Map<java.lang.String,java.lang.String> prop)`
`CompressionParameters` | `compressionParameters()`
`CFMetaData` | `compressionParameters(CompressionParameters prop)`
`static java.lang.Class<? extends AbstractCompactionStrategy>` | `createCompactionSrategy(java.lang.String className)`
`AbstractCompactionStrategy` | `createCompactionStrategyInstance(ColumnFamilyStore cfs)`
`CFMetaData` | `defaultValidator(AbstractType prop)`
`boolean` | `equals(java.lang.Object obj)`
`static CFMetaData` | `fromAvro(org.apache.cassandra.db.migration.avro.CfDef cf)`
`static CFMetaData` | `fromThrift(CfDef cf_def)`
`CFMetaData` | `gcGraceSeconds(int prop)`
`java.util.Map<java.nio.ByteBuffer,ColumnDefinition>` | `getColumn_metadata()`
`ColumnDefinition` | `getColumnDefinition(java.nio.ByteBuffer name)`
`ColumnDefinition` | `getColumnDefinitionForIndex(java.lang.String indexName)`
`IColumnSerializer` | `getColumnSerializer()`
`java.lang.String` | `getComment()`
`AbstractType` | `getComparatorFor(java.nio.ByteBuffer superColumnName)`
`static java.lang.String` | `getDefaultIndexName(java.lang.String cfName, AbstractType comparator, java.nio.ByteBuffer columnName)`
`AbstractType` | `getDefaultValidator()`
`int` | `getGcGraceSeconds()`
`int` | `getKeyCacheSavePeriodInSeconds()`
`double` | `getKeyCacheSize()`
`java.nio.ByteBuffer` | `getKeyName()`
`AbstractType` | `getKeyValidator()`
`java.lang.Integer` | `getMaxCompactionThreshold()`
`double` | `getMergeShardsChance()`
`java.lang.Integer` | `getMinCompactionThreshold()`
`double` | `getReadRepairChance()`
`boolean` | `getReplicateOnWrite()`
`int` | `getRowCacheKeysToSave()`
`IRowCacheProvider` | `getRowCacheProvider()`
`int` | `getRowCacheSavePeriodInSeconds()`
`double` | `getRowCacheSize()`
`AbstractType` | `getValueValidator(java.nio.ByteBuffer column)`
`AbstractType` | `getValueValidator(ColumnDefinition columnDefinition)`
`int` | `hashCode()`
`java.lang.String` | `indexColumnFamilyName(ColumnDefinition info)` generate a column family name for an index corresponding to the given column.
`CFMetaData` | `keyAlias(java.nio.ByteBuffer prop)`
`CFMetaData` | `keyCacheSavePeriod(int prop)`
`CFMetaData` | `keyCacheSize(double prop)`
`CFMetaData` | `keyValidator(AbstractType prop)`
`CFMetaData` | `maxCompactionThreshold(int prop)`
`CFMetaData` | `mergeShardsChance(double prop)`
`CFMetaData` | `minCompactionThreshold(int prop)`
`static CFMetaData` | `newIndexMetadata(CFMetaData parent, ColumnDefinition info, AbstractType columnComparator)`
`CFMetaData` | `readRepairChance(double prop)`
`static CFMetaData` | `rename(CFMetaData cfm, java.lang.String newName)`
`static CFMetaData` | `renameTable(CFMetaData cfm, java.lang.String ksName)`
`CFMetaData` | `replicateOnWrite(boolean prop)`
`CFMetaData` | `rowCacheKeysToSave(int prop)`
`CFMetaData` | `rowCacheProvider(IRowCacheProvider prop)`
`CFMetaData` | `rowCacheSavePeriod(int prop)`
`CFMetaData` | `rowCacheSize(double prop)`
`org.apache.cassandra.db.migration.avro.CfDef` | `toAvro()`
`java.lang.String` | `toString()`
`CfDef` | `toThrift()`
`static void` | `validateMinMaxCompactionThresholds(org.apache.cassandra.db.migration.avro.CfDef cf_def)`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### DEFAULT_ROW_CACHE_SIZE

    public static final double DEFAULT_ROW_CACHE_SIZE

See Also:
  Constant Field Values

### DEFAULT_KEY_CACHE_SIZE

    public static final double DEFAULT_KEY_CACHE_SIZE

See Also:
  Constant Field Values

### DEFAULT_READ_REPAIR_CHANCE

    public static final double DEFAULT_READ_REPAIR_CHANCE

See Also:
  Constant Field Values

### DEFAULT_REPLICATE_ON_WRITE

    public static final boolean DEFAULT_REPLICATE_ON_WRITE

See Also:
  Constant Field Values

### DEFAULT_ROW_CACHE_SAVE_PERIOD_IN_SECONDS

    public static final int DEFAULT_ROW_CACHE_SAVE_PERIOD_IN_SECONDS

See Also:
  Constant Field Values

### DEFAULT_KEY_CACHE_SAVE_PERIOD_IN_SECONDS

    public static final int DEFAULT_KEY_CACHE_SAVE_PERIOD_IN_SECONDS

See Also:
  Constant Field Values

### DEFAULT_ROW_CACHE_KEYS_TO_SAVE

    public static final int DEFAULT_ROW_CACHE_KEYS_TO_SAVE

See Also:
  Constant Field Values

### DEFAULT_GC_GRACE_SECONDS

    public static final int DEFAULT_GC_GRACE_SECONDS

See Also:
  Constant Field Values

### DEFAULT_MIN_COMPACTION_THRESHOLD

    public static final int DEFAULT_MIN_COMPACTION_THRESHOLD

See Also:
  Constant Field Values

### DEFAULT_MAX_COMPACTION_THRESHOLD

    public static final int DEFAULT_MAX_COMPACTION_THRESHOLD

See Also:
  Constant Field Values

### DEFAULT_MERGE_SHARDS_CHANCE

    public static final double DEFAULT_MERGE_SHARDS_CHANCE

See Also:
  Constant Field Values

### DEFAULT_ROW_CACHE_PROVIDER

    public static final IRowCacheProvider DEFAULT_ROW_CACHE_PROVIDER

### DEFAULT_COMPACTION_STRATEGY_CLASS

    public static final java.lang.String DEFAULT_COMPACTION_STRATEGY_CLASS

See Also:
  Constant Field Values

### DEFAULT_KEY_NAME

    public static final java.nio.ByteBuffer DEFAULT_KEY_NAME

### StatusCf

    public static final CFMetaData StatusCf

### HintsCf

    public static final CFMetaData HintsCf

### MigrationsCf

    public static final CFMetaData MigrationsCf

### SchemaCf

    public static final CFMetaData SchemaCf

### IndexCf

    public static final CFMetaData IndexCf

### NodeIdCf

    public static final CFMetaData NodeIdCf

### VersionCf

    public static final CFMetaData VersionCf

### cfId

    public final java.lang.Integer cfId

### ksName

    public final java.lang.String ksName

### cfName

    public final java.lang.String cfName

### cfType

    public final ColumnFamilyType cfType

### comparator

    public final AbstractType comparator

### subcolumnComparator

    public final AbstractType subcolumnComparator

### compactionStrategyClass

    public java.lang.Class<? extends AbstractCompactionStrategy> compactionStrategyClass

### compactionStrategyOptions

    public java.util.Map<java.lang.String,java.lang.String> compactionStrategyOptions

Constructor Detail

### CFMetaData

    public CFMetaData(java.lang.String keyspace,
                      java.lang.String name,
                      ColumnFamilyType type,
                      AbstractType comp,
                      AbstractType subcc)

Method Detail

### comment

    public CFMetaData comment(java.lang.String prop)

### rowCacheSize

    public CFMetaData rowCacheSize(double prop)

### keyCacheSize

    public CFMetaData keyCacheSize(double prop)

### readRepairChance

    public CFMetaData readRepairChance(double prop)

### replicateOnWrite

    public CFMetaData replicateOnWrite(boolean prop)

### gcGraceSeconds

    public CFMetaData gcGraceSeconds(int prop)

### defaultValidator

    public CFMetaData defaultValidator(AbstractType prop)

### keyValidator

    public CFMetaData keyValidator(AbstractType prop)

### minCompactionThreshold

    public CFMetaData minCompactionThreshold(int prop)

### maxCompactionThreshold

    public CFMetaData maxCompactionThreshold(int prop)

### rowCacheSavePeriod

    public CFMetaData rowCacheSavePeriod(int prop)

### keyCacheSavePeriod

    public CFMetaData keyCacheSavePeriod(int prop)

### rowCacheKeysToSave

    public CFMetaData rowCacheKeysToSave(int prop)

### mergeShardsChance

    public CFMetaData mergeShardsChance(double prop)

### keyAlias

    public CFMetaData keyAlias(java.nio.ByteBuffer prop)

### columnMetadata

    public CFMetaData columnMetadata(java.util.Map<java.nio.ByteBuffer,ColumnDefinition> prop)

### rowCacheProvider

    public CFMetaData rowCacheProvider(IRowCacheProvider prop)

### compactionStrategyClass

    public CFMetaData compactionStrategyClass(java.lang.Class<? extends AbstractCompactionStrategy> prop)

### compactionStrategyOptions

    public CFMetaData compactionStrategyOptions(java.util.Map<java.lang.String,java.lang.String> prop)

### compressionParameters

    public CFMetaData compressionParameters(CompressionParameters prop)

### newIndexMetadata

    public static CFMetaData newIndexMetadata(CFMetaData parent,
                                              ColumnDefinition info,
                                              AbstractType columnComparator)

### rename

    public static CFMetaData rename(CFMetaData cfm,
                                    java.lang.String newName)

### renameTable

    public static CFMetaData renameTable(CFMetaData cfm,
                                         java.lang.String ksName)

### indexColumnFamilyName

    public java.lang.String indexColumnFamilyName(ColumnDefinition info)

  generate a column family name for an index corresponding to the given column. This is NOT the same as the index's name! This is only used in sstable filenames and is not exposed to users.

  Parameters:
    `info` - A definition of the column with index
  Returns:
    name of the index ColumnFamily

### toAvro

    public org.apache.cassandra.db.migration.avro.CfDef toAvro()

### fromAvro

    public static CFMetaData fromAvro(org.apache.cassandra.db.migration.avro.CfDef cf)

### getComment

    public java.lang.String getComment()

### getRowCacheSize

    public double getRowCacheSize()

### getKeyCacheSize

    public double getKeyCacheSize()

### getReadRepairChance

    public double getReadRepairChance()

### getMergeShardsChance

    public double getMergeShardsChance()

### getReplicateOnWrite

    public boolean getReplicateOnWrite()

### getGcGraceSeconds

    public int getGcGraceSeconds()

### getDefaultValidator

    public AbstractType getDefaultValidator()

### getKeyValidator

    public AbstractType getKeyValidator()

### getMinCompactionThreshold

    public java.lang.Integer getMinCompactionThreshold()

### getMaxCompactionThreshold

    public java.lang.Integer getMaxCompactionThreshold()

### getRowCacheSavePeriodInSeconds

    public int getRowCacheSavePeriodInSeconds()

### getKeyCacheSavePeriodInSeconds

    public int getKeyCacheSavePeriodInSeconds()

### getRowCacheKeysToSave

    public int getRowCacheKeysToSave()

### getRowCacheProvider

    public IRowCacheProvider getRowCacheProvider()

### getKeyName

    public java.nio.ByteBuffer getKeyName()

### compressionParameters

    public CompressionParameters compressionParameters()

### getColumn_metadata

    public java.util.Map<java.nio.ByteBuffer,ColumnDefinition> getColumn_metadata()

### getComparatorFor

    public AbstractType getComparatorFor(java.nio.ByteBuffer superColumnName)

### equals

    public boolean equals(java.lang.Object obj)

  Overrides:
    `equals` in class `java.lang.Object`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`

### getValueValidator

    public AbstractType getValueValidator(java.nio.ByteBuffer column)

### getValueValidator

    public AbstractType getValueValidator(ColumnDefinition columnDefinition)

### applyImplicitDefaults

    public static void applyImplicitDefaults(CfDef cf_def)

  applies implicit defaults to cf definition. useful in updates

### fromThrift

    public static CFMetaData fromThrift(CfDef cf_def)
                                 throws InvalidRequestException,
                                        ConfigurationException

  Throws:
    `InvalidRequestException`
    `ConfigurationException`

### apply

    public void apply(org.apache.cassandra.db.migration.avro.CfDef cf_def)
               throws ConfigurationException

  updates CFMetaData in-place to match cf_def

  Throws:
    `ConfigurationException`

### createCompactionSrategy

    public static java.lang.Class<? extends AbstractCompactionStrategy> createCompactionSrategy(java.lang.String className)
                                                                                         throws ConfigurationException

  Throws:
    `ConfigurationException`

### createCompactionStrategyInstance

    public AbstractCompactionStrategy createCompactionStrategyInstance(ColumnFamilyStore cfs)

### toThrift

    public CfDef toThrift()

### validateMinMaxCompactionThresholds

    public static void validateMinMaxCompactionThresholds(org.apache.cassandra.db.migration.avro.CfDef cf_def)
                                                   throws ConfigurationException

  Throws:
    `ConfigurationException`

### getColumnDefinition

    public ColumnDefinition getColumnDefinition(java.nio.ByteBuffer name)

### getColumnDefinitionForIndex

    public ColumnDefinition getColumnDefinitionForIndex(java.lang.String indexName)

### addDefaultIndexNames

    public static void addDefaultIndexNames(CfDef cf_def)
                                     throws InvalidRequestException

  Convert a null index_name to appropriate default name according to column status

  Parameters:
    `cf_def` - Thrift ColumnFamily Definition
  Throws:
    `InvalidRequestException`

### getDefaultIndexName

    public static java.lang.String getDefaultIndexName(java.lang.String cfName,
                                                       AbstractType comparator,
                                                       java.nio.ByteBuffer columnName)

### getColumnSerializer

    public IColumnSerializer getColumnSerializer()

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2011 The Apache Software Foundation