com.taobao.metamorphosis.server.utils
类 MetaConfig

java.lang.Object
  继承者 com.taobao.metamorphosis.utils.Config
      继承者 com.taobao.metamorphosis.server.utils.MetaConfig
所有已实现的接口:
MetaConfigMBean, Serializable

public class MetaConfig
extends Config
implements Serializable, MetaConfigMBean

服务器端配置

作者:
boyan, wuhua
另请参见:
序列化表格

构造方法摘要
MetaConfig()
           
 
方法摘要
 void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)
           
 void addTopic(String topic, TopicConfig topicConfig)
           
 void closePartitions(String topic, int start, int end)
          关闭分区
 String getAppClassPath()
           
 int getBrokerId()
           
 long getCheckpointInterval()
           
 long getConfigFileChecksum()
           
 String getConfigFilePath()
           
 int getDashboardHttpPort()
           
 String getDataLogPath()
           
 String getDataPath()
           
 String getDeletePolicy()
           
 String getDeleteWhen()
           
 int getFlushTxLogAtCommit()
           
 int getGetProcessThreadCount()
           
 String getHostName()
           
 long getLastModified()
           
 int getMaxCheckpoints()
           
 int getMaxSegmentSize()
           
 int getMaxTransferSize()
           
 int getMaxTxTimeoutInSeconds()
           
 int getMaxTxTimeoutTimerCapacity()
           
 int getNumPartitions()
           
 int getPutProcessThreadCount()
           
 int getQuartzThreadCount()
           
 int getServerPort()
           
 SlaveConfig getSlaveConfig()
           
 int getSlaveId()
           
 TopicConfig getTopicConfig(String topic)
           
 Map<String,TopicConfig> getTopicConfigMap()
           
 List<String> getTopics()
           
 int getUnflushInterval()
           
 int getUnflushThreshold()
           
 ZkUtils.ZKConfig getZkConfig()
           
 boolean isAcceptPublish()
           
 boolean isAcceptSubscribe()
           
 boolean isClosedPartition(String topic, int partition)
           
 boolean isLoadMessageStoresInParallel()
           
 boolean isSlave()
           
 boolean isStat()
           
 boolean isUpdateConsumerOffsets()
           
 void loadFromFile(String path)
           
 void loadFromString(String str)
           
 void openPartitions(String topic)
          打开一个topic的所有分区
protected  void populateAttributes(org.ini4j.Ini conf)
           
 void reload()
          Reload topics configuration
 void removePropertyChangeListener(PropertyChangeListener listener)
           
 void setAcceptPublish(boolean acceptPublish)
           
 void setAcceptSubscribe(boolean acceptSubscribe)
           
 void setAppClassPath(String appClassPath)
           
 void setBrokerId(int brokerId)
           
 void setCheckpointInterval(long checkpointInterval)
           
 void setConfigFileChecksum(long configFileChecksum)
           
 void setDashboardHttpPort(int dashboardHttpPort)
           
 void setDataLogPath(String dataLogPath)
           
 void setDataPath(String dataPath)
           
 void setDeletePolicy(String deletePolicy)
           
 void setDeleteWhen(String deleteWhen)
           
 void setFlushTxLogAtCommit(int flushTxLogAtCommit)
           
 void setGetProcessThreadCount(int getProcessThreadCount)
           
 void setHostName(String hostName)
           
 void setLoadMessageStoresInParallel(boolean loadMessageStoresInParallel)
           
 void setMaxCheckpoints(int maxCheckpoints)
           
 void setMaxSegmentSize(int maxSegmentSize)
           
 void setMaxTransferSize(int maxTransferSize)
           
 void setMaxTxTimeoutInSeconds(int maxTxTimeoutInSeconds)
           
 void setMaxTxTimeoutTimerCapacity(int maxTxTimeoutTimerCapacity)
           
 void setNumPartitions(int numPartitions)
           
 void setPutProcessThreadCount(int putProcessThreadCount)
           
 void setQuartzThreadCount(int quartzThreadCount)
           
 void setServerPort(int serverPort)
           
 void setSlaveConfig(SlaveConfig slaveConfig)
           
 void setStat(boolean stat)
           
 void setTopics(List<String> topics)
           
 void setUnflushInterval(int unflushInterval)
           
 void setUnflushThreshold(int storeFlushThreshold)
           
 void setUpdateConsumerOffsets(boolean updateConsumerOffsets)
           
 void setZkConfig(ZkUtils.ZKConfig zkConfig)
           
 String toString()
           
 void verify()
          校验配置是否正确
 
从类 com.taobao.metamorphosis.utils.Config 继承的方法
checkConfigKeys, findBestMatchField, getFieldSet
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

构造方法详细信息

MetaConfig

public MetaConfig()
方法详细信息

getDashboardHttpPort

public int getDashboardHttpPort()

setDashboardHttpPort

public void setDashboardHttpPort(int dashboardHttpPort)

isLoadMessageStoresInParallel

public boolean isLoadMessageStoresInParallel()

setLoadMessageStoresInParallel

public void setLoadMessageStoresInParallel(boolean loadMessageStoresInParallel)

getQuartzThreadCount

public int getQuartzThreadCount()

isAcceptPublish

public boolean isAcceptPublish()

isUpdateConsumerOffsets

public boolean isUpdateConsumerOffsets()

setUpdateConsumerOffsets

public void setUpdateConsumerOffsets(boolean updateConsumerOffsets)

isStat

public boolean isStat()

setStat

public void setStat(boolean stat)

setAcceptPublish

public void setAcceptPublish(boolean acceptPublish)

isAcceptSubscribe

public boolean isAcceptSubscribe()

setAcceptSubscribe

public void setAcceptSubscribe(boolean acceptSubscribe)

getSlaveConfig

public SlaveConfig getSlaveConfig()

getSlaveId

public int getSlaveId()

getConfigFilePath

public String getConfigFilePath()

setSlaveConfig

public void setSlaveConfig(SlaveConfig slaveConfig)

setQuartzThreadCount

public void setQuartzThreadCount(int quartzThreadCount)

getMaxTxTimeoutTimerCapacity

public int getMaxTxTimeoutTimerCapacity()

getDeleteWhen

public String getDeleteWhen()

setDeleteWhen

public void setDeleteWhen(String deleteWhen)

setMaxTxTimeoutTimerCapacity

public void setMaxTxTimeoutTimerCapacity(int maxTxTimeoutTimerCapacity)

getMaxTxTimeoutInSeconds

public int getMaxTxTimeoutInSeconds()

setMaxTxTimeoutInSeconds

public void setMaxTxTimeoutInSeconds(int maxTxTimeoutInSeconds)

getFlushTxLogAtCommit

public int getFlushTxLogAtCommit()

setFlushTxLogAtCommit

public void setFlushTxLogAtCommit(int flushTxLogAtCommit)

getMaxCheckpoints

public int getMaxCheckpoints()

getCheckpointInterval

public long getCheckpointInterval()

setCheckpointInterval

public void setCheckpointInterval(long checkpointInterval)

setMaxCheckpoints

public void setMaxCheckpoints(int maxCheckpoints)

getLastModified

public long getLastModified()

addPropertyChangeListener

public void addPropertyChangeListener(String propertyName,
                                      PropertyChangeListener listener)

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener listener)

loadFromFile

public void loadFromFile(String path)

loadFromString

public void loadFromString(String str)

getConfigFileChecksum

public long getConfigFileChecksum()

setConfigFileChecksum

public void setConfigFileChecksum(long configFileChecksum)

getDeletePolicy

public String getDeletePolicy()

setDeletePolicy

public void setDeletePolicy(String deletePolicy)

getZkConfig

public ZkUtils.ZKConfig getZkConfig()

getTopics

public List<String> getTopics()

setTopics

public void setTopics(List<String> topics)

setZkConfig

public void setZkConfig(ZkUtils.ZKConfig zkConfig)

getNumPartitions

public int getNumPartitions()

setNumPartitions

public void setNumPartitions(int numPartitions)

getBrokerId

public int getBrokerId()

setBrokerId

public void setBrokerId(int brokerId)

getHostName

public String getHostName()

setHostName

public void setHostName(String hostName)

populateAttributes

protected void populateAttributes(org.ini4j.Ini conf)

addTopic

public void addTopic(String topic,
                     TopicConfig topicConfig)

reload

public void reload()
Reload topics configuration

指定者:
接口 MetaConfigMBean 中的 reload

getAppClassPath

public String getAppClassPath()

setAppClassPath

public void setAppClassPath(String appClassPath)

getGetProcessThreadCount

public int getGetProcessThreadCount()

setGetProcessThreadCount

public void setGetProcessThreadCount(int getProcessThreadCount)

getPutProcessThreadCount

public int getPutProcessThreadCount()

setPutProcessThreadCount

public void setPutProcessThreadCount(int putProcessThreadCount)

getServerPort

public int getServerPort()

setUnflushInterval

public void setUnflushInterval(int unflushInterval)

getMaxTransferSize

public int getMaxTransferSize()

setMaxTransferSize

public void setMaxTransferSize(int maxTransferSize)

setMaxSegmentSize

public void setMaxSegmentSize(int maxSegmentSize)

getUnflushInterval

public int getUnflushInterval()

getMaxSegmentSize

public int getMaxSegmentSize()

setUnflushThreshold

public void setUnflushThreshold(int storeFlushThreshold)

getUnflushThreshold

public int getUnflushThreshold()

toString

public String toString()
覆盖:
Object 中的 toString

setServerPort

public void setServerPort(int serverPort)

verify

public void verify()
校验配置是否正确


setDataPath

public void setDataPath(String dataPath)

getDataPath

public String getDataPath()

getDataLogPath

public String getDataLogPath()

setDataLogPath

public void setDataLogPath(String dataLogPath)

isSlave

public boolean isSlave()

closePartitions

public void closePartitions(String topic,
                            int start,
                            int end)
从接口 MetaConfigMBean 复制的描述
关闭分区

指定者:
接口 MetaConfigMBean 中的 closePartitions

isClosedPartition

public boolean isClosedPartition(String topic,
                                 int partition)

openPartitions

public void openPartitions(String topic)
从接口 MetaConfigMBean 复制的描述
打开一个topic的所有分区

指定者:
接口 MetaConfigMBean 中的 openPartitions

getTopicConfig

public final TopicConfig getTopicConfig(String topic)

getTopicConfigMap

public Map<String,TopicConfig> getTopicConfigMap()


Copyright © 2010–2013. All rights reserved.