Package org.apache.pulsar.broker.service
Class TopicPoliciesService.TopicPoliciesServiceDisabled
java.lang.Object
org.apache.pulsar.broker.service.TopicPoliciesService.TopicPoliciesServiceDisabled
- All Implemented Interfaces:
AutoCloseable,TopicPoliciesService
- Enclosing interface:
- TopicPoliciesService
public static class TopicPoliciesService.TopicPoliciesServiceDisabled
extends Object
implements TopicPoliciesService
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.pulsar.broker.service.TopicPoliciesService
TopicPoliciesService.GetType, TopicPoliciesService.TopicPoliciesServiceDisabled -
Field Summary
Fields inherited from interface org.apache.pulsar.broker.service.TopicPoliciesService
DISABLED -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondeleteTopicPoliciesAsync(org.apache.pulsar.common.naming.TopicName topicName) Delete policies for a topic asynchronously.CompletableFuture<Optional<org.apache.pulsar.common.policies.data.TopicPolicies>>getTopicPoliciesAsync(org.apache.pulsar.common.naming.TopicName topicName, TopicPoliciesService.GetType type) Retrieve the topic policies.booleanregisterListener(org.apache.pulsar.common.naming.TopicName topicName, TopicPolicyListener listener) Registers a listener for topic policies updates.voidunregisterListener(org.apache.pulsar.common.naming.TopicName topicName, TopicPolicyListener listener) Unregister the topic policies listener.updateTopicPoliciesAsync(org.apache.pulsar.common.naming.TopicName topicName, org.apache.pulsar.common.policies.data.TopicPolicies policies) Update policies for a topic asynchronously.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.pulsar.broker.service.TopicPoliciesService
close, start
-
Constructor Details
-
TopicPoliciesServiceDisabled
public TopicPoliciesServiceDisabled()
-
-
Method Details
-
deleteTopicPoliciesAsync
public CompletableFuture<Void> deleteTopicPoliciesAsync(org.apache.pulsar.common.naming.TopicName topicName) Description copied from interface:TopicPoliciesServiceDelete policies for a topic asynchronously.- Specified by:
deleteTopicPoliciesAsyncin interfaceTopicPoliciesService- Parameters:
topicName- topic name
-
updateTopicPoliciesAsync
public CompletableFuture<Void> updateTopicPoliciesAsync(org.apache.pulsar.common.naming.TopicName topicName, org.apache.pulsar.common.policies.data.TopicPolicies policies) Description copied from interface:TopicPoliciesServiceUpdate policies for a topic asynchronously.- Specified by:
updateTopicPoliciesAsyncin interfaceTopicPoliciesService- Parameters:
topicName- topic namepolicies- policies for the topic name
-
getTopicPoliciesAsync
public CompletableFuture<Optional<org.apache.pulsar.common.policies.data.TopicPolicies>> getTopicPoliciesAsync(org.apache.pulsar.common.naming.TopicName topicName, TopicPoliciesService.GetType type) Description copied from interface:TopicPoliciesServiceRetrieve the topic policies.- Specified by:
getTopicPoliciesAsyncin interfaceTopicPoliciesService
-
registerListener
public boolean registerListener(org.apache.pulsar.common.naming.TopicName topicName, TopicPolicyListener listener) Description copied from interface:TopicPoliciesServiceRegisters a listener for topic policies updates.The listener will receive the latest topic policies when they are updated. If the policies are removed, the listener will receive a null value. Note that not every update is guaranteed to trigger the listener. For instance, if the policies change from A -> B -> null -> C in quick succession, only the final state (C) is guaranteed to be received by the listener. In summary, the listener is guaranteed to receive only the latest value.
- Specified by:
registerListenerin interfaceTopicPoliciesService- Returns:
- true if the listener is registered successfully
-
unregisterListener
public void unregisterListener(org.apache.pulsar.common.naming.TopicName topicName, TopicPolicyListener listener) Description copied from interface:TopicPoliciesServiceUnregister the topic policies listener.- Specified by:
unregisterListenerin interfaceTopicPoliciesService
-