Class NodeProbe

java.lang.Object
org.apache.cassandra.tools.NodeProbe
All Implemented Interfaces:
AutoCloseable

public class NodeProbe extends Object implements AutoCloseable
JMX client operations for Cassandra.
  • Field Details

  • Constructor Details

    • NodeProbe

      public NodeProbe(String host, int port, String username, String password) throws IOException
      Creates a NodeProbe using the specified JMX host, port, username, and password.
      Parameters:
      host - hostname or IP address of the JMX agent
      port - TCP port of the remote JMX agent
      Throws:
      IOException - on connection failures
    • NodeProbe

      public NodeProbe(String host, int port) throws IOException
      Creates a NodeProbe using the specified JMX host and port.
      Parameters:
      host - hostname or IP address of the JMX agent
      port - TCP port of the remote JMX agent
      Throws:
      IOException - on connection failures
    • NodeProbe

      public NodeProbe(String host) throws IOException
      Creates a NodeProbe using the specified JMX host and default port.
      Parameters:
      host - hostname or IP address of the JMX agent
      Throws:
      IOException - on connection failures
    • NodeProbe

      protected NodeProbe()
  • Method Details

    • connect

      protected void connect() throws IOException
      Create a connection to the JMX agent and setup the M[X]Bean proxies.
      Throws:
      IOException - on connection failures
    • close

      public void close() throws IOException
      Specified by:
      close in interface AutoCloseable
      Throws:
      IOException
    • setOutput

      public void setOutput(Output output)
    • output

      public Output output()
    • forceKeyspaceCleanup

      public int forceKeyspaceCleanup(int jobs, String keyspaceName, String... tables) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • scrub

      public int scrub(boolean disableSnapshot, boolean skipCorrupted, boolean checkData, boolean reinsertOverflowedTTL, int jobs, String keyspaceName, String... tables) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • verify

      public int verify(boolean extendedVerify, boolean checkVersion, boolean diskFailurePolicy, boolean mutateRepairStatus, boolean checkOwnsTokens, boolean quick, String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • upgradeSSTables

      public int upgradeSSTables(String keyspaceName, boolean excludeCurrentVersion, long maxSSTableTimestamp, int jobs, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • garbageCollect

      public int garbageCollect(String tombstoneOption, int jobs, String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • recompressSSTables

      public int recompressSSTables(String keyspaceName, int jobs, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • forceKeyspaceCleanup

      public void forceKeyspaceCleanup(PrintStream out, int jobs, String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • scrub

      public void scrub(PrintStream out, boolean disableSnapshot, boolean skipCorrupted, boolean checkData, boolean reinsertOverflowedTTL, int jobs, String keyspaceName, String... tables) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • verify

      public void verify(PrintStream out, boolean extendedVerify, boolean checkVersion, boolean diskFailurePolicy, boolean mutateRepairStatus, boolean checkOwnsTokens, boolean quick, String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • recompressSSTables

      public void recompressSSTables(PrintStream out, String keyspaceName, int jobs, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • upgradeSSTables

      public void upgradeSSTables(PrintStream out, String keyspaceName, boolean excludeCurrentVersion, long maxSSTableTimestamp, int jobs, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • garbageCollect

      public void garbageCollect(PrintStream out, String tombstoneOption, int jobs, String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • forceUserDefinedCompaction

      public void forceUserDefinedCompaction(String datafiles) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • forceKeyspaceCompaction

      public void forceKeyspaceCompaction(boolean splitOutput, String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • relocateSSTables

      public void relocateSSTables(int jobs, String keyspace, String[] cfnames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • forceKeyspaceCompactionForTokenRange

      public void forceKeyspaceCompactionForTokenRange(String keyspaceName, String startToken, String endToken, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Forces major compaction of specified token range in a single keyspace.
      Parameters:
      keyspaceName - the name of the keyspace to be compacted
      startToken - the token at which the compaction range starts (inclusive)
      endToken - the token at which compaction range ends (inclusive)
      tableNames - the names of the tables to be compacted
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • forceKeyspaceCompactionForPartitionKey

      public void forceKeyspaceCompactionForPartitionKey(String keyspaceName, String partitionKey, String... tableNames) throws InterruptedException, ExecutionException, IOException
      Throws:
      InterruptedException
      ExecutionException
      IOException
    • forceCompactionKeysIgnoringGcGrace

      public void forceCompactionKeysIgnoringGcGrace(String keyspaceName, String tableName, String... partitionKeysIgnoreGcGrace) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • forceKeyspaceFlush

      public void forceKeyspaceFlush(String keyspaceName, String... tableNames) throws IOException, ExecutionException, InterruptedException
      Throws:
      IOException
      ExecutionException
      InterruptedException
    • getKeyspaceReplicationInfo

      public String getKeyspaceReplicationInfo(String keyspaceName)
    • repairAsync

      public void repairAsync(PrintStream out, String keyspace, Map<String,String> options) throws IOException
      Throws:
      IOException
    • handleScheduledSampling

      public boolean handleScheduledSampling(String ks, String table, int capacity, int count, int durationMillis, int intervalMillis, List<String> samplers, boolean shouldStop) throws OpenDataException
      Throws:
      OpenDataException
    • getSampleTasks

      public List<String> getSampleTasks()
    • getPartitionSample

      public Map<String,List<CompositeData>> getPartitionSample(String ks, int capacity, int durationMillis, int count, List<String> samplers) throws OpenDataException
      Throws:
      OpenDataException
    • getPartitionSample

      public Map<String,List<CompositeData>> getPartitionSample(String ks, String cf, int capacity, int durationMillis, int count, List<String> samplers) throws OpenDataException
      Throws:
      OpenDataException
    • getDroppableTombstoneRatio

      public double getDroppableTombstoneRatio(String keyspace, String table)
    • invalidateCounterCache

      public void invalidateCounterCache()
    • invalidateCredentialsCache

      public void invalidateCredentialsCache()
    • invalidateCredentialsCache

      public void invalidateCredentialsCache(String roleName)
    • invalidateJmxPermissionsCache

      public void invalidateJmxPermissionsCache()
    • invalidateJmxPermissionsCache

      public void invalidateJmxPermissionsCache(String roleName)
    • invalidateKeyCache

      public void invalidateKeyCache()
    • invalidateNetworkPermissionsCache

      public void invalidateNetworkPermissionsCache()
    • invalidateNetworkPermissionsCache

      public void invalidateNetworkPermissionsCache(String roleName)
    • invalidateCidrPermissionsCache

      public boolean invalidateCidrPermissionsCache(String roleName)
    • reloadCidrGroupsCache

      public void reloadCidrGroupsCache()
    • listAvailableCidrGroups

      public Set<String> listAvailableCidrGroups()
    • listCidrsOfCidrGroup

      public Set<String> listCidrsOfCidrGroup(String cidrGroup)
    • updateCidrGroup

      public void updateCidrGroup(String cidrGroupName, List<String> cidrs)
    • dropCidrGroup

      public void dropCidrGroup(String cidrGroupName)
    • getCidrGroupsOfIp

      public Set<String> getCidrGroupsOfIp(String ipStr)
    • invalidatePermissionsCache

      public void invalidatePermissionsCache()
    • invalidatePermissionsCache

      public void invalidatePermissionsCache(String roleName, String resourceName)
    • invalidateRolesCache

      public void invalidateRolesCache()
    • invalidateRolesCache

      public void invalidateRolesCache(String roleName)
    • invalidateRowCache

      public void invalidateRowCache()
    • getAuthCacheMBean

      public AuthCacheMBean getAuthCacheMBean(String cacheName)
    • drain

      public void drain() throws IOException, InterruptedException, ExecutionException
      Throws:
      IOException
      InterruptedException
      ExecutionException
    • getTokenToEndpointMap

      public Map<String,String> getTokenToEndpointMap(boolean withPort)
    • getLiveNodes

      public List<String> getLiveNodes(boolean withPort)
    • getJoiningNodes

      public List<String> getJoiningNodes(boolean withPort)
    • getLeavingNodes

      public List<String> getLeavingNodes(boolean withPort)
    • getMovingNodes

      public List<String> getMovingNodes(boolean withPort)
    • getUnreachableNodes

      public List<String> getUnreachableNodes(boolean withPort)
    • getLoadMap

      public Map<String,String> getLoadMap(boolean withPort)
    • getOwnership

      public Map<InetAddress,Float> getOwnership()
    • getOwnershipWithPort

      public Map<String,Float> getOwnershipWithPort()
    • effectiveOwnership

      public Map<InetAddress,Float> effectiveOwnership(String keyspace) throws IllegalStateException
      Throws:
      IllegalStateException
    • effectiveOwnershipWithPort

      public Map<String,Float> effectiveOwnershipWithPort(String keyspace) throws IllegalStateException
      Throws:
      IllegalStateException
    • getMbeanServerConn

      public MBeanServerConnection getMbeanServerConn()
    • getCacheServiceMBean

      public CacheServiceMBean getCacheServiceMBean()
    • getAndResetGCStats

      public double[] getAndResetGCStats()
    • getColumnFamilyStoreMBeanProxies

      public Iterator<Map.Entry<String,ColumnFamilyStoreMBean>> getColumnFamilyStoreMBeanProxies()
    • getCompactionManagerProxy

      public CompactionManagerMBean getCompactionManagerProxy()
    • getTokens

      public List<String> getTokens()
    • getTokens

      public List<String> getTokens(String endpoint)
    • getHostIdToEndpointWithPort

      public Map<String,String> getHostIdToEndpointWithPort()
    • getLocalHostId

      public String getLocalHostId()
    • getHostIdMap

      public Map<String,String> getHostIdMap(boolean withPort)
    • getLoadString

      public String getLoadString()
    • getUncompressedLoadString

      public String getUncompressedLoadString()
    • getReleaseVersion

      public String getReleaseVersion()
    • getGitSHA

      public String getGitSHA()
    • getCurrentGenerationNumber

      public int getCurrentGenerationNumber()
    • getUptime

      public long getUptime()
    • getHeapMemoryUsage

      public MemoryUsage getHeapMemoryUsage()
    • getSnapshotLinksPerSecond

      public long getSnapshotLinksPerSecond()
    • setSnapshotLinksPerSecond

      public void setSnapshotLinksPerSecond(long throttle)
    • takeSnapshot

      public void takeSnapshot(String snapshotName, String table, Map<String,String> options, String... keyspaces) throws IOException
      Take a snapshot of all the keyspaces, optionally specifying only a specific column family.
      Parameters:
      snapshotName - the name of the snapshot.
      table - the table to snapshot or all on null
      options - Options (skipFlush for now)
      keyspaces - the keyspaces to snapshot
      Throws:
      IOException
    • takeMultipleTableSnapshot

      public void takeMultipleTableSnapshot(String snapshotName, Map<String,String> options, String... tableList) throws IOException
      Take a snapshot of all column family from different keyspaces.
      Parameters:
      snapshotName - the name of the snapshot.
      options - Options (skipFlush for now)
      tableList - list of columnfamily from different keyspace in the form of ks1.cf1 ks2.cf2
      Throws:
      IOException
    • clearSnapshot

      @Deprecated(since="5.0") public void clearSnapshot(String tag, String... keyspaces) throws IOException
      Deprecated.
      See CASSANDRA-16860
      Throws:
      IOException
    • clearSnapshot

      public void clearSnapshot(Map<String,Object> options, String tag, String... keyspaces) throws IOException
      Remove all the existing snapshots of given tag for provided keyspaces. When no keyspaces are specified, take all keyspaces into account. When tag is not specified (null or empty string), take all tags into account.
      Parameters:
      options - options to supply for snapshot clearing
      tag - tag of snapshot to clear
      keyspaces - keyspaces to clear snapshots for
      Throws:
      IOException
    • getSnapshotDetails

      public Map<String,TabularData> getSnapshotDetails(Map<String,String> options)
    • getSnapshotDetails

      @Deprecated(since="4.1") public Map<String,TabularData> getSnapshotDetails()
      Deprecated.
      See CASSANDRA-16789
    • trueSnapshotsSize

      public long trueSnapshotsSize()
    • isJoined

      public boolean isJoined()
    • isDrained

      public boolean isDrained()
    • isDraining

      public boolean isDraining()
    • isBootstrapMode

      public boolean isBootstrapMode()
    • joinRing

      public void joinRing() throws IOException
      Throws:
      IOException
    • decommission

      public void decommission(boolean force) throws InterruptedException
      Throws:
      InterruptedException
    • move

      public void move(String newToken) throws IOException
      Throws:
      IOException
    • removeNode

      public void removeNode(String token)
    • getRemovalStatus

      public String getRemovalStatus(boolean withPort)
    • forceRemoveCompletion

      public void forceRemoveCompletion()
    • assassinateEndpoint

      public void assassinateEndpoint(String address) throws UnknownHostException
      Throws:
      UnknownHostException
    • reloadSeeds

      public List<String> reloadSeeds()
    • getSeeds

      public List<String> getSeeds()
    • setCompactionThreshold

      public void setCompactionThreshold(String ks, String cf, int minimumCompactionThreshold, int maximumCompactionThreshold)
      Set the compaction threshold
      Parameters:
      minimumCompactionThreshold - minimum compaction threshold
      maximumCompactionThreshold - maximum compaction threshold
    • disableAutoCompaction

      public void disableAutoCompaction(String ks, String... tables) throws IOException
      Throws:
      IOException
    • enableAutoCompaction

      public void enableAutoCompaction(String ks, String... tableNames) throws IOException
      Throws:
      IOException
    • getAutoCompactionDisabled

      public Map<String,Boolean> getAutoCompactionDisabled(String ks, String... tableNames) throws IOException
      Throws:
      IOException
    • setIncrementalBackupsEnabled

      public void setIncrementalBackupsEnabled(boolean enabled)
    • isIncrementalBackupsEnabled

      public boolean isIncrementalBackupsEnabled()
    • setCacheCapacities

      public void setCacheCapacities(int keyCacheCapacity, int rowCacheCapacity, int counterCacheCapacity)
    • setCacheKeysToSave

      public void setCacheKeysToSave(int keyCacheKeysToSave, int rowCacheKeysToSave, int counterCacheKeysToSave)
    • setHintedHandoffThrottleInKB

      public void setHintedHandoffThrottleInKB(int throttleInKB)
    • getEndpointsWithPort

      public List<String> getEndpointsWithPort(String keyspace, String cf, String key)
    • getEndpoints

      public List<InetAddress> getEndpoints(String keyspace, String cf, String key)
    • getSSTables

      public List<String> getSSTables(String keyspace, String cf, String key, boolean hexFormat)
    • getSSTablesWithLevel

      public Map<Integer,Set<String>> getSSTablesWithLevel(String keyspace, String cf, String key, boolean hexFormat)
    • isLeveledCompaction

      public boolean isLeveledCompaction(String keyspace, String cf)
    • getStreamStatus

      public Set<StreamState> getStreamStatus()
    • getOperationMode

      public String getOperationMode()
    • isStarting

      public boolean isStarting()
    • truncate

      public void truncate(String keyspaceName, String tableName)
    • getEndpointSnitchInfoProxy

      public EndpointSnitchInfoMBean getEndpointSnitchInfoProxy()
    • getDynamicEndpointSnitchInfoProxy

      public DynamicEndpointSnitchMBean getDynamicEndpointSnitchInfoProxy()
    • getCfsProxy

      public ColumnFamilyStoreMBean getCfsProxy(String ks, String cf)
    • getSpProxy

      public StorageProxyMBean getSpProxy()
    • getStorageService

      public StorageServiceMBean getStorageService()
    • getGossProxy

      public GossiperMBean getGossProxy()
    • getEndpoint

      public String getEndpoint()
    • getDataCenter

      public String getDataCenter()
    • getRack

      public String getRack()
    • getKeyspaces

      public List<String> getKeyspaces()
    • getNonSystemKeyspaces

      public List<String> getNonSystemKeyspaces()
    • getNonLocalStrategyKeyspaces

      public List<String> getNonLocalStrategyKeyspaces()
    • getClusterName

      public String getClusterName()
    • getPartitioner

      public String getPartitioner()
    • disableHintedHandoff

      public void disableHintedHandoff()
    • enableHintedHandoff

      public void enableHintedHandoff()
    • isHandoffEnabled

      public boolean isHandoffEnabled()
    • enableHintsForDC

      public void enableHintsForDC(String dc)
    • disableHintsForDC

      public void disableHintsForDC(String dc)
    • getHintedHandoffDisabledDCs

      public Set<String> getHintedHandoffDisabledDCs()
    • getViewBuildStatuses

      public Map<String,String> getViewBuildStatuses(String keyspace, String view)
    • pauseHintsDelivery

      public void pauseHintsDelivery()
    • resumeHintsDelivery

      public void resumeHintsDelivery()
    • truncateHints

      public void truncateHints(String host)
    • truncateHints

      public void truncateHints()
    • listPendingHints

      public List<Map<String,String>> listPendingHints()
    • refreshSizeEstimates

      public void refreshSizeEstimates()
    • stopNativeTransport

      public void stopNativeTransport(boolean force)
    • startNativeTransport

      public void startNativeTransport()
    • isNativeTransportRunning

      public boolean isNativeTransportRunning()
    • stopGossiping

      public void stopGossiping()
    • startGossiping

      public void startGossiping()
    • isGossipRunning

      public boolean isGossipRunning()
    • stopCassandraDaemon

      public void stopCassandraDaemon()
    • isInitialized

      public boolean isInitialized()
    • setColumnIndexSize

      public void setColumnIndexSize(int columnIndexSizeInKiB)
    • getColumnIndexSizeInKB

      public int getColumnIndexSizeInKB()
    • setCompactionThroughput

      public void setCompactionThroughput(int value)
    • getCompactionThroughput

      @Deprecated(since="4.1") public int getCompactionThroughput()
      Deprecated.
      See CASSANDRA-17225
    • getCompactionThroughputMebibytesAsDouble

      public double getCompactionThroughputMebibytesAsDouble()
    • getCompactionThroughputBytes

      public long getCompactionThroughputBytes()
    • setBatchlogReplayThrottle

      public void setBatchlogReplayThrottle(int value)
    • getBatchlogReplayThrottle

      public int getBatchlogReplayThrottle()
    • setConcurrentCompactors

      public void setConcurrentCompactors(int value)
    • getConcurrentCompactors

      public int getConcurrentCompactors()
    • setConcurrentViewBuilders

      public void setConcurrentViewBuilders(int value)
    • getConcurrentViewBuilders

      public int getConcurrentViewBuilders()
    • setMaxHintWindow

      public void setMaxHintWindow(int value)
    • getMaxHintWindow

      public int getMaxHintWindow()
    • getTimeout

      public long getTimeout(String type)
    • getStreamThroughput

      @Deprecated(since="4.1") public int getStreamThroughput()
      Deprecated.
      See CASSANDRA-17225
    • getStreamThroughputAsDouble

      public double getStreamThroughputAsDouble()
    • getInterDCStreamThroughput

      @Deprecated(since="4.1") public int getInterDCStreamThroughput()
      Deprecated.
      See CASSANDRA-17225
    • getInterDCStreamThroughputAsDouble

      public double getInterDCStreamThroughputAsDouble()
    • getStreamThroughputMibAsDouble

      public double getStreamThroughputMibAsDouble()
    • getInterDCStreamThroughputMibAsDouble

      public double getInterDCStreamThroughputMibAsDouble()
    • getEntireSSTableStreamThroughput

      public double getEntireSSTableStreamThroughput()
    • getEntireSSTableInterDCStreamThroughput

      public double getEntireSSTableInterDCStreamThroughput()
    • getTraceProbability

      public double getTraceProbability()
    • getExceptionCount

      public int getExceptionCount()
    • getDroppedMessages

      public Map<String,Integer> getDroppedMessages()
    • loadNewSSTables

      @Deprecated(since="4.0") public void loadNewSSTables(String ksName, String cfName)
      Deprecated.
      See CASSANDRA-6719
    • importNewSSTables

      public List<String> importNewSSTables(String ksName, String cfName, Set<String> srcPaths, boolean resetLevel, boolean clearRepaired, boolean verifySSTables, boolean verifyTokens, boolean invalidateCaches, boolean extendedVerify, boolean copyData, boolean failOnMissingIndex, boolean validateIndexChecksum)
    • rebuildIndex

      public void rebuildIndex(String ksName, String cfName, String... idxNames)
    • getSimpleStatesWithPort

      public Map<String,String> getSimpleStatesWithPort()
    • getGossipInfo

      public String getGossipInfo(boolean withPort)
    • getGossipInfo

      public String getGossipInfo(boolean withPort, boolean resolveIp)
    • stop

      public void stop(String string)
    • setTimeout

      public void setTimeout(String type, long value)
    • stopById

      public void stopById(String compactionId)
    • setStreamThroughput

      public void setStreamThroughput(int value)
    • setStreamThroughputMiB

      public void setStreamThroughputMiB(int value)
    • setInterDCStreamThroughput

      public void setInterDCStreamThroughput(int value)
    • setInterDCStreamThroughputMiB

      public void setInterDCStreamThroughputMiB(int value)
    • setEntireSSTableStreamThroughput

      public void setEntireSSTableStreamThroughput(int value)
    • setEntireSSTableInterDCStreamThroughput

      public void setEntireSSTableInterDCStreamThroughput(int value)
    • setTraceProbability

      public void setTraceProbability(double value)
    • getSchemaVersion

      public String getSchemaVersion()
    • describeRing

      public List<String> describeRing(String keyspaceName, boolean withPort) throws IOException
      Throws:
      IOException
    • rebuild

      public void rebuild(String sourceDc, String keyspace, String tokens, String specificSources, boolean excludeLocalDatacenterNodes)
    • sampleKeyRange

      public List<String> sampleKeyRange()
    • resetLocalSchema

      public void resetLocalSchema() throws IOException
      Throws:
      IOException
    • reloadLocalSchema

      public void reloadLocalSchema()
    • isFailed

      public boolean isFailed()
    • failed

      public void failed()
    • getReadRepairAttempted

      public long getReadRepairAttempted()
    • getReadRepairRepairedBlocking

      public long getReadRepairRepairedBlocking()
    • getReadRepairRepairedBackground

      public long getReadRepairRepairedBackground()
    • getOutOfRangeOpCounts

      public Map<String,long[]> getOutOfRangeOpCounts()
    • compareGossipAndTokenMetadata

      public Map<String,List<String>> compareGossipAndTokenMetadata()
    • getCacheMetric

      public Object getCacheMetric(String cacheType, String metricName)
      Retrieve cache metrics based on the cache type (KeyCache, RowCache, or CounterCache)
      Parameters:
      cacheType - KeyCach, RowCache, or CounterCache
      metricName - Capacity, Entries, HitRate, Size, Requests or Hits.
    • getBufferPoolMetric

      public Object getBufferPoolMetric(String poolType, String metricName)
      Retrieve buffer pool metrics based on the buffer pool type
      Parameters:
      poolType - networking chunk-cache
      metricName - UsedSize Size
      Returns:
    • getThreadPoolMetric

      public Object getThreadPoolMetric(String pathName, String poolName, String metricName)
    • getSaiMetric

      public Object getSaiMetric(String ks, String cf, String metricName)
    • getThreadPools

      public com.google.common.collect.Multimap<String,String> getThreadPools()
      Retrieve threadpool paths and names for threadpools with metrics.
      Returns:
      Multimap from path (internal, request, etc.) to name
    • getNumberOfTables

      public int getNumberOfTables()
    • getColumnFamilyMetric

      public Object getColumnFamilyMetric(String ks, String cf, String metricName)
      Retrieve ColumnFamily metrics
      Parameters:
      ks - Keyspace for which stats are to be displayed or null for the global value
      cf - ColumnFamily for which stats are to be displayed or null for the keyspace value (if ks supplied)
      metricName - View TableMetrics.
    • getProxyMetric

      public CassandraMetricsRegistry.JmxTimerMBean getProxyMetric(String scope)
      Retrieve Proxy metrics
      Parameters:
      scope - RangeSlice, Read or Write
    • getMessagingQueueWaitMetrics

      public CassandraMetricsRegistry.JmxTimerMBean getMessagingQueueWaitMetrics(String verb)
    • getCompactionMetric

      public Object getCompactionMetric(String metricName)
      Retrieve Proxy metrics
      Parameters:
      metricName - BytesCompacted, CompactionsAborted, CompactionsReduced, SSTablesDroppedFromCompaction, CompletedTasks, PendingTasks, PendingTasksByTableName or TotalCompactionsCompleted.
    • getClientMetric

      public Object getClientMetric(String metricName)
      Retrieve Proxy metrics
      Parameters:
      metricName -
    • getCidrFilteringMetric

      public Object getCidrFilteringMetric(String metricName)
    • getCountsMetricsFromVtable

      public Map<String,Long> getCountsMetricsFromVtable()
    • getLatenciesMetricsFromVtable

      public Map<String,List<Double>> getLatenciesMetricsFromVtable()
    • getStorageMetric

      public long getStorageMetric(String metricName)
      Retrieve Proxy metrics
      Parameters:
      metricName - Exceptions, Load, TotalHints or TotalHintsInProgress.
    • metricPercentilesAsArray

      public Double[] metricPercentilesAsArray(CassandraMetricsRegistry.JmxHistogramMBean metric)
    • metricPercentilesAsArray

      public Double[] metricPercentilesAsArray(CassandraMetricsRegistry.JmxTimerMBean metric)
    • getCompactionHistory

      public TabularData getCompactionHistory()
    • reloadTriggers

      public void reloadTriggers()
    • setLoggingLevel

      public void setLoggingLevel(String classQualifier, String level)
    • getLoggingLevels

      public Map<String,String> getLoggingLevels()
    • getPid

      public long getPid()
    • resumeBootstrap

      public void resumeBootstrap(PrintStream out) throws IOException
      Throws:
      IOException
    • getMaximumPoolSizes

      public Map<String,List<Integer>> getMaximumPoolSizes(List<String> stageNames)
    • setConcurrency

      public void setConcurrency(String stageName, int coreThreads, int maxConcurrency)
    • replayBatchlog

      public void replayBatchlog() throws IOException
      Throws:
      IOException
    • getFailureDetectorPhilValues

      public TabularData getFailureDetectorPhilValues(boolean withPort)
    • getRepairServiceProxy

      public ActiveRepairServiceMBean getRepairServiceProxy()
    • reloadSslCerts

      public void reloadSslCerts() throws IOException
      Throws:
      IOException
    • clearConnectionHistory

      public void clearConnectionHistory()
    • disableAuditLog

      public void disableAuditLog()
    • enableAuditLog

      public void enableAuditLog(String loggerName, Map<String,String> parameters, String includedKeyspaces, String excludedKeyspaces, String includedCategories, String excludedCategories, String includedUsers, String excludedUsers)
    • enableAuditLog

      public void enableAuditLog(String loggerName, String includedKeyspaces, String excludedKeyspaces, String includedCategories, String excludedCategories, String includedUsers, String excludedUsers)
    • enableAuditLog

      public void enableAuditLog(String loggerName, Map<String,String> parameters, String includedKeyspaces, String excludedKeyspaces, String includedCategories, String excludedCategories, String includedUsers, String excludedUsers, Integer maxArchiveRetries, Boolean block, String rollCycle, Long maxLogSize, Integer maxQueueWeight, String archiveCommand)
    • enableOldProtocolVersions

      public void enableOldProtocolVersions()
    • disableOldProtocolVersions

      public void disableOldProtocolVersions()
    • getMessagingServiceProxy

      public MessagingServiceMBean getMessagingServiceProxy()
    • enableFullQueryLogger

      public void enableFullQueryLogger(String path, String rollCycle, Boolean blocking, int maxQueueWeight, long maxLogSize, @Nullable String archiveCommand, int maxArchiveRetries)
    • stopFullQueryLogger

      public void stopFullQueryLogger()
    • resetFullQueryLogger

      public void resetFullQueryLogger()
    • getFullQueryLoggerOptions

      public FullQueryLoggerOptions getFullQueryLoggerOptions()
    • getAuditLogOptions

      public AuditLogOptions getAuditLogOptions()
    • setDefaultKeyspaceReplicationFactor

      public void setDefaultKeyspaceReplicationFactor(int value)
    • getDefaultKeyspaceReplicationFactor

      public int getDefaultKeyspaceReplicationFactor()
    • printSet

      public void printSet(PrintStream out, String colName, Set<String> values)
    • getGuardrailsMBean

      public GuardrailsMBean getGuardrailsMBean()
    • isAutoRepairDisabled

      public boolean isAutoRepairDisabled()
    • autoRepairConfiguration

      public String autoRepairConfiguration()
    • setAutoRepairTokenRangeSplitterParameter

      public void setAutoRepairTokenRangeSplitterParameter(String repairType, String key, String value)
    • setAutoRepairEnabled

      public void setAutoRepairEnabled(String repairType, boolean enabled)
    • setAutoRepairThreads

      public void setAutoRepairThreads(String repairType, int repairThreads)
    • setAutoRepairPriorityForHosts

      public void setAutoRepairPriorityForHosts(String repairType, String commaSeparatedHostSet)
    • setAutoRepairForceRepairForHosts

      public void setAutoRepairForceRepairForHosts(String repairType, String commaSeparatedHostSet)
    • setAutoRepairMinInterval

      public void setAutoRepairMinInterval(String repairType, String minRepairInterval)
    • setAutoRepairHistoryClearDeleteHostsBufferDuration

      public void setAutoRepairHistoryClearDeleteHostsBufferDuration(String duration)
    • startAutoRepairScheduler

      public void startAutoRepairScheduler()
    • setAutoRepairMinRepairTaskDuration

      public void setAutoRepairMinRepairTaskDuration(String duration)
    • setAutoRepairSSTableCountHigherThreshold

      public void setAutoRepairSSTableCountHigherThreshold(String repairType, int ssTableHigherThreshold)
    • setAutoRepairTableMaxRepairTime

      public void setAutoRepairTableMaxRepairTime(String repairType, String autoRepairTableMaxRepairTime)
    • setAutoRepairIgnoreDCs

      public void setAutoRepairIgnoreDCs(String repairType, Set<String> ignoreDCs)
    • setAutoRepairParallelRepairPercentage

      public void setAutoRepairParallelRepairPercentage(String repairType, int percentage)
    • setAutoRepairParallelRepairCount

      public void setAutoRepairParallelRepairCount(String repairType, int count)
    • setAutoRepairAllowParallelReplicaRepair

      public void setAutoRepairAllowParallelReplicaRepair(String repairType, boolean enabled)
    • setAutoRepairAllowParallelReplicaRepairAcrossSchedules

      public void setAutoRepairAllowParallelReplicaRepairAcrossSchedules(String repairType, boolean enabled)
    • setAutoRepairPrimaryTokenRangeOnly

      public void setAutoRepairPrimaryTokenRangeOnly(String repairType, boolean primaryTokenRangeOnly)
    • setAutoRepairMaterializedViewRepairEnabled

      public void setAutoRepairMaterializedViewRepairEnabled(String repairType, boolean enabled)
    • mutateSSTableRepairedState

      public List<String> mutateSSTableRepairedState(boolean repair, boolean preview, String keyspace, List<String> tables)
    • getAutoRepairTablesForKeyspace

      public List<String> getAutoRepairTablesForKeyspace(String keyspace)
    • setAutoRepairSessionTimeout

      public void setAutoRepairSessionTimeout(String repairType, String timeout)
    • getAutoRepairOnGoingRepairHostIds

      public Set<String> getAutoRepairOnGoingRepairHostIds(String repairType)
    • setAutoRepairRepairByKeyspace

      public void setAutoRepairRepairByKeyspace(String repairType, boolean enabled)
    • setAutoRepairMaxRetriesCount

      public void setAutoRepairMaxRetriesCount(String repairType, int retries)
    • setAutoRepairRetryBackoff

      public void setAutoRepairRetryBackoff(String repairType, String interval)
    • setMixedMajorVersionRepairEnabled

      public void setMixedMajorVersionRepairEnabled(boolean enabled)