Class SubscriptionInfo
java.lang.Object
org.apache.iotdb.confignode.persistence.subscription.SubscriptionInfo
- All Implemented Interfaces:
SnapshotProcessor
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidalterTopic(AlterTopicPlan plan) booleanvoidcheckBeforeAlterConsumerGroupInternal(ConsumerGroupMeta consumerGroupMeta) createTopic(CreateTopicPlan plan) deepCopyConsumerGroupMeta(String consumerGroupName) deepCopyTopicMeta(String topicName) dropTopic(DropTopicPlan plan) getConsumerGroupMeta(String consumerGroupName) getTopicMeta(String topicName) booleanisConsumerExisted(String consumerGroupName, String consumerId) booleanisConsumerGroupExisted(String consumerGroupName) booleanisTopicExisted(String topicName) booleanisTopicSubscribedByConsumerGroup(String topicName, String consumerGroupId) parseSubscriptionId(String subscriptionId) voidprocessLoadSnapshot(File snapshotDir) booleanprocessTakeSnapshot(File snapshotDir) voidvoidCaller should ensure that the method is called in the lockacquireWriteLock().voidvalidateBeforeAlterConsumerGroup(ConsumerGroupMeta consumerGroupMeta) voidvalidateBeforeAlteringTopic(TopicMeta topicMeta) voidvalidateBeforeCreatingConsumer(TCreateConsumerReq createConsumerReq) booleanvalidateBeforeCreatingTopic(TCreateTopicReq createTopicReq) voidvalidateBeforeDroppingConsumer(TCloseConsumerReq dropConsumerReq) voidvalidateBeforeDroppingTopic(String topicName) voidvalidateBeforeSubscribe(TSubscribeReq subscribeReq) voidvalidateBeforeUnsubscribe(TUnsubscribeReq unsubscribeReq) voidvalidatePipePluginUsageByTopic(String pipePluginName) voidvalidatePipePluginUsageByTopicInternal(String pipePluginName)
-
Constructor Details
-
SubscriptionInfo
public SubscriptionInfo()
-
-
Method Details
-
acquireWriteLock
public void acquireWriteLock() -
releaseWriteLock
public void releaseWriteLock() -
updateLastSyncedVersion
public void updateLastSyncedVersion()Caller should ensure that the method is called in the lockacquireWriteLock(). -
canSkipNextSync
public boolean canSkipNextSync() -
validateBeforeCreatingTopic
public boolean validateBeforeCreatingTopic(TCreateTopicReq createTopicReq) throws SubscriptionException - Throws:
SubscriptionException
-
validateBeforeDroppingTopic
- Throws:
SubscriptionException
-
validatePipePluginUsageByTopic
- Throws:
SubscriptionException
-
validatePipePluginUsageByTopicInternal
public void validatePipePluginUsageByTopicInternal(String pipePluginName) throws SubscriptionException - Throws:
SubscriptionException
-
validateBeforeAlteringTopic
- Throws:
SubscriptionException
-
isTopicExisted
-
getTopicMeta
-
getAllTopicMeta
-
deepCopyTopicMeta
-
showTopics
-
createTopic
-
alterTopic
-
alterMultipleTopics
-
dropTopic
-
handleTopicMetaChanges
-
validateBeforeCreatingConsumer
public void validateBeforeCreatingConsumer(TCreateConsumerReq createConsumerReq) throws SubscriptionException - Throws:
SubscriptionException
-
validateBeforeDroppingConsumer
public void validateBeforeDroppingConsumer(TCloseConsumerReq dropConsumerReq) throws SubscriptionException - Throws:
SubscriptionException
-
validateBeforeAlterConsumerGroup
public void validateBeforeAlterConsumerGroup(ConsumerGroupMeta consumerGroupMeta) throws SubscriptionException - Throws:
SubscriptionException
-
checkBeforeAlterConsumerGroupInternal
public void checkBeforeAlterConsumerGroupInternal(ConsumerGroupMeta consumerGroupMeta) throws SubscriptionException - Throws:
SubscriptionException
-
isConsumerGroupExisted
-
isConsumerExisted
-
getConsumerGroupMeta
-
deepCopyConsumerGroupMeta
-
isTopicSubscribedByConsumerGroup
-
alterConsumerGroup
-
handleConsumerGroupMetaChanges
-
validateBeforeSubscribe
- Throws:
SubscriptionException
-
validateBeforeUnsubscribe
- Throws:
SubscriptionException
-
showSubscriptions
-
getAllConsumerGroupMeta
-
parseSubscriptionId
-
processTakeSnapshot
- Specified by:
processTakeSnapshotin interfaceSnapshotProcessor- Throws:
IOException
-
processLoadSnapshot
- Specified by:
processLoadSnapshotin interfaceSnapshotProcessor- Throws:
IOException
-