org.apache.cassandra.config
Class DatabaseDescriptor

java.lang.Object
  extended by org.apache.cassandra.config.DatabaseDescriptor

public class DatabaseDescriptor
extends java.lang.Object


Constructor Summary
DatabaseDescriptor()
           
 
Method Summary
static void createAllDirectories()
          Creates all storage-related directories.
static java.lang.String[] getAllDataFileLocations()
           
static IAuthenticator getAuthenticator()
           
static IAuthorizer getAuthorizer()
           
static java.net.InetAddress getBroadcastAddress()
           
static EncryptionOptions.ClientEncryptionOptions getClientEncryptionOptions()
           
static java.lang.String getClusterName()
           
static int getColumnIndexSize()
           
static java.lang.String getCommitLogLocation()
           
static int getCommitLogSegmentSize()
          size of commitlog segments to allocate
static Config.CommitLogSync getCommitLogSync()
           
static double getCommitLogSyncBatchWindow()
           
static int getCommitLogSyncPeriod()
           
static int getCompactionThroughputMbPerSec()
           
static int getConcurrentCompactors()
           
static int getConcurrentReaders()
           
static int getConcurrentReplicators()
           
static int getConcurrentWriters()
           
static Config.DiskAccessMode getDiskAccessMode()
           
static Config.DiskFailurePolicy getDiskFailurePolicy()
           
static double getDynamicBadnessThreshold()
           
static int getDynamicResetInterval()
           
static int getDynamicUpdateInterval()
           
static IEndpointSnitch getEndpointSnitch()
           
static double getFlushLargestMemtablesAt()
           
static int getFlushQueueSize()
           
static int getFlushWriters()
           
static int getHintedHandoffThrottleInKB()
           
static Config.DiskAccessMode getIndexAccessMode()
           
static java.lang.Integer getIndexInterval()
           
static java.util.Collection<java.lang.String> getInitialTokens()
           
static int getInMemoryCompactionLimit()
           
static boolean getInterDCTcpNoDelay()
           
static java.lang.Integer getInternodeRecvBufferSize()
           
static java.lang.Integer getInternodeSendBufferSize()
           
static int getKeyCacheKeysToSave()
           
static int getKeyCacheSavePeriod()
           
static long getKeyCacheSizeInMB()
           
static java.net.InetAddress getListenAddress()
           
static java.util.Comparator<java.net.InetAddress> getLocalComparator()
           
static java.lang.String getLocalDataCenter()
           
static int getMaxHintsThread()
           
static int getMaxHintWindow()
           
static int getMaxStreamingRetries()
           
static long getMinRpcTimeout()
           
static java.net.InetAddress getNativeTransportAddress()
           
static java.lang.Integer getNativeTransportMaxThreads()
           
static java.lang.Integer getNativeTransportMinThreads()
           
static int getNativeTransportPort()
           
static java.lang.Integer getNumTokens()
           
static IPartitioner<?> getPartitioner()
           
static java.lang.String getPartitionerName()
           
static int getPermissionsValidity()
           
static double getPhiConvictThreshold()
           
static boolean getPreheatKeyCache()
           
static long getRangeRpcTimeout()
           
static long getReadRpcTimeout()
           
static double getReduceCacheCapacityTo()
           
static double getReduceCacheSizesAt()
           
static java.util.Collection<java.lang.String> getReplaceTokens()
           
static IRequestScheduler getRequestScheduler()
           
static Config.RequestSchedulerId getRequestSchedulerId()
           
static RequestSchedulerOptions getRequestSchedulerOptions()
           
static int getRowCacheKeysToSave()
           
static IRowCacheProvider getRowCacheProvider()
           
static int getRowCacheSavePeriod()
           
static long getRowCacheSizeInMB()
           
static java.net.InetAddress getRpcAddress()
           
static boolean getRpcKeepAlive()
           
static java.lang.Integer getRpcMaxThreads()
           
static java.lang.Integer getRpcMinThreads()
           
static int getRpcPort()
           
static java.lang.Integer getRpcRecvBufferSize()
           
static java.lang.Integer getRpcSendBufferSize()
           
static java.lang.String getRpcServerType()
           
static long getRpcTimeout()
           
static java.lang.String getSavedCachesLocation()
           
static java.util.Set<java.net.InetAddress> getSeeds()
           
static java.io.File getSerializedCachePath(java.lang.String ksName, java.lang.String cfName, CacheService.CacheType cacheType, java.lang.String version)
           
static EncryptionOptions.ServerEncryptionOptions getServerEncryptionOptions()
           
static int getSSLStoragePort()
           
static int getStoragePort()
           
static int getStreamingSocketTimeout()
           
static int getStreamThroughputOutboundMegabitsPerSec()
           
static int getThriftFramedTransportSize()
           
static int getThriftMaxMessageLength()
           
static long getTimeout(MessagingService.Verb verb)
           
static long getTotalCommitlogSpaceInMB()
           
static int getTotalMemtableSpaceInMB()
           
static boolean getTrickleFsync()
           
static int getTrickleFsyncIntervalInKb()
           
static long getTruncateRpcTimeout()
           
static long getWriteRpcTimeout()
           
static boolean hasCrossNodeTimeout()
           
static boolean hintedHandoffEnabled()
           
static Config.InternodeCompression internodeCompression()
           
static boolean isAutoBootstrap()
           
static boolean isAutoSnapshot()
           
static boolean isIncrementalBackupsEnabled()
           
static boolean isMultithreadedCompaction()
           
static boolean isSnapshotBeforeCompaction()
           
static void loadSchemas()
          load keyspace (table) definitions, but do not initialize the table instances.
static void setBroadcastAddress(java.net.InetAddress broadcastAdd)
           
static void setCompactionThroughputMbPerSec(int value)
           
static void setDiskFailurePolicy(Config.DiskFailurePolicy policy)
           
static void setDynamicBadnessThreshold(java.lang.Double dynamicBadnessThreshold)
           
static void setDynamicResetInterval(java.lang.Integer dynamicResetInterval)
           
static void setDynamicUpdateInterval(java.lang.Integer dynamicUpdateInterval)
           
static void setEndpointSnitch(IEndpointSnitch eps)
           
static void setHintedHandoffEnabled(boolean hintedHandoffEnabled)
           
static void setIncrementalBackupsEnabled(boolean value)
           
static void setInMemoryCompactionLimit(int sizeInMB)
           
static void setKeyCacheSavePeriod(int keyCacheSavePeriod)
           
static void setMaxHintWindow(int ms)
           
static void setPartitioner(IPartitioner<?> newPartitioner)
           
static void setPhiConvictThreshold(double phiConvictThreshold)
           
static void setRangeRpcTimeout(java.lang.Long timeOutInMillis)
           
static void setReadRpcTimeout(java.lang.Long timeOutInMillis)
           
static void setRowCacheSavePeriod(int rowCacheSavePeriod)
           
static void setRpcTimeout(java.lang.Long timeOutInMillis)
           
static void setStreamThroughputOutboundMegabitsPerSec(int value)
           
static void setTruncateRpcTimeout(java.lang.Long timeOutInMillis)
           
static void setWriteRpcTimeout(java.lang.Long timeOutInMillis)
           
static boolean startNativeTransport()
           
static boolean startRpc()
           
static java.util.Collection<java.lang.String> tokensFromString(java.lang.String tokenString)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DatabaseDescriptor

public DatabaseDescriptor()
Method Detail

loadSchemas

public static void loadSchemas()
                        throws java.io.IOException
load keyspace (table) definitions, but do not initialize the table instances.

Throws:
java.io.IOException

getAuthenticator

public static IAuthenticator getAuthenticator()

getAuthorizer

public static IAuthorizer getAuthorizer()

getPermissionsValidity

public static int getPermissionsValidity()

getThriftMaxMessageLength

public static int getThriftMaxMessageLength()

getThriftFramedTransportSize

public static int getThriftFramedTransportSize()

createAllDirectories

public static void createAllDirectories()
Creates all storage-related directories.


getPartitioner

public static IPartitioner<?> getPartitioner()

getPartitionerName

public static java.lang.String getPartitionerName()

setPartitioner

public static void setPartitioner(IPartitioner<?> newPartitioner)

getEndpointSnitch

public static IEndpointSnitch getEndpointSnitch()

setEndpointSnitch

public static void setEndpointSnitch(IEndpointSnitch eps)

getRequestScheduler

public static IRequestScheduler getRequestScheduler()

getRequestSchedulerOptions

public static RequestSchedulerOptions getRequestSchedulerOptions()

getRequestSchedulerId

public static Config.RequestSchedulerId getRequestSchedulerId()

getColumnIndexSize

public static int getColumnIndexSize()

getInitialTokens

public static java.util.Collection<java.lang.String> getInitialTokens()

tokensFromString

public static java.util.Collection<java.lang.String> tokensFromString(java.lang.String tokenString)

getNumTokens

public static java.lang.Integer getNumTokens()

getReplaceTokens

public static java.util.Collection<java.lang.String> getReplaceTokens()

getClusterName

public static java.lang.String getClusterName()

getMaxStreamingRetries

public static int getMaxStreamingRetries()

getStoragePort

public static int getStoragePort()

getSSLStoragePort

public static int getSSLStoragePort()

getRpcPort

public static int getRpcPort()

getRpcTimeout

public static long getRpcTimeout()

setRpcTimeout

public static void setRpcTimeout(java.lang.Long timeOutInMillis)

getReadRpcTimeout

public static long getReadRpcTimeout()

setReadRpcTimeout

public static void setReadRpcTimeout(java.lang.Long timeOutInMillis)

getRangeRpcTimeout

public static long getRangeRpcTimeout()

setRangeRpcTimeout

public static void setRangeRpcTimeout(java.lang.Long timeOutInMillis)

getWriteRpcTimeout

public static long getWriteRpcTimeout()

setWriteRpcTimeout

public static void setWriteRpcTimeout(java.lang.Long timeOutInMillis)

getTruncateRpcTimeout

public static long getTruncateRpcTimeout()

setTruncateRpcTimeout

public static void setTruncateRpcTimeout(java.lang.Long timeOutInMillis)

hasCrossNodeTimeout

public static boolean hasCrossNodeTimeout()

getTimeout

public static long getTimeout(MessagingService.Verb verb)

getMinRpcTimeout

public static long getMinRpcTimeout()
Returns:
the minimum configured {read, write, range, truncate, misc} timeout

getPhiConvictThreshold

public static double getPhiConvictThreshold()

setPhiConvictThreshold

public static void setPhiConvictThreshold(double phiConvictThreshold)

getConcurrentReaders

public static int getConcurrentReaders()

getConcurrentWriters

public static int getConcurrentWriters()

getConcurrentReplicators

public static int getConcurrentReplicators()

getFlushWriters

public static int getFlushWriters()

getInMemoryCompactionLimit

public static int getInMemoryCompactionLimit()

setInMemoryCompactionLimit

public static void setInMemoryCompactionLimit(int sizeInMB)

getConcurrentCompactors

public static int getConcurrentCompactors()

isMultithreadedCompaction

public static boolean isMultithreadedCompaction()

getCompactionThroughputMbPerSec

public static int getCompactionThroughputMbPerSec()

setCompactionThroughputMbPerSec

public static void setCompactionThroughputMbPerSec(int value)

getStreamThroughputOutboundMegabitsPerSec

public static int getStreamThroughputOutboundMegabitsPerSec()

setStreamThroughputOutboundMegabitsPerSec

public static void setStreamThroughputOutboundMegabitsPerSec(int value)

getAllDataFileLocations

public static java.lang.String[] getAllDataFileLocations()

getCommitLogLocation

public static java.lang.String getCommitLogLocation()

getCommitLogSegmentSize

public static int getCommitLogSegmentSize()
size of commitlog segments to allocate


getSavedCachesLocation

public static java.lang.String getSavedCachesLocation()

getSeeds

public static java.util.Set<java.net.InetAddress> getSeeds()

getListenAddress

public static java.net.InetAddress getListenAddress()

getBroadcastAddress

public static java.net.InetAddress getBroadcastAddress()

setBroadcastAddress

public static void setBroadcastAddress(java.net.InetAddress broadcastAdd)

startRpc

public static boolean startRpc()

getRpcAddress

public static java.net.InetAddress getRpcAddress()

getRpcServerType

public static java.lang.String getRpcServerType()

getRpcKeepAlive

public static boolean getRpcKeepAlive()

getRpcMinThreads

public static java.lang.Integer getRpcMinThreads()

getRpcMaxThreads

public static java.lang.Integer getRpcMaxThreads()

getRpcSendBufferSize

public static java.lang.Integer getRpcSendBufferSize()

getRpcRecvBufferSize

public static java.lang.Integer getRpcRecvBufferSize()

getInternodeSendBufferSize

public static java.lang.Integer getInternodeSendBufferSize()

getInternodeRecvBufferSize

public static java.lang.Integer getInternodeRecvBufferSize()

startNativeTransport

public static boolean startNativeTransport()

getNativeTransportAddress

public static java.net.InetAddress getNativeTransportAddress()

getNativeTransportPort

public static int getNativeTransportPort()

getNativeTransportMinThreads

public static java.lang.Integer getNativeTransportMinThreads()

getNativeTransportMaxThreads

public static java.lang.Integer getNativeTransportMaxThreads()

getCommitLogSyncBatchWindow

public static double getCommitLogSyncBatchWindow()

getCommitLogSyncPeriod

public static int getCommitLogSyncPeriod()

getCommitLogSync

public static Config.CommitLogSync getCommitLogSync()

getDiskAccessMode

public static Config.DiskAccessMode getDiskAccessMode()

getIndexAccessMode

public static Config.DiskAccessMode getIndexAccessMode()

setDiskFailurePolicy

public static void setDiskFailurePolicy(Config.DiskFailurePolicy policy)

getDiskFailurePolicy

public static Config.DiskFailurePolicy getDiskFailurePolicy()

isSnapshotBeforeCompaction

public static boolean isSnapshotBeforeCompaction()

isAutoSnapshot

public static boolean isAutoSnapshot()

isAutoBootstrap

public static boolean isAutoBootstrap()

setHintedHandoffEnabled

public static void setHintedHandoffEnabled(boolean hintedHandoffEnabled)

hintedHandoffEnabled

public static boolean hintedHandoffEnabled()

setMaxHintWindow

public static void setMaxHintWindow(int ms)

getMaxHintWindow

public static int getMaxHintWindow()

getIndexInterval

public static java.lang.Integer getIndexInterval()

getSerializedCachePath

public static java.io.File getSerializedCachePath(java.lang.String ksName,
                                                  java.lang.String cfName,
                                                  CacheService.CacheType cacheType,
                                                  java.lang.String version)

getDynamicUpdateInterval

public static int getDynamicUpdateInterval()

setDynamicUpdateInterval

public static void setDynamicUpdateInterval(java.lang.Integer dynamicUpdateInterval)

getDynamicResetInterval

public static int getDynamicResetInterval()

setDynamicResetInterval

public static void setDynamicResetInterval(java.lang.Integer dynamicResetInterval)

getDynamicBadnessThreshold

public static double getDynamicBadnessThreshold()

setDynamicBadnessThreshold

public static void setDynamicBadnessThreshold(java.lang.Double dynamicBadnessThreshold)

getServerEncryptionOptions

public static EncryptionOptions.ServerEncryptionOptions getServerEncryptionOptions()

getClientEncryptionOptions

public static EncryptionOptions.ClientEncryptionOptions getClientEncryptionOptions()

getFlushLargestMemtablesAt

public static double getFlushLargestMemtablesAt()

getReduceCacheSizesAt

public static double getReduceCacheSizesAt()

getReduceCacheCapacityTo

public static double getReduceCacheCapacityTo()

getHintedHandoffThrottleInKB

public static int getHintedHandoffThrottleInKB()

getMaxHintsThread

public static int getMaxHintsThread()

getPreheatKeyCache

public static boolean getPreheatKeyCache()

isIncrementalBackupsEnabled

public static boolean isIncrementalBackupsEnabled()

setIncrementalBackupsEnabled

public static void setIncrementalBackupsEnabled(boolean value)

getFlushQueueSize

public static int getFlushQueueSize()

getTotalMemtableSpaceInMB

public static int getTotalMemtableSpaceInMB()

getTotalCommitlogSpaceInMB

public static long getTotalCommitlogSpaceInMB()

getTrickleFsync

public static boolean getTrickleFsync()

getTrickleFsyncIntervalInKb

public static int getTrickleFsyncIntervalInKb()

getKeyCacheSizeInMB

public static long getKeyCacheSizeInMB()

getKeyCacheSavePeriod

public static int getKeyCacheSavePeriod()

setKeyCacheSavePeriod

public static void setKeyCacheSavePeriod(int keyCacheSavePeriod)

getKeyCacheKeysToSave

public static int getKeyCacheKeysToSave()

getRowCacheSizeInMB

public static long getRowCacheSizeInMB()

getRowCacheSavePeriod

public static int getRowCacheSavePeriod()

setRowCacheSavePeriod

public static void setRowCacheSavePeriod(int rowCacheSavePeriod)

getRowCacheKeysToSave

public static int getRowCacheKeysToSave()

getRowCacheProvider

public static IRowCacheProvider getRowCacheProvider()

getStreamingSocketTimeout

public static int getStreamingSocketTimeout()

getLocalDataCenter

public static java.lang.String getLocalDataCenter()

getLocalComparator

public static java.util.Comparator<java.net.InetAddress> getLocalComparator()

internodeCompression

public static Config.InternodeCompression internodeCompression()

getInterDCTcpNoDelay

public static boolean getInterDCTcpNoDelay()


Copyright © 2013 The Apache Software Foundation