public interface Topics
| Modifier and Type | Method and Description |
|---|---|
LongRunningProcessStatus |
compactionStatus(String topic)
Check the status of an ongoing compaction for a topic.
|
CompletableFuture<LongRunningProcessStatus> |
compactionStatusAsync(String topic)
Check the status of an ongoing compaction for a topic asynchronously.
|
void |
createMissedPartitions(String topic)
Create missed partitions for partitioned topic.
|
CompletableFuture<Void> |
createMissedPartitionsAsync(String topic)
Create missed partitions for partitioned topic asynchronously.
|
void |
createNonPartitionedTopic(String topic)
Create a non-partitioned topic.
|
CompletableFuture<Void> |
createNonPartitionedTopicAsync(String topic)
Create a non-partitioned topic asynchronously.
|
void |
createPartitionedTopic(String topic,
int numPartitions)
Create a partitioned topic.
|
CompletableFuture<Void> |
createPartitionedTopicAsync(String topic,
int numPartitions)
Create a partitioned topic asynchronously.
|
void |
createSubscription(String topic,
String subscriptionName,
org.apache.pulsar.client.api.MessageId messageId)
Create a new subscription on a topic.
|
CompletableFuture<Void> |
createSubscriptionAsync(String topic,
String subscriptionName,
org.apache.pulsar.client.api.MessageId messageId)
Create a new subscription on a topic.
|
void |
delete(String topic)
Delete a topic.
|
default void |
delete(String topic,
boolean force) |
void |
delete(String topic,
boolean force,
boolean deleteSchema)
Delete a topic.
|
CompletableFuture<Void> |
deleteAsync(String topic)
Delete a topic asynchronously.
|
default CompletableFuture<Void> |
deleteAsync(String topic,
boolean force) |
CompletableFuture<Void> |
deleteAsync(String topic,
boolean force,
boolean deleteSchema)
Delete a topic asynchronously.
|
void |
deletePartitionedTopic(String topic)
Delete a partitioned topic.
|
default void |
deletePartitionedTopic(String topic,
boolean force) |
void |
deletePartitionedTopic(String topic,
boolean force,
boolean deleteSchema)
Delete a partitioned topic.
|
CompletableFuture<Void> |
deletePartitionedTopicAsync(String topic)
Delete a partitioned topic asynchronously.
|
default CompletableFuture<Void> |
deletePartitionedTopicAsync(String topic,
boolean force) |
CompletableFuture<Void> |
deletePartitionedTopicAsync(String topic,
boolean force,
boolean deleteSchema)
Delete a partitioned topic asynchronously.
|
void |
deleteSubscription(String topic,
String subName)
Delete a subscription.
|
void |
deleteSubscription(String topic,
String subName,
boolean force)
Delete a subscription.
|
CompletableFuture<Void> |
deleteSubscriptionAsync(String topic,
String subName)
Delete a subscription asynchronously.
|
CompletableFuture<Void> |
deleteSubscriptionAsync(String topic,
String subName,
boolean force)
Delete a subscription asynchronously.
|
void |
disableDeduplication(String topic)
Deprecated.
|
CompletableFuture<Void> |
disableDeduplicationAsync(String topic)
Deprecated.
|
void |
enableDeduplication(String topic,
boolean enabled)
Deprecated.
|
CompletableFuture<Void> |
enableDeduplicationAsync(String topic,
boolean enabled)
Deprecated.
|
org.apache.pulsar.client.api.Message<byte[]> |
examineMessage(String topic,
String initialPosition,
long messagePosition)
Examine a specific message on a topic by position relative to the earliest or the latest message.
|
CompletableFuture<org.apache.pulsar.client.api.Message<byte[]>> |
examineMessageAsync(String topic,
String initialPosition,
long messagePosition)
Examine a specific message on a topic by position relative to the earliest or the latest message.
|
void |
expireMessages(String topic,
String subscriptionName,
long expireTimeInSeconds)
Expire all messages older than given N (expireTimeInSeconds) seconds for a given subscription.
|
void |
expireMessages(String topic,
String subscriptionName,
org.apache.pulsar.client.api.MessageId messageId,
boolean isExcluded)
Expire all messages older than given N (expireTimeInSeconds) seconds for a given subscription.
|
CompletableFuture<Void> |
expireMessagesAsync(String topic,
String subscriptionName,
long expireTimeInSeconds)
Expire all messages older than given N (expireTimeInSeconds) seconds for a given subscription asynchronously.
|
CompletableFuture<Void> |
expireMessagesAsync(String topic,
String subscriptionName,
org.apache.pulsar.client.api.MessageId messageId,
boolean isExcluded)
Expire all messages older than given N (expireTimeInSeconds) seconds for a given subscription asynchronously.
|
void |
expireMessagesForAllSubscriptions(String topic,
long expireTimeInSeconds)
Expire all messages older than given N seconds for all subscriptions of the persistent-topic.
|
CompletableFuture<Void> |
expireMessagesForAllSubscriptionsAsync(String topic,
long expireTimeInSeconds)
Expire all messages older than given N seconds for all subscriptions of the persistent-topic asynchronously.
|
Map<BacklogQuota.BacklogQuotaType,BacklogQuota> |
getBacklogQuotaMap(String topic)
Get backlog quota map for a topic.
|
Map<BacklogQuota.BacklogQuotaType,BacklogQuota> |
getBacklogQuotaMap(String topic,
boolean applied)
Get applied backlog quota map for a topic.
|
Long |
getCompactionThreshold(String topic)
Get the compactionThreshold for a topic.
|
Long |
getCompactionThreshold(String topic,
boolean applied)
Get the compactionThreshold for a topic.
|
CompletableFuture<Long> |
getCompactionThresholdAsync(String topic)
Get the compactionThreshold for a topic asynchronously.
|
CompletableFuture<Long> |
getCompactionThresholdAsync(String topic,
boolean applied)
Get the compactionThreshold for a topic asynchronously.
|
Boolean |
getDeduplicationEnabled(String topic)
Deprecated.
|
CompletableFuture<Boolean> |
getDeduplicationEnabledAsync(String topic)
Deprecated.
|
Integer |
getDeduplicationSnapshotInterval(String topic)
Get the deduplication snapshot interval for specified topic.
|
CompletableFuture<Integer> |
getDeduplicationSnapshotIntervalAsync(String topic)
Get the deduplication snapshot interval for specified topic asynchronously.
|
Boolean |
getDeduplicationStatus(String topic)
get deduplication enabled of a topic.
|
Boolean |
getDeduplicationStatus(String topic,
boolean applied)
get applied deduplication enabled of a topic.
|
CompletableFuture<Boolean> |
getDeduplicationStatusAsync(String topic)
get deduplication enabled of a topic asynchronously.
|
CompletableFuture<Boolean> |
getDeduplicationStatusAsync(String topic,
boolean applied)
get applied deduplication enabled of a topic asynchronously.
|
DelayedDeliveryPolicies |
getDelayedDeliveryPolicy(String topic)
Get the delayed delivery policy for a specified topic.
|
DelayedDeliveryPolicies |
getDelayedDeliveryPolicy(String topic,
boolean applied)
Get the delayed delivery policy applied for a specified topic.
|
CompletableFuture<DelayedDeliveryPolicies> |
getDelayedDeliveryPolicyAsync(String topic)
Get the delayed delivery policy for a specified topic asynchronously.
|
CompletableFuture<DelayedDeliveryPolicies> |
getDelayedDeliveryPolicyAsync(String topic,
boolean applied)
Get the delayed delivery policy applied for a specified topic asynchronously.
|
DispatchRate |
getDispatchRate(String topic)
Get message-dispatch-rate (topic can dispatch this many messages per second).
|
DispatchRate |
getDispatchRate(String topic,
boolean applied)
Get applied message-dispatch-rate (topic can dispatch this many messages per second).
|
CompletableFuture<DispatchRate> |
getDispatchRateAsync(String topic)
Get message-dispatch-rate asynchronously.
|
CompletableFuture<DispatchRate> |
getDispatchRateAsync(String topic,
boolean applied)
Get applied message-dispatch-rate asynchronously.
|
InactiveTopicPolicies |
getInactiveTopicPolicies(String topic)
get inactive topic policies of a topic.
|
InactiveTopicPolicies |
getInactiveTopicPolicies(String topic,
boolean applied)
Get inactive topic policies applied for a topic.
|
CompletableFuture<InactiveTopicPolicies> |
getInactiveTopicPoliciesAsync(String topic)
get inactive topic policies of a topic asynchronously.
|
CompletableFuture<InactiveTopicPolicies> |
getInactiveTopicPoliciesAsync(String topic,
boolean applied)
Get inactive topic policies applied for a topic asynchronously.
|
com.google.gson.JsonObject |
getInternalInfo(String topic)
Get a JSON representation of the topic metadata stored in ZooKeeper.
|
CompletableFuture<com.google.gson.JsonObject> |
getInternalInfoAsync(String topic)
Get a JSON representation of the topic metadata stored in ZooKeeper.
|
PersistentTopicInternalStats |
getInternalStats(String topic)
Get the internal stats for the topic.
|
PersistentTopicInternalStats |
getInternalStats(String topic,
boolean metadata)
Get the internal stats for the topic.
|
CompletableFuture<PersistentTopicInternalStats> |
getInternalStatsAsync(String topic)
Get the internal stats for the topic asynchronously.
|
CompletableFuture<PersistentTopicInternalStats> |
getInternalStatsAsync(String topic,
boolean metadata)
Get the internal stats for the topic asynchronously.
|
org.apache.pulsar.client.api.MessageId |
getLastMessageId(String topic)
Get the last commit message Id of a topic.
|
CompletableFuture<org.apache.pulsar.client.api.MessageId> |
getLastMessageIdAsync(String topic)
Get the last commit message Id of a topic asynchronously.
|
List<String> |
getList(String namespace)
Get the both persistent and non-persistent topics under a namespace.
|
List<String> |
getList(String namespace,
TopicDomain topicDomain)
Get the list of topics under a namespace.
|
CompletableFuture<List<String>> |
getListAsync(String namespace)
Get both persistent and non-persistent topics under a namespace asynchronously.
|
CompletableFuture<List<String>> |
getListAsync(String namespace,
TopicDomain topicDomain)
Get the list of topics under a namespace asynchronously.
|
List<String> |
getListInBundle(String namespace,
String bundleRange)
Get list of topics exist into given bundle.
|
CompletableFuture<List<String>> |
getListInBundleAsync(String namespace,
String bundleRange)
Get list of topics exist into given bundle asynchronously.
|
Integer |
getMaxConsumers(String topic)
Get the max number of consumer for specified topic.
|
Integer |
getMaxConsumers(String topic,
boolean applied)
Get the max number of consumer applied for specified topic.
|
CompletableFuture<Integer> |
getMaxConsumersAsync(String topic)
Get the max number of consumer for specified topic asynchronously.
|
CompletableFuture<Integer> |
getMaxConsumersAsync(String topic,
boolean applied)
Get the max number of consumer applied for specified topic asynchronously.
|
Integer |
getMaxConsumersPerSubscription(String topic)
Get the maxConsumersPerSubscription for a topic.
|
CompletableFuture<Integer> |
getMaxConsumersPerSubscriptionAsync(String topic)
Get the maxConsumersPerSubscription for a topic asynchronously.
|
Integer |
getMaxMessageSize(String topic)
Get the max message size for specified topic.
|
CompletableFuture<Integer> |
getMaxMessageSizeAsync(String topic)
Get the max message size for specified topic asynchronously.
|
Integer |
getMaxProducers(String topic)
Get the max number of producer for specified topic.
|
Integer |
getMaxProducers(String topic,
boolean applied)
Get the max number of producer applied for specified topic.
|
CompletableFuture<Integer> |
getMaxProducersAsync(String topic)
Get the max number of producer for specified topic asynchronously.
|
CompletableFuture<Integer> |
getMaxProducersAsync(String topic,
boolean applied)
Get the max number of producer applied for specified topic asynchronously.
|
Integer |
getMaxSubscriptionsPerTopic(String topic)
Get the max number of subscriptions for specified topic.
|
CompletableFuture<Integer> |
getMaxSubscriptionsPerTopicAsync(String topic)
Get the max number of subscriptions for specified topic asynchronously.
|
Integer |
getMaxUnackedMessagesOnConsumer(String topic)
get max unacked messages on consumer of a topic.
|
Integer |
getMaxUnackedMessagesOnConsumer(String topic,
boolean applied)
get applied max unacked messages on consumer of a topic.
|
CompletableFuture<Integer> |
getMaxUnackedMessagesOnConsumerAsync(String topic)
get max unacked messages on consumer of a topic asynchronously.
|
CompletableFuture<Integer> |
getMaxUnackedMessagesOnConsumerAsync(String topic,
boolean applied)
get applied max unacked messages on consumer of a topic asynchronously.
|
Integer |
getMaxUnackedMessagesOnSubscription(String topic)
get max unacked messages on subscription of a topic.
|
Integer |
getMaxUnackedMessagesOnSubscription(String topic,
boolean applied)
get max unacked messages on subscription of a topic.
|
CompletableFuture<Integer> |
getMaxUnackedMessagesOnSubscriptionAsync(String topic)
get max unacked messages on subscription of a topic asynchronously.
|
CompletableFuture<Integer> |
getMaxUnackedMessagesOnSubscriptionAsync(String topic,
boolean applied)
get max unacked messages on subscription of a topic asynchronously.
|
org.apache.pulsar.client.api.Message<byte[]> |
getMessageById(String topic,
long ledgerId,
long entryId)
Get a message by its messageId via a topic subscription.
|
CompletableFuture<org.apache.pulsar.client.api.Message<byte[]>> |
getMessageByIdAsync(String topic,
long ledgerId,
long entryId)
Get a message by its messageId via a topic subscription asynchronously.
|
Integer |
getMessageTTL(String topic)
Get message TTL for a topic.
|
Integer |
getMessageTTL(String topic,
boolean applied)
Get message TTL applied for a topic.
|
OffloadPolicies |
getOffloadPolicies(String topic)
get offload policies of a topic.
|
OffloadPolicies |
getOffloadPolicies(String topic,
boolean applied)
get applied offload policies of a topic.
|
CompletableFuture<OffloadPolicies> |
getOffloadPoliciesAsync(String topic)
get offload policies of a topic asynchronously.
|
CompletableFuture<OffloadPolicies> |
getOffloadPoliciesAsync(String topic,
boolean applied)
get applied offload policies of a topic asynchronously.
|
PartitionedTopicInternalStats |
getPartitionedInternalStats(String topic)
Get the stats for the partitioned topic.
|
CompletableFuture<PartitionedTopicInternalStats> |
getPartitionedInternalStatsAsync(String topic)
Get the stats-internal for the partitioned topic asynchronously.
|
default PartitionedTopicStats |
getPartitionedStats(String topic,
boolean perPartition) |
PartitionedTopicStats |
getPartitionedStats(String topic,
boolean perPartition,
boolean getPreciseBacklog,
boolean subscriptionBacklogSize)
Get the stats for the partitioned topic
Response Example:
|
default CompletableFuture<PartitionedTopicStats> |
getPartitionedStatsAsync(String topic,
boolean perPartition) |
CompletableFuture<PartitionedTopicStats> |
getPartitionedStatsAsync(String topic,
boolean perPartition,
boolean getPreciseBacklog,
boolean subscriptionBacklogSize)
Get the stats for the partitioned topic asynchronously.
|
List<String> |
getPartitionedTopicList(String namespace)
Get the list of partitioned topics under a namespace.
|
CompletableFuture<List<String>> |
getPartitionedTopicListAsync(String namespace)
Get the list of partitioned topics under a namespace asynchronously.
|
PartitionedTopicMetadata |
getPartitionedTopicMetadata(String topic)
Get metadata of a partitioned topic.
|
CompletableFuture<PartitionedTopicMetadata> |
getPartitionedTopicMetadataAsync(String topic)
Get metadata of a partitioned topic asynchronously.
|
Map<String,Set<AuthAction>> |
getPermissions(String topic)
Get permissions on a topic.
|
CompletableFuture<Map<String,Set<AuthAction>>> |
getPermissionsAsync(String topic)
Get permissions on a topic asynchronously.
|
PersistencePolicies |
getPersistence(String topic)
Get the configuration of persistence policies for specified topic.
|
PersistencePolicies |
getPersistence(String topic,
boolean applied)
Get the applied configuration of persistence policies for specified topic.
|
CompletableFuture<PersistencePolicies> |
getPersistenceAsync(String topic)
Get the configuration of persistence policies for specified topic asynchronously.
|
CompletableFuture<PersistencePolicies> |
getPersistenceAsync(String topic,
boolean applied)
Get the applied configuration of persistence policies for specified topic asynchronously.
|
PublishRate |
getPublishRate(String topic)
Get message-publish-rate (topics can publish this many messages per second).
|
CompletableFuture<PublishRate> |
getPublishRateAsync(String topic)
Get message-publish-rate (topics can publish this many messages per second) asynchronously.
|
DispatchRate |
getReplicatorDispatchRate(String topic)
Get replicatorDispatchRate for the topic.
|
DispatchRate |
getReplicatorDispatchRate(String topic,
boolean applied)
Get applied replicatorDispatchRate for the topic.
|
CompletableFuture<DispatchRate> |
getReplicatorDispatchRateAsync(String topic)
Get replicatorDispatchRate asynchronously.
|
CompletableFuture<DispatchRate> |
getReplicatorDispatchRateAsync(String topic,
boolean applied)
Get applied replicatorDispatchRate asynchronously.
|
RetentionPolicies |
getRetention(String topic)
Get the retention configuration for a topic.
|
RetentionPolicies |
getRetention(String topic,
boolean applied)
Get the applied retention configuration for a topic.
|
CompletableFuture<RetentionPolicies> |
getRetentionAsync(String topic)
Get the retention configuration for a topic asynchronously.
|
CompletableFuture<RetentionPolicies> |
getRetentionAsync(String topic,
boolean applied)
Get the applied retention configuration for a topic asynchronously.
|
default TopicStats |
getStats(String topic) |
default TopicStats |
getStats(String topic,
boolean getPreciseBacklog) |
TopicStats |
getStats(String topic,
boolean getPreciseBacklog,
boolean subscriptionBacklogSize)
Get the stats for the topic.
|
default CompletableFuture<TopicStats> |
getStatsAsync(String topic) |
CompletableFuture<TopicStats> |
getStatsAsync(String topic,
boolean getPreciseBacklog,
boolean subscriptionBacklogSize)
Get the stats for the topic asynchronously.
|
SubscribeRate |
getSubscribeRate(String topic)
Get topic-subscribe-rate (topics allow subscribe times per consumer in a period).
|
SubscribeRate |
getSubscribeRate(String topic,
boolean applied)
Get applied topic-subscribe-rate (topics allow subscribe times per consumer in a period).
|
CompletableFuture<SubscribeRate> |
getSubscribeRateAsync(String topic)
Get topic-subscribe-rate asynchronously.
|
CompletableFuture<SubscribeRate> |
getSubscribeRateAsync(String topic,
boolean applied)
Get applied topic-subscribe-rate asynchronously.
|
DispatchRate |
getSubscriptionDispatchRate(String topic)
Get subscription-message-dispatch-rate for the topic.
|
DispatchRate |
getSubscriptionDispatchRate(String namespace,
boolean applied)
Get applied subscription-message-dispatch-rate.
|
CompletableFuture<DispatchRate> |
getSubscriptionDispatchRateAsync(String topic)
Get subscription-message-dispatch-rate asynchronously.
|
CompletableFuture<DispatchRate> |
getSubscriptionDispatchRateAsync(String namespace,
boolean applied)
Get applied subscription-message-dispatch-rate asynchronously.
|
List<String> |
getSubscriptions(String topic)
Get the list of subscriptions.
|
CompletableFuture<List<String>> |
getSubscriptionsAsync(String topic)
Get the list of subscriptions asynchronously.
|
Set<org.apache.pulsar.client.api.SubscriptionType> |
getSubscriptionTypesEnabled(String topic)
Get is enable sub types.
|
CompletableFuture<Set<org.apache.pulsar.client.api.SubscriptionType>> |
getSubscriptionTypesEnabledAsync(String topic)
Get is enable sub types asynchronously.
|
void |
grantPermission(String topic,
String role,
Set<AuthAction> actions)
Grant permission on a topic.
|
CompletableFuture<Void> |
grantPermissionAsync(String topic,
String role,
Set<AuthAction> actions)
Grant permission on a topic asynchronously.
|
OffloadProcessStatus |
offloadStatus(String topic)
Check the status of an ongoing offloading operation for a topic.
|
CompletableFuture<OffloadProcessStatus> |
offloadStatusAsync(String topic)
Check the status of an ongoing offloading operation for a topic asynchronously.
|
List<org.apache.pulsar.client.api.Message<byte[]>> |
peekMessages(String topic,
String subName,
int numMessages)
Peek messages from a topic subscription.
|
CompletableFuture<List<org.apache.pulsar.client.api.Message<byte[]>>> |
peekMessagesAsync(String topic,
String subName,
int numMessages)
Peek messages from a topic subscription asynchronously.
|
void |
removeBacklogQuota(String topic)
Remove a backlog quota policy from a topic.
|
void |
removeCompactionThreshold(String topic)
Remove the compactionThreshold for a topic.
|
CompletableFuture<Void> |
removeCompactionThresholdAsync(String topic)
Remove the compactionThreshold for a topic asynchronously.
|
void |
removeDeduplicationSnapshotInterval(String topic)
Remove the deduplication snapshot interval for specified topic.
|
CompletableFuture<Void> |
removeDeduplicationSnapshotIntervalAsync(String topic)
Remove the deduplication snapshot interval for specified topic asynchronously.
|
void |
removeDeduplicationStatus(String topic)
remove deduplication enabled of a topic.
|
CompletableFuture<Void> |
removeDeduplicationStatusAsync(String topic)
remove deduplication enabled of a topic asynchronously.
|
void |
removeDelayedDeliveryPolicy(String topic)
Remove the delayed delivery policy for a specified topic.
|
CompletableFuture<Void> |
removeDelayedDeliveryPolicyAsync(String topic)
Remove the delayed delivery policy for a specified topic asynchronously.
|
void |
removeDispatchRate(String topic)
Remove message-dispatch-rate.
|
CompletableFuture<Void> |
removeDispatchRateAsync(String topic)
Remove message-dispatch-rate asynchronously.
|
void |
removeInactiveTopicPolicies(String topic)
remove inactive topic policies of a topic.
|
CompletableFuture<Void> |
removeInactiveTopicPoliciesAsync(String topic)
remove inactive topic policies of a topic asynchronously.
|
void |
removeMaxConsumers(String topic)
Remove the max number of consumer for specified topic.
|
CompletableFuture<Void> |
removeMaxConsumersAsync(String topic)
Remove the max number of consumer for specified topic asynchronously.
|
void |
removeMaxConsumersPerSubscription(String topic)
Remove the maxConsumersPerSubscription for a topic.
|
CompletableFuture<Void> |
removeMaxConsumersPerSubscriptionAsync(String topic)
Remove the maxConsumersPerSubscription for a topic asynchronously.
|
void |
removeMaxMessageSize(String topic)
Remove the max message size for specified topic.
|
CompletableFuture<Void> |
removeMaxMessageSizeAsync(String topic)
Remove the max message size for specified topic asynchronously.
|
void |
removeMaxProducers(String topic)
Remove the max number of producer for specified topic.
|
CompletableFuture<Void> |
removeMaxProducersAsync(String topic)
Remove the max number of producer for specified topic asynchronously.
|
void |
removeMaxSubscriptionsPerTopic(String topic)
Remove the max number of subscriptions for specified topic.
|
CompletableFuture<Void> |
removeMaxSubscriptionsPerTopicAsync(String topic)
Remove the max number of subscriptions for specified topic asynchronously.
|
void |
removeMaxUnackedMessagesOnConsumer(String topic)
remove max unacked messages on consumer of a topic.
|
CompletableFuture<Void> |
removeMaxUnackedMessagesOnConsumerAsync(String topic)
remove max unacked messages on consumer of a topic asynchronously.
|
void |
removeMaxUnackedMessagesOnSubscription(String topic)
remove max unacked messages on subscription of a topic.
|
CompletableFuture<Void> |
removeMaxUnackedMessagesOnSubscriptionAsync(String topic)
remove max unacked messages on subscription of a topic asynchronously.
|
void |
removeMessageTTL(String topic)
Remove message TTL for a topic.
|
void |
removeOffloadPolicies(String topic)
remove offload policies of a topic.
|
CompletableFuture<Void> |
removeOffloadPoliciesAsync(String topic)
remove offload policies of a topic asynchronously.
|
void |
removePersistence(String topic)
Remove the configuration of persistence policies for specified topic.
|
CompletableFuture<Void> |
removePersistenceAsync(String topic)
Remove the configuration of persistence policies for specified topic asynchronously.
|
void |
removePublishRate(String topic)
Remove message-publish-rate.
|
CompletableFuture<Void> |
removePublishRateAsync(String topic)
Remove message-publish-rate asynchronously.
|
void |
removeReplicatorDispatchRate(String topic)
Remove replicatorDispatchRate for a topic.
|
CompletableFuture<Void> |
removeReplicatorDispatchRateAsync(String topic)
Remove replicatorDispatchRate for a topic asynchronously.
|
void |
removeRetention(String topic)
Remove the retention configuration for all the topics on a topic.
|
CompletableFuture<Void> |
removeRetentionAsync(String topic)
Remove the retention configuration for all the topics on a topic asynchronously.
|
void |
removeSubscribeRate(String topic)
Remove topic-subscribe-rate.
|
CompletableFuture<Void> |
removeSubscribeRateAsync(String topic)
Remove topic-subscribe-rate asynchronously.
|
void |
removeSubscriptionDispatchRate(String topic)
Remove subscription-message-dispatch-rate for a topic.
|
CompletableFuture<Void> |
removeSubscriptionDispatchRateAsync(String topic)
Remove subscription-message-dispatch-rate for a topic asynchronously.
|
void |
resetCursor(String topic,
String subName,
long timestamp)
Reset cursor position on a topic subscription.
|
void |
resetCursor(String topic,
String subName,
org.apache.pulsar.client.api.MessageId messageId)
Reset cursor position on a topic subscription.
|
void |
resetCursor(String topic,
String subName,
org.apache.pulsar.client.api.MessageId messageId,
boolean isExcluded)
Reset cursor position on a topic subscription.
|
CompletableFuture<Void> |
resetCursorAsync(String topic,
String subName,
long timestamp)
Reset cursor position on a topic subscription.
|
CompletableFuture<Void> |
resetCursorAsync(String topic,
String subName,
org.apache.pulsar.client.api.MessageId messageId)
Reset cursor position on a topic subscription.
|
CompletableFuture<Void> |
resetCursorAsync(String topic,
String subName,
org.apache.pulsar.client.api.MessageId messageId,
boolean isExcluded)
Reset cursor position on a topic subscription.
|
void |
revokePermissions(String topic,
String role)
Revoke permissions on a topic.
|
CompletableFuture<Void> |
revokePermissionsAsync(String topic,
String role)
Revoke permissions on a topic asynchronously.
|
void |
setBacklogQuota(String topic,
BacklogQuota backlogQuota)
Set a backlog quota for a topic.
|
void |
setCompactionThreshold(String topic,
long compactionThreshold)
Set the compactionThreshold for a topic.
|
CompletableFuture<Void> |
setCompactionThresholdAsync(String topic,
long compactionThreshold)
Set the compactionThreshold for a topic asynchronously.
|
void |
setDeduplicationSnapshotInterval(String topic,
int interval)
Set the deduplication snapshot interval for specified topic.
|
CompletableFuture<Void> |
setDeduplicationSnapshotIntervalAsync(String topic,
int interval)
Set the deduplication snapshot interval for specified topic asynchronously.
|
void |
setDeduplicationStatus(String topic,
boolean enabled)
set deduplication enabled of a topic.
|
CompletableFuture<Void> |
setDeduplicationStatusAsync(String topic,
boolean enabled)
set deduplication enabled of a topic asynchronously.
|
void |
setDelayedDeliveryPolicy(String topic,
DelayedDeliveryPolicies delayedDeliveryPolicies)
Set the delayed delivery policy for a specified topic.
|
CompletableFuture<Void> |
setDelayedDeliveryPolicyAsync(String topic,
DelayedDeliveryPolicies delayedDeliveryPolicies)
Set the delayed delivery policy for a specified topic asynchronously.
|
void |
setDispatchRate(String topic,
DispatchRate dispatchRate)
Set message-dispatch-rate (topic can dispatch this many messages per second).
|
CompletableFuture<Void> |
setDispatchRateAsync(String topic,
DispatchRate dispatchRate)
Set message-dispatch-rate asynchronously.
|
void |
setInactiveTopicPolicies(String topic,
InactiveTopicPolicies inactiveTopicPolicies)
set inactive topic policies of a topic.
|
CompletableFuture<Void> |
setInactiveTopicPoliciesAsync(String topic,
InactiveTopicPolicies inactiveTopicPolicies)
set inactive topic policies of a topic asynchronously.
|
void |
setMaxConsumers(String topic,
int maxConsumers)
Set the max number of consumer for specified topic.
|
CompletableFuture<Void> |
setMaxConsumersAsync(String topic,
int maxConsumers)
Set the max number of consumer for specified topic asynchronously.
|
void |
setMaxConsumersPerSubscription(String topic,
int maxConsumersPerSubscription)
Set maxConsumersPerSubscription for a topic.
|
CompletableFuture<Void> |
setMaxConsumersPerSubscriptionAsync(String topic,
int maxConsumersPerSubscription)
Set maxConsumersPerSubscription for a topic asynchronously.
|
void |
setMaxMessageSize(String topic,
int maxMessageSize)
Set the max message size for specified topic.
|
CompletableFuture<Void> |
setMaxMessageSizeAsync(String topic,
int maxMessageSize)
Set the max message size for specified topic asynchronously.0 disables.
|
void |
setMaxProducers(String topic,
int maxProducers)
Set the max number of producer for specified topic.
|
CompletableFuture<Void> |
setMaxProducersAsync(String topic,
int maxProducers)
Set the max number of producer for specified topic asynchronously.
|
void |
setMaxSubscriptionsPerTopic(String topic,
int maxSubscriptionsPerTopic)
Set the max number of subscriptions for specified topic.
|
CompletableFuture<Void> |
setMaxSubscriptionsPerTopicAsync(String topic,
int maxSubscriptionsPerTopic)
Set the max number of subscriptions for specified topic asynchronously.
|
void |
setMaxUnackedMessagesOnConsumer(String topic,
int maxNum)
set max unacked messages on consumer of a topic.
|
CompletableFuture<Void> |
setMaxUnackedMessagesOnConsumerAsync(String topic,
int maxNum)
set max unacked messages on consumer of a topic asynchronously.
|
void |
setMaxUnackedMessagesOnSubscription(String topic,
int maxNum)
set max unacked messages on subscription of a topic.
|
CompletableFuture<Void> |
setMaxUnackedMessagesOnSubscriptionAsync(String topic,
int maxNum)
set max unacked messages on subscription of a topic asynchronously.
|
void |
setMessageTTL(String topic,
int messageTTLInSecond)
Set message TTL for a topic.
|
void |
setOffloadPolicies(String topic,
OffloadPolicies offloadPolicies)
set offload policies of a topic.
|
CompletableFuture<Void> |
setOffloadPoliciesAsync(String topic,
OffloadPolicies offloadPolicies)
set offload policies of a topic asynchronously.
|
void |
setPersistence(String topic,
PersistencePolicies persistencePolicies)
Set the configuration of persistence policies for specified topic.
|
CompletableFuture<Void> |
setPersistenceAsync(String topic,
PersistencePolicies persistencePolicies)
Set the configuration of persistence policies for specified topic asynchronously.
|
void |
setPublishRate(String topic,
PublishRate publishMsgRate)
Set message-publish-rate (topics can publish this many messages per second).
|
CompletableFuture<Void> |
setPublishRateAsync(String topic,
PublishRate publishMsgRate)
Set message-publish-rate (topics can publish this many messages per second) asynchronously.
|
void |
setReplicatorDispatchRate(String topic,
DispatchRate dispatchRate)
Set replicatorDispatchRate for the topic.
|
CompletableFuture<Void> |
setReplicatorDispatchRateAsync(String topic,
DispatchRate dispatchRate)
Set replicatorDispatchRate for the topic asynchronously.
|
void |
setRetention(String topic,
RetentionPolicies retention)
Set the retention configuration on a topic.
|
CompletableFuture<Void> |
setRetentionAsync(String topic,
RetentionPolicies retention)
Set the retention configuration for all the topics on a topic asynchronously.
|
void |
setSubscribeRate(String topic,
SubscribeRate subscribeRate)
Set topic-subscribe-rate (topic will limit by subscribeRate).
|
CompletableFuture<Void> |
setSubscribeRateAsync(String topic,
SubscribeRate subscribeRate)
Set topic-subscribe-rate (topics will limit by subscribeRate) asynchronously.
|
void |
setSubscriptionDispatchRate(String topic,
DispatchRate dispatchRate)
Set subscription-message-dispatch-rate for the topic.
|
CompletableFuture<Void> |
setSubscriptionDispatchRateAsync(String topic,
DispatchRate dispatchRate)
Set subscription-message-dispatch-rate for the topic asynchronously.
|
void |
setSubscriptionTypesEnabled(String topic,
Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled)
Set is enable sub types.
|
CompletableFuture<Void> |
setSubscriptionTypesEnabledAsync(String topic,
Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled)
Set is enable sub types asynchronously.
|
void |
skipAllMessages(String topic,
String subName)
Skip all messages on a topic subscription.
|
CompletableFuture<Void> |
skipAllMessagesAsync(String topic,
String subName)
Skip all messages on a topic subscription asynchronously.
|
void |
skipMessages(String topic,
String subName,
long numMessages)
Skip messages on a topic subscription.
|
CompletableFuture<Void> |
skipMessagesAsync(String topic,
String subName,
long numMessages)
Skip messages on a topic subscription asynchronously.
|
org.apache.pulsar.client.api.MessageId |
terminateTopic(String topic)
Terminate the topic and prevent any more messages being published on it.
|
CompletableFuture<org.apache.pulsar.client.api.MessageId> |
terminateTopicAsync(String topic)
Terminate the topic and prevent any more messages being published on it.
|
void |
triggerCompaction(String topic)
Trigger compaction to run for a topic.
|
CompletableFuture<Void> |
triggerCompactionAsync(String topic)
Trigger compaction to run for a topic asynchronously.
|
void |
triggerOffload(String topic,
org.apache.pulsar.client.api.MessageId messageId)
Trigger offloading messages in topic to longterm storage.
|
CompletableFuture<Void> |
triggerOffloadAsync(String topic,
org.apache.pulsar.client.api.MessageId messageId)
Trigger offloading messages in topic to longterm storage asynchronously.
|
void |
truncate(String topic)
Truncate a topic.
|
CompletableFuture<Void> |
truncateAsync(String topic)
Truncate a topic asynchronously.
|
void |
unload(String topic)
Unload a topic.
|
CompletableFuture<Void> |
unloadAsync(String topic)
Unload a topic asynchronously.
|
void |
updatePartitionedTopic(String topic,
int numPartitions)
Update number of partitions of a non-global partitioned topic.
|
void |
updatePartitionedTopic(String topic,
int numPartitions,
boolean updateLocalTopicOnly)
Update number of partitions of a non-global partitioned topic.
|
CompletableFuture<Void> |
updatePartitionedTopicAsync(String topic,
int numPartitions)
Update number of partitions of a non-global partitioned topic asynchronously.
|
CompletableFuture<Void> |
updatePartitionedTopicAsync(String topic,
int numPartitions,
boolean updateLocalTopicOnly)
Update number of partitions of a non-global partitioned topic asynchronously.
|
List<String> getList(String namespace) throws PulsarAdminException
["topic://my-tenant/my-namespace/topic-1",
"topic://my-tenant/my-namespace/topic-2"]
namespace - Namespace namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorList<String> getList(String namespace, TopicDomain topicDomain) throws PulsarAdminException
["topic://my-tenant/my-namespace/topic-1",
"topic://my-tenant/my-namespace/topic-2"]
namespace - Namespace nametopicDomain - use TopicDomain.persistent to get persistent topics
use TopicDomain.non_persistent to get non-persistent topics
Use null to get both persistent and non-persistent topicsPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<List<String>> getListAsync(String namespace)
["topic://my-tenant/my-namespace/topic-1",
"topic://my-tenant/my-namespace/topic-2"]
namespace - Namespace nameCompletableFuture<List<String>> getListAsync(String namespace, TopicDomain topicDomain)
["topic://my-tenant/my-namespace/topic-1",
"topic://my-tenant/my-namespace/topic-2"]
namespace - Namespace nametopicDomain - use TopicDomain.persistent to get persistent topics
use TopicDomain.non_persistent to get non-persistent topics
Use null to get both persistent and non-persistent topicsList<String> getPartitionedTopicList(String namespace) throws PulsarAdminException
["persistent://my-tenant/my-namespace/topic-1",
"persistent://my-tenant/my-namespace/topic-2"]
namespace - Namespace namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<List<String>> getPartitionedTopicListAsync(String namespace)
["persistent://my-tenant/my-namespace/topic-1",
"persistent://my-tenant/my-namespace/topic-2"]
namespace - Namespace nameList<String> getListInBundle(String namespace, String bundleRange) throws PulsarAdminException
namespace - bundleRange - PulsarAdminExceptionCompletableFuture<List<String>> getListInBundleAsync(String namespace, String bundleRange)
namespace - bundleRange - Map<String,Set<AuthAction>> getPermissions(String topic) throws PulsarAdminException
{
"role-1" : [ "produce" ],
"role-2" : [ "consume" ]
}
topic - Topic urlPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Map<String,Set<AuthAction>>> getPermissionsAsync(String topic)
{
"role-1" : [ "produce" ],
"role-2" : [ "consume" ]
}
topic - Topic urlvoid grantPermission(String topic, String role, Set<AuthAction> actions) throws PulsarAdminException
["produce", "consume"]
topic - Topic urlrole - Client role to which grant permissionactions - Auth actions (produce and consume)PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException.ConflictException - Concurrent modificationPulsarAdminException - Unexpected errorCompletableFuture<Void> grantPermissionAsync(String topic, String role, Set<AuthAction> actions)
["produce", "consume"]
topic - Topic urlrole - Client role to which grant permissionactions - Auth actions (produce and consume)void revokePermissions(String topic, String role) throws PulsarAdminException
topic - Topic urlrole - Client role to which remove permissionPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException.PreconditionFailedException - Permissions are not set at the topic levelPulsarAdminException - Unexpected errorCompletableFuture<Void> revokePermissionsAsync(String topic, String role)
topic - Topic urlrole - Client role to which remove permissionvoid createPartitionedTopic(String topic, int numPartitions) throws PulsarAdminException
topic - Topic namenumPartitions - Number of partitions to create of the topicPulsarAdminExceptionCompletableFuture<Void> createPartitionedTopicAsync(String topic, int numPartitions)
topic - Topic namenumPartitions - Number of partitions to create of the topicvoid createNonPartitionedTopic(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminExceptionCompletableFuture<Void> createNonPartitionedTopicAsync(String topic)
topic - Topic namevoid createMissedPartitions(String topic) throws PulsarAdminException
topic - partitioned topic namePulsarAdminExceptionCompletableFuture<Void> createMissedPartitionsAsync(String topic)
topic - partitioned topic namevoid updatePartitionedTopic(String topic, int numPartitions) throws PulsarAdminException
topic - Topic namenumPartitions - Number of new partitions of already exist partitioned-topicPulsarAdminExceptionCompletableFuture<Void> updatePartitionedTopicAsync(String topic, int numPartitions)
topic - Topic namenumPartitions - Number of new partitions of already exist partitioned-topicvoid updatePartitionedTopic(String topic, int numPartitions, boolean updateLocalTopicOnly) throws PulsarAdminException
topic - Topic namenumPartitions - Number of new partitions of already exist partitioned-topicupdateLocalTopicOnly - Used by broker for global topic with multiple replicated clustersPulsarAdminExceptionCompletableFuture<Void> updatePartitionedTopicAsync(String topic, int numPartitions, boolean updateLocalTopicOnly)
topic - Topic namenumPartitions - Number of new partitions of already exist partitioned-topicupdateLocalTopicOnly - Used by broker for global topic with multiple replicated clustersPartitionedTopicMetadata getPartitionedTopicMetadata(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminExceptionCompletableFuture<PartitionedTopicMetadata> getPartitionedTopicMetadataAsync(String topic)
topic - Topic namevoid deletePartitionedTopic(String topic, boolean force, boolean deleteSchema) throws PulsarAdminException
topic - Topic nameforce - Delete topic forcefullydeleteSchema - Delete topic's schema storagePulsarAdminExceptiondefault void deletePartitionedTopic(String topic, boolean force) throws PulsarAdminException
PulsarAdminExceptiondeletePartitionedTopic(String, boolean, boolean)CompletableFuture<Void> deletePartitionedTopicAsync(String topic, boolean force, boolean deleteSchema)
topic - Topic nameforce - Delete topic forcefullydeleteSchema - Delete topic's schema storagedefault CompletableFuture<Void> deletePartitionedTopicAsync(String topic, boolean force)
void deletePartitionedTopic(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminExceptionCompletableFuture<Void> deletePartitionedTopicAsync(String topic)
topic - Topic namevoid delete(String topic, boolean force, boolean deleteSchema) throws PulsarAdminException
topic - Topic nameforce - Delete topic forcefullydeleteSchema - Delete topic's schema storagePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException.PreconditionFailedException - Topic has active subscriptions or producersPulsarAdminException - Unexpected errordefault void delete(String topic, boolean force) throws PulsarAdminException
PulsarAdminExceptiondelete(String, boolean, boolean)CompletableFuture<Void> deleteAsync(String topic, boolean force, boolean deleteSchema)
topic - topic nameforce - Delete topic forcefullydeleteSchema - Delete topic's schema storagedefault CompletableFuture<Void> deleteAsync(String topic, boolean force)
deleteAsync(String, boolean, boolean)void delete(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException.PreconditionFailedException - Topic has active subscriptions or producersPulsarAdminException - Unexpected errorCompletableFuture<Void> deleteAsync(String topic)
topic - Topic namevoid unload(String topic) throws PulsarAdminException
topic - topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - topic does not existPulsarAdminException - Unexpected errorCompletableFuture<Void> unloadAsync(String topic)
topic - topic nameorg.apache.pulsar.client.api.MessageId terminateTopic(String topic) throws PulsarAdminException
topic - topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - topic does not existPulsarAdminException - Unexpected errorCompletableFuture<org.apache.pulsar.client.api.MessageId> terminateTopicAsync(String topic)
topic - topic nameList<String> getSubscriptions(String topic) throws PulsarAdminException
topic - topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorCompletableFuture<List<String>> getSubscriptionsAsync(String topic)
topic - topic nameTopicStats getStats(String topic, boolean getPreciseBacklog, boolean subscriptionBacklogSize) throws PulsarAdminException
{
"msgRateIn" : 100.0, // Total rate of messages published on the topic. msg/s
"msgThroughputIn" : 10240.0, // Total throughput of messages published on the topic. byte/s
"msgRateOut" : 100.0, // Total rate of messages delivered on the topic. msg/s
"msgThroughputOut" : 10240.0, // Total throughput of messages delivered on the topic. byte/s
"averageMsgSize" : 1024.0, // Average size of published messages. bytes
"publishers" : [ // List of publishes on this topic with their stats
{
"producerId" : 10 // producer id
"address" : 10.4.1.23:3425 // IP and port for this producer
"connectedSince" : 2014-11-21 23:54:46 // Timestamp of this published connection
"msgRateIn" : 100.0, // Total rate of messages published by this producer. msg/s
"msgThroughputIn" : 10240.0, // Total throughput of messages published by this producer. byte/s
"averageMsgSize" : 1024.0, // Average size of published messages by this producer. bytes
},
],
"subscriptions" : { // Map of subscriptions on this topic
"sub1" : {
"msgRateOut" : 100.0, // Total rate of messages delivered on this subscription. msg/s
"msgThroughputOut" : 10240.0, // Total throughput delivered on this subscription. bytes/s
"msgBacklog" : 0, // Number of messages in the subscriotion backlog
"type" : Exclusive // Whether the subscription is exclusive or shared
"consumers" [ // List of consumers on this subscription
{
"id" : 5 // Consumer id
"address" : 10.4.1.23:3425 // IP and port for this consumer
"connectedSince" : 2014-11-21 23:54:46 // Timestamp of this consumer connection
"msgRateOut" : 100.0, // Total rate of messages delivered to this consumer. msg/s
"msgThroughputOut" : 10240.0, // Total throughput delivered to this consumer. bytes/s
}
],
},
"replication" : { // Replication statistics
"cluster_1" : { // Cluster name in the context of from-cluster or to-cluster
"msgRateIn" : 100.0, // Total rate of messages received from this remote cluster. msg/s
"msgThroughputIn" : 10240.0, // Total throughput received from this remote cluster. bytes/s
"msgRateOut" : 100.0, // Total rate of messages delivered to the replication-subscriber. msg/s
"msgThroughputOut" : 10240.0, // Total throughput delivered to the replication-subscriber. bytes/s
"replicationBacklog" : 0, // Number of messages pending to be replicated to this remote cluster
"connected" : true, // Whether the replication-subscriber is currently connected locally
},
"cluster_2" : {
"msgRateIn" : 100.0,
"msgThroughputIn" : 10240.0,
"msgRateOut" : 100.0,
"msgThroughputOut" : 10240.0,
"replicationBacklog" : 0,
"connected" : true,
}
},
}
All the rates are computed over a 1 minute window and are relative the last completed 1 minute period.
topic - topic namegetPreciseBacklog - Set to true to get precise backlog, Otherwise get imprecise backlog.subscriptionBacklogSize - Whether to get backlog size for each subscription.PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errordefault TopicStats getStats(String topic, boolean getPreciseBacklog) throws PulsarAdminException
PulsarAdminExceptiondefault TopicStats getStats(String topic) throws PulsarAdminException
PulsarAdminExceptionCompletableFuture<TopicStats> getStatsAsync(String topic, boolean getPreciseBacklog, boolean subscriptionBacklogSize)
topic - topic namegetPreciseBacklog - Set to true to get precise backlog, Otherwise get imprecise backlog.subscriptionBacklogSize - Whether to get backlog size for each subscription.default CompletableFuture<TopicStats> getStatsAsync(String topic)
PersistentTopicInternalStats getInternalStats(String topic, boolean metadata) throws PulsarAdminException
topic - topic namemetadata - flag to include ledger metadataPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorPersistentTopicInternalStats getInternalStats(String topic) throws PulsarAdminException
topic - topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorCompletableFuture<PersistentTopicInternalStats> getInternalStatsAsync(String topic, boolean metadata)
topic - topic Namemetadata - flag to include ledger metadataCompletableFuture<PersistentTopicInternalStats> getInternalStatsAsync(String topic)
topic - topic Namecom.google.gson.JsonObject getInternalInfo(String topic) throws PulsarAdminException
topic - topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorCompletableFuture<com.google.gson.JsonObject> getInternalInfoAsync(String topic)
topic - topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorPartitionedTopicStats getPartitionedStats(String topic, boolean perPartition, boolean getPreciseBacklog, boolean subscriptionBacklogSize) throws PulsarAdminException
{
"msgRateIn" : 100.0, // Total rate of messages published on the partitioned topic. msg/s
"msgThroughputIn" : 10240.0, // Total throughput of messages published on the partitioned topic. byte/s
"msgRateOut" : 100.0, // Total rate of messages delivered on the partitioned topic. msg/s
"msgThroughputOut" : 10240.0, // Total throughput of messages delivered on the partitioned topic. byte/s
"averageMsgSize" : 1024.0, // Average size of published messages. bytes
"publishers" : [ // List of publishes on this partitioned topic with their stats
{
"msgRateIn" : 100.0, // Total rate of messages published by this producer. msg/s
"msgThroughputIn" : 10240.0, // Total throughput of messages published by this producer. byte/s
"averageMsgSize" : 1024.0, // Average size of published messages by this producer. bytes
},
],
"subscriptions" : { // Map of subscriptions on this topic
"sub1" : {
"msgRateOut" : 100.0, // Total rate of messages delivered on this subscription. msg/s
"msgThroughputOut" : 10240.0, // Total throughput delivered on this subscription. bytes/s
"msgBacklog" : 0, // Number of messages in the subscriotion backlog
"type" : Exclusive // Whether the subscription is exclusive or shared
"consumers" [ // List of consumers on this subscription
{
"msgRateOut" : 100.0, // Total rate of messages delivered to this consumer. msg/s
"msgThroughputOut" : 10240.0, // Total throughput delivered to this consumer. bytes/s
}
],
},
"replication" : { // Replication statistics
"cluster_1" : { // Cluster name in the context of from-cluster or to-cluster
"msgRateIn" : 100.0, // Total rate of messages received from this remote cluster. msg/s
"msgThroughputIn" : 10240.0, // Total throughput received from this remote cluster. bytes/s
"msgRateOut" : 100.0, // Total rate of messages delivered to the replication-subscriber. msg/s
"msgThroughputOut" : 10240.0, // Total throughput delivered to the replication-subscriber. bytes/s
"replicationBacklog" : 0, // Number of messages pending to be replicated to this remote cluster
"connected" : true, // Whether the replication-subscriber is currently connected locally
},
"cluster_2" : {
"msgRateIn" : 100.0,
"msgThroughputIn" : 10240.0,
"msgRateOut" : 100.0,
"msghroughputOut" : 10240.0,
"replicationBacklog" : 0,
"connected" : true,
}
},
}
All the rates are computed over a 1 minute window and are relative the last completed 1 minute period.
topic - topic nameperPartition - flag to get stats per partitiongetPreciseBacklog - Set to true to get precise backlog, Otherwise get imprecise backlog.subscriptionBacklogSize - Whether to get backlog size for each subscription.PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errordefault PartitionedTopicStats getPartitionedStats(String topic, boolean perPartition) throws PulsarAdminException
PulsarAdminExceptionCompletableFuture<PartitionedTopicStats> getPartitionedStatsAsync(String topic, boolean perPartition, boolean getPreciseBacklog, boolean subscriptionBacklogSize)
topic - topic NameperPartition - flag to get stats per partitiongetPreciseBacklog - Set to true to get precise backlog, Otherwise get imprecise backlog.subscriptionBacklogSize - Whether to get backlog size for each subscription.default CompletableFuture<PartitionedTopicStats> getPartitionedStatsAsync(String topic, boolean perPartition)
PartitionedTopicInternalStats getPartitionedInternalStats(String topic) throws PulsarAdminException
topic - topic namePulsarAdminExceptionCompletableFuture<PartitionedTopicInternalStats> getPartitionedInternalStatsAsync(String topic)
topic - topic Namevoid deleteSubscription(String topic, String subName) throws PulsarAdminException
topic - topic namesubName - Subscription namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic or subscription does not existPulsarAdminException.PreconditionFailedException - Subscription has active consumersPulsarAdminException - Unexpected errorvoid deleteSubscription(String topic, String subName, boolean force) throws PulsarAdminException
topic - topic namesubName - Subscription nameforce - Delete topic forcefullyPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic or subscription does not existPulsarAdminException.PreconditionFailedException - Subscription has active consumersPulsarAdminException - Unexpected errorCompletableFuture<Void> deleteSubscriptionAsync(String topic, String subName)
topic - topic namesubName - Subscription nameCompletableFuture<Void> deleteSubscriptionAsync(String topic, String subName, boolean force)
topic - topic namesubName - Subscription nameforce - Delete topic forcefullyvoid skipAllMessages(String topic, String subName) throws PulsarAdminException
topic - topic namesubName - Subscription namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic or subscription does not existPulsarAdminException - Unexpected errorCompletableFuture<Void> skipAllMessagesAsync(String topic, String subName)
topic - topic namesubName - Subscription namevoid skipMessages(String topic, String subName, long numMessages) throws PulsarAdminException
topic - topic namesubName - Subscription namenumMessages - Number of messagesPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic or subscription does not existPulsarAdminException - Unexpected errorCompletableFuture<Void> skipMessagesAsync(String topic, String subName, long numMessages)
topic - topic namesubName - Subscription namenumMessages - Number of messagesvoid expireMessages(String topic, String subscriptionName, long expireTimeInSeconds) throws PulsarAdminException
topic - topic namesubscriptionName - Subscription nameexpireTimeInSeconds - Expire messages older than time in secondsPulsarAdminException - Unexpected errorCompletableFuture<Void> expireMessagesAsync(String topic, String subscriptionName, long expireTimeInSeconds)
topic - topic namesubscriptionName - Subscription nameexpireTimeInSeconds - Expire messages older than time in secondsvoid expireMessages(String topic, String subscriptionName, org.apache.pulsar.client.api.MessageId messageId, boolean isExcluded) throws PulsarAdminException
topic - topic namesubscriptionName - Subscription namemessageId - Position before which all messages will be expired.isExcluded - Will message at passed in position also be expired.PulsarAdminException - Unexpected errorCompletableFuture<Void> expireMessagesAsync(String topic, String subscriptionName, org.apache.pulsar.client.api.MessageId messageId, boolean isExcluded)
topic - topic namesubscriptionName - Subscription namemessageId - Position before which all messages will be expired.isExcluded - Will message at passed in position also be expired.CompletableFuture that'll be completed when expire message is done.void expireMessagesForAllSubscriptions(String topic, long expireTimeInSeconds) throws PulsarAdminException
topic - topic nameexpireTimeInSeconds - Expire messages older than time in secondsPulsarAdminException - Unexpected errorCompletableFuture<Void> expireMessagesForAllSubscriptionsAsync(String topic, long expireTimeInSeconds)
topic - topic nameexpireTimeInSeconds - Expire messages older than time in secondsList<org.apache.pulsar.client.api.Message<byte[]>> peekMessages(String topic, String subName, int numMessages) throws PulsarAdminException
topic - topic namesubName - Subscription namenumMessages - Number of messagesPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic or subscription does not existPulsarAdminException - Unexpected errorCompletableFuture<List<org.apache.pulsar.client.api.Message<byte[]>>> peekMessagesAsync(String topic, String subName, int numMessages)
topic - topic namesubName - Subscription namenumMessages - Number of messagesorg.apache.pulsar.client.api.Message<byte[]> getMessageById(String topic, long ledgerId, long entryId) throws PulsarAdminException
topic - Topic nameledgerId - Ledger identryId - Entry idPulsarAdminException - Unexpected errorCompletableFuture<org.apache.pulsar.client.api.Message<byte[]>> getMessageByIdAsync(String topic, long ledgerId, long entryId)
topic - Topic nameledgerId - Ledger identryId - Entry idvoid createSubscription(String topic, String subscriptionName, org.apache.pulsar.client.api.MessageId messageId) throws PulsarAdminException
topic - topic namesubscriptionName - Subscription namemessageId - The MessageId on where to initialize the subscription. It could be MessageId.latest,
MessageId.earliest or a specific message id.PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.ConflictException - Subscription already existsPulsarAdminException.NotAllowedException - Command disallowed for requested resourcePulsarAdminException - Unexpected errorCompletableFuture<Void> createSubscriptionAsync(String topic, String subscriptionName, org.apache.pulsar.client.api.MessageId messageId)
topic - topic namesubscriptionName - Subscription namemessageId - The MessageId on where to initialize the subscription. It could be MessageId.latest,
MessageId.earliest or a specific message id.void resetCursor(String topic, String subName, long timestamp) throws PulsarAdminException
topic - topic namesubName - Subscription nametimestamp - reset subscription to position closest to time in ms since epochPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic or subscription does not existPulsarAdminException.NotAllowedException - Command disallowed for requested resourcePulsarAdminException - Unexpected errorvoid resetCursor(String topic, String subName, org.apache.pulsar.client.api.MessageId messageId, boolean isExcluded) throws PulsarAdminException
topic - subName - messageId - isExcluded - PulsarAdminExceptionCompletableFuture<Void> resetCursorAsync(String topic, String subName, long timestamp)
topic - topic namesubName - Subscription nametimestamp - reset subscription to position closest to time in ms since epochCompletableFuture<Void> resetCursorAsync(String topic, String subName, org.apache.pulsar.client.api.MessageId messageId, boolean isExcluded)
topic - subName - messageId - isExcluded - void resetCursor(String topic, String subName, org.apache.pulsar.client.api.MessageId messageId) throws PulsarAdminException
topic - topic namesubName - Subscription namemessageId - reset subscription to messageId (or previous nearest messageId if given messageId is not valid)PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic or subscription does not existPulsarAdminException.NotAllowedException - Command disallowed for requested resourcePulsarAdminException - Unexpected errorCompletableFuture<Void> resetCursorAsync(String topic, String subName, org.apache.pulsar.client.api.MessageId messageId)
topic - topic namesubName - Subscription namemessageId - reset subscription to messageId (or previous nearest messageId if given messageId is not valid)void triggerCompaction(String topic) throws PulsarAdminException
topic - The topic on which to trigger compactionPulsarAdminExceptionCompletableFuture<Void> triggerCompactionAsync(String topic)
topic - The topic on which to trigger compactionLongRunningProcessStatus compactionStatus(String topic) throws PulsarAdminException
topic - The topic whose compaction status we wish to checkPulsarAdminExceptionCompletableFuture<LongRunningProcessStatus> compactionStatusAsync(String topic)
topic - The topic whose compaction status we wish to checkvoid triggerOffload(String topic, org.apache.pulsar.client.api.MessageId messageId) throws PulsarAdminException
topic - the topic to offloadmessageId - ID of maximum message which should be offloadedPulsarAdminExceptionCompletableFuture<Void> triggerOffloadAsync(String topic, org.apache.pulsar.client.api.MessageId messageId)
topic - the topic to offloadmessageId - ID of maximum message which should be offloadedOffloadProcessStatus offloadStatus(String topic) throws PulsarAdminException
topic - the topic being offloadedPulsarAdminExceptionCompletableFuture<OffloadProcessStatus> offloadStatusAsync(String topic)
topic - the topic being offloadedorg.apache.pulsar.client.api.MessageId getLastMessageId(String topic) throws PulsarAdminException
topic - the topic namePulsarAdminExceptionCompletableFuture<org.apache.pulsar.client.api.MessageId> getLastMessageIdAsync(String topic)
topic - the topic nameMap<BacklogQuota.BacklogQuotaType,BacklogQuota> getBacklogQuotaMap(String topic) throws PulsarAdminException
{
"namespace_memory" : {
"limit" : "134217728",
"policy" : "consumer_backlog_eviction"
},
"destination_storage" : {
"limit" : "-1",
"policy" : "producer_exception"
}
}
topic - Topic namePulsarAdminException.NotAuthorizedException - Permission deniedPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorMap<BacklogQuota.BacklogQuotaType,BacklogQuota> getBacklogQuotaMap(String topic, boolean applied) throws PulsarAdminException
topic - applied - PulsarAdminExceptionvoid setBacklogQuota(String topic, BacklogQuota backlogQuota) throws PulsarAdminException
Request parameter example:
{
"limit" : "134217728",
"policy" : "consumer_backlog_eviction"
}
topic - Topic namebacklogQuota - the new BacklogQuotaPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorvoid removeBacklogQuota(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorDelayedDeliveryPolicies getDelayedDeliveryPolicy(String topic, boolean applied) throws PulsarAdminException
topic - applied - PulsarAdminExceptionCompletableFuture<DelayedDeliveryPolicies> getDelayedDeliveryPolicyAsync(String topic, boolean applied)
topic - applied - DelayedDeliveryPolicies getDelayedDeliveryPolicy(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<DelayedDeliveryPolicies> getDelayedDeliveryPolicyAsync(String topic)
topic - void setDelayedDeliveryPolicy(String topic, DelayedDeliveryPolicies delayedDeliveryPolicies) throws PulsarAdminException
topic - delayedDeliveryPolicies - PulsarAdminExceptionCompletableFuture<Void> setDelayedDeliveryPolicyAsync(String topic, DelayedDeliveryPolicies delayedDeliveryPolicies)
topic - delayedDeliveryPolicies - CompletableFuture<Void> removeDelayedDeliveryPolicyAsync(String topic)
topic - void removeDelayedDeliveryPolicy(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionvoid setMessageTTL(String topic, int messageTTLInSecond) throws PulsarAdminException
topic - Topic namemessageTTLInSecond - Message TTL in second.PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorInteger getMessageTTL(String topic) throws PulsarAdminException
topic - PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorInteger getMessageTTL(String topic, boolean applied) throws PulsarAdminException
topic - PulsarAdminExceptionvoid removeMessageTTL(String topic) throws PulsarAdminException
topic - PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException - Unexpected errorvoid setRetention(String topic, RetentionPolicies retention) throws PulsarAdminException
{
"retentionTimeInMinutes" : 60, // how long to retain messages
"retentionSizeInMB" : 1024, // retention backlog limit
}
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException.ConflictException - Concurrent modificationPulsarAdminException - Unexpected errorCompletableFuture<Void> setRetentionAsync(String topic, RetentionPolicies retention)
{
"retentionTimeInMinutes" : 60, // how long to retain messages
"retentionSizeInMB" : 1024, // retention backlog limit
}
topic - Topic nameRetentionPolicies getRetention(String topic) throws PulsarAdminException
{
"retentionTimeInMinutes" : 60, // how long to retain messages
"retentionSizeInMB" : 1024, // retention backlog limit
}
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException.ConflictException - Concurrent modificationPulsarAdminException - Unexpected errorCompletableFuture<RetentionPolicies> getRetentionAsync(String topic)
topic - Topic nameRetentionPolicies getRetention(String topic, boolean applied) throws PulsarAdminException
topic - applied - PulsarAdminExceptionCompletableFuture<RetentionPolicies> getRetentionAsync(String topic, boolean applied)
topic - applied - void removeRetention(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Topic does not existPulsarAdminException.ConflictException - Concurrent modificationPulsarAdminException - Unexpected errorCompletableFuture<Void> removeRetentionAsync(String topic)
{
"retentionTimeInMinutes" : 60, // how long to retain messages
"retentionSizeInMB" : 1024, // retention backlog limit
}
topic - Topic nameInteger getMaxUnackedMessagesOnConsumer(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Integer> getMaxUnackedMessagesOnConsumerAsync(String topic)
topic - Integer getMaxUnackedMessagesOnConsumer(String topic, boolean applied) throws PulsarAdminException
topic - applied - PulsarAdminExceptionCompletableFuture<Integer> getMaxUnackedMessagesOnConsumerAsync(String topic, boolean applied)
topic - applied - void setMaxUnackedMessagesOnConsumer(String topic, int maxNum) throws PulsarAdminException
topic - maxNum - PulsarAdminExceptionCompletableFuture<Void> setMaxUnackedMessagesOnConsumerAsync(String topic, int maxNum)
topic - maxNum - void removeMaxUnackedMessagesOnConsumer(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Void> removeMaxUnackedMessagesOnConsumerAsync(String topic)
topic - InactiveTopicPolicies getInactiveTopicPolicies(String topic, boolean applied) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<InactiveTopicPolicies> getInactiveTopicPoliciesAsync(String topic, boolean applied)
topic - applied - InactiveTopicPolicies getInactiveTopicPolicies(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<InactiveTopicPolicies> getInactiveTopicPoliciesAsync(String topic)
topic - void setInactiveTopicPolicies(String topic, InactiveTopicPolicies inactiveTopicPolicies) throws PulsarAdminException
topic - inactiveTopicPolicies - PulsarAdminExceptionCompletableFuture<Void> setInactiveTopicPoliciesAsync(String topic, InactiveTopicPolicies inactiveTopicPolicies)
topic - inactiveTopicPolicies - void removeInactiveTopicPolicies(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Void> removeInactiveTopicPoliciesAsync(String topic)
topic - OffloadPolicies getOffloadPolicies(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<OffloadPolicies> getOffloadPoliciesAsync(String topic)
topic - OffloadPolicies getOffloadPolicies(String topic, boolean applied) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<OffloadPolicies> getOffloadPoliciesAsync(String topic, boolean applied)
topic - void setOffloadPolicies(String topic, OffloadPolicies offloadPolicies) throws PulsarAdminException
topic - offloadPolicies - PulsarAdminExceptionCompletableFuture<Void> setOffloadPoliciesAsync(String topic, OffloadPolicies offloadPolicies)
topic - offloadPolicies - void removeOffloadPolicies(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Void> removeOffloadPoliciesAsync(String topic)
topic - Integer getMaxUnackedMessagesOnSubscription(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Integer> getMaxUnackedMessagesOnSubscriptionAsync(String topic)
topic - Integer getMaxUnackedMessagesOnSubscription(String topic, boolean applied) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Integer> getMaxUnackedMessagesOnSubscriptionAsync(String topic, boolean applied)
topic - void setMaxUnackedMessagesOnSubscription(String topic, int maxNum) throws PulsarAdminException
topic - maxNum - PulsarAdminExceptionCompletableFuture<Void> setMaxUnackedMessagesOnSubscriptionAsync(String topic, int maxNum)
topic - maxNum - void removeMaxUnackedMessagesOnSubscription(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Void> removeMaxUnackedMessagesOnSubscriptionAsync(String topic)
topic - void setPersistence(String topic, PersistencePolicies persistencePolicies) throws PulsarAdminException
topic - Topic namepersistencePolicies - Configuration of bookkeeper persistence policiesPulsarAdminException - Unexpected errorCompletableFuture<Void> setPersistenceAsync(String topic, PersistencePolicies persistencePolicies)
topic - Topic namepersistencePolicies - Configuration of bookkeeper persistence policiesPersistencePolicies getPersistence(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<PersistencePolicies> getPersistenceAsync(String topic)
topic - Topic namePersistencePolicies getPersistence(String topic, boolean applied) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<PersistencePolicies> getPersistenceAsync(String topic, boolean applied)
topic - Topic namevoid removePersistence(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removePersistenceAsync(String topic)
topic - Topic name@Deprecated Boolean getDeduplicationEnabled(String topic) throws PulsarAdminException
topic - PulsarAdminException@Deprecated CompletableFuture<Boolean> getDeduplicationEnabledAsync(String topic)
topic - Boolean getDeduplicationStatus(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Boolean> getDeduplicationStatusAsync(String topic)
topic - Boolean getDeduplicationStatus(String topic, boolean applied) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Boolean> getDeduplicationStatusAsync(String topic, boolean applied)
topic - @Deprecated void enableDeduplication(String topic, boolean enabled) throws PulsarAdminException
topic - enabled - PulsarAdminException@Deprecated CompletableFuture<Void> enableDeduplicationAsync(String topic, boolean enabled)
topic - enabled - void setDeduplicationStatus(String topic, boolean enabled) throws PulsarAdminException
topic - enabled - PulsarAdminExceptionCompletableFuture<Void> setDeduplicationStatusAsync(String topic, boolean enabled)
topic - enabled - @Deprecated void disableDeduplication(String topic) throws PulsarAdminException
topic - PulsarAdminException@Deprecated CompletableFuture<Void> disableDeduplicationAsync(String topic)
topic - void removeDeduplicationStatus(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Void> removeDeduplicationStatusAsync(String topic)
topic - void setDispatchRate(String topic, DispatchRate dispatchRate) throws PulsarAdminException
topic - dispatchRate - number of messages per secondPulsarAdminException - Unexpected errorCompletableFuture<Void> setDispatchRateAsync(String topic, DispatchRate dispatchRate)
topic - dispatchRate - number of messages per secondDispatchRate getDispatchRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - Unexpected errorCompletableFuture<DispatchRate> getDispatchRateAsync(String topic)
topic - DispatchRate getDispatchRate(String topic, boolean applied) throws PulsarAdminException
topic - PulsarAdminException - Unexpected errorCompletableFuture<DispatchRate> getDispatchRateAsync(String topic, boolean applied)
topic - void removeDispatchRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - unexpected errorCompletableFuture<Void> removeDispatchRateAsync(String topic) throws PulsarAdminException
topic - PulsarAdminException - unexpected errorvoid setSubscriptionDispatchRate(String topic, DispatchRate dispatchRate) throws PulsarAdminException
topic - dispatchRate - number of messages per secondPulsarAdminException - Unexpected errorCompletableFuture<Void> setSubscriptionDispatchRateAsync(String topic, DispatchRate dispatchRate)
topic - dispatchRate - number of messages per secondDispatchRate getSubscriptionDispatchRate(String namespace, boolean applied) throws PulsarAdminException
namespace - PulsarAdminException - Unexpected errorCompletableFuture<DispatchRate> getSubscriptionDispatchRateAsync(String namespace, boolean applied)
namespace - DispatchRate getSubscriptionDispatchRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - Unexpected errorCompletableFuture<DispatchRate> getSubscriptionDispatchRateAsync(String topic)
topic - void removeSubscriptionDispatchRate(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeSubscriptionDispatchRateAsync(String topic)
topic - Topic namevoid setReplicatorDispatchRate(String topic, DispatchRate dispatchRate) throws PulsarAdminException
topic - dispatchRate - number of messages per secondPulsarAdminException - Unexpected errorCompletableFuture<Void> setReplicatorDispatchRateAsync(String topic, DispatchRate dispatchRate)
topic - dispatchRate - number of messages per secondDispatchRate getReplicatorDispatchRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - Unexpected errorCompletableFuture<DispatchRate> getReplicatorDispatchRateAsync(String topic)
topic - DispatchRate getReplicatorDispatchRate(String topic, boolean applied) throws PulsarAdminException
topic - applied - PulsarAdminExceptionCompletableFuture<DispatchRate> getReplicatorDispatchRateAsync(String topic, boolean applied)
topic - applied - void removeReplicatorDispatchRate(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeReplicatorDispatchRateAsync(String topic)
topic - Topic nameLong getCompactionThreshold(String topic) throws PulsarAdminException
10000000
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Long> getCompactionThresholdAsync(String topic)
10000000
topic - Topic nameLong getCompactionThreshold(String topic, boolean applied) throws PulsarAdminException
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Long> getCompactionThresholdAsync(String topic, boolean applied)
topic - Topic namevoid setCompactionThreshold(String topic, long compactionThreshold) throws PulsarAdminException
10000000
topic - Topic namecompactionThreshold - maximum number of backlog bytes before compaction is triggeredPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Void> setCompactionThresholdAsync(String topic, long compactionThreshold)
10000000
topic - Topic namecompactionThreshold - maximum number of backlog bytes before compaction is triggeredvoid removeCompactionThreshold(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeCompactionThresholdAsync(String topic)
topic - Topic namevoid setPublishRate(String topic, PublishRate publishMsgRate) throws PulsarAdminException
topic - publishMsgRate - number of messages per secondPulsarAdminException - Unexpected errorCompletableFuture<Void> setPublishRateAsync(String topic, PublishRate publishMsgRate)
topic - publishMsgRate - number of messages per secondPublishRate getPublishRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - Unexpected errorCompletableFuture<PublishRate> getPublishRateAsync(String topic)
topic - void removePublishRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - unexpected errorCompletableFuture<Void> removePublishRateAsync(String topic) throws PulsarAdminException
topic - PulsarAdminException - unexpected errorInteger getMaxConsumersPerSubscription(String topic) throws PulsarAdminException
0
topic - Topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Integer> getMaxConsumersPerSubscriptionAsync(String topic)
0
topic - Topic namevoid setMaxConsumersPerSubscription(String topic, int maxConsumersPerSubscription) throws PulsarAdminException
10
topic - Topic namemaxConsumersPerSubscription - maxConsumersPerSubscription value for a namespacePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Void> setMaxConsumersPerSubscriptionAsync(String topic, int maxConsumersPerSubscription)
10
topic - Topic namemaxConsumersPerSubscription - maxConsumersPerSubscription value for a namespacevoid removeMaxConsumersPerSubscription(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeMaxConsumersPerSubscriptionAsync(String topic)
topic - Topic nameInteger getMaxProducers(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Integer> getMaxProducersAsync(String topic)
topic - Topic namePulsarAdminException - Unexpected errorInteger getMaxProducers(String topic, boolean applied) throws PulsarAdminException
topic - applied - PulsarAdminExceptionCompletableFuture<Integer> getMaxProducersAsync(String topic, boolean applied)
topic - applied - void setMaxProducers(String topic, int maxProducers) throws PulsarAdminException
topic - Topic namemaxProducers - Max number of producerPulsarAdminException - Unexpected errorCompletableFuture<Void> setMaxProducersAsync(String topic, int maxProducers)
topic - Topic namemaxProducers - Max number of producerPulsarAdminException - Unexpected errorvoid removeMaxProducers(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeMaxProducersAsync(String topic)
topic - Topic nameInteger getMaxSubscriptionsPerTopic(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Integer> getMaxSubscriptionsPerTopicAsync(String topic)
topic - Topic namePulsarAdminException - Unexpected errorvoid setMaxSubscriptionsPerTopic(String topic, int maxSubscriptionsPerTopic) throws PulsarAdminException
topic - Topic namemaxSubscriptionsPerTopic - Max number of subscriptionsPulsarAdminException - Unexpected errorCompletableFuture<Void> setMaxSubscriptionsPerTopicAsync(String topic, int maxSubscriptionsPerTopic)
topic - Topic namemaxSubscriptionsPerTopic - Max number of subscriptionsPulsarAdminException - Unexpected errorvoid removeMaxSubscriptionsPerTopic(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeMaxSubscriptionsPerTopicAsync(String topic)
topic - Topic nameInteger getMaxMessageSize(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Integer> getMaxMessageSizeAsync(String topic)
topic - Topic namePulsarAdminException - Unexpected errorvoid setMaxMessageSize(String topic, int maxMessageSize) throws PulsarAdminException
topic - Topic namemaxMessageSize - Max message size of producerPulsarAdminException - Unexpected errorCompletableFuture<Void> setMaxMessageSizeAsync(String topic, int maxMessageSize)
topic - Topic namemaxMessageSize - Max message size of topicPulsarAdminException - Unexpected errorvoid removeMaxMessageSize(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeMaxMessageSizeAsync(String topic)
topic - Topic nameInteger getMaxConsumers(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Integer> getMaxConsumersAsync(String topic)
topic - Topic namePulsarAdminException - Unexpected errorInteger getMaxConsumers(String topic, boolean applied) throws PulsarAdminException
topic - applied - PulsarAdminExceptionCompletableFuture<Integer> getMaxConsumersAsync(String topic, boolean applied)
topic - applied - void setMaxConsumers(String topic, int maxConsumers) throws PulsarAdminException
topic - Topic namemaxConsumers - Max number of consumerPulsarAdminException - Unexpected errorCompletableFuture<Void> setMaxConsumersAsync(String topic, int maxConsumers)
topic - Topic namemaxConsumers - Max number of consumerPulsarAdminException - Unexpected errorvoid removeMaxConsumers(String topic) throws PulsarAdminException
topic - Topic namePulsarAdminException - Unexpected errorCompletableFuture<Void> removeMaxConsumersAsync(String topic)
topic - Topic nameInteger getDeduplicationSnapshotInterval(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Integer> getDeduplicationSnapshotIntervalAsync(String topic)
topic - void setDeduplicationSnapshotInterval(String topic, int interval) throws PulsarAdminException
topic - interval - PulsarAdminExceptionCompletableFuture<Void> setDeduplicationSnapshotIntervalAsync(String topic, int interval)
topic - interval - void removeDeduplicationSnapshotInterval(String topic) throws PulsarAdminException
topic - PulsarAdminExceptionCompletableFuture<Void> removeDeduplicationSnapshotIntervalAsync(String topic)
topic - void setSubscriptionTypesEnabled(String topic, Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled) throws PulsarAdminException
topic - subscriptionTypesEnabled - is enable subTypesPulsarAdminException - Unexpected errorCompletableFuture<Void> setSubscriptionTypesEnabledAsync(String topic, Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled)
topic - subscriptionTypesEnabled - is enable subTypesSet<org.apache.pulsar.client.api.SubscriptionType> getSubscriptionTypesEnabled(String topic) throws PulsarAdminException
topic - is topic for get is enable sub typesSetPulsarAdminException - Unexpected errorCompletableFuture<Set<org.apache.pulsar.client.api.SubscriptionType>> getSubscriptionTypesEnabledAsync(String topic)
topic - is topic for get is enable sub typesvoid setSubscribeRate(String topic, SubscribeRate subscribeRate) throws PulsarAdminException
topic - subscribeRate - consumer subscribe limit by this subscribeRatePulsarAdminException - Unexpected errorCompletableFuture<Void> setSubscribeRateAsync(String topic, SubscribeRate subscribeRate)
topic - subscribeRate - consumer subscribe limit by this subscribeRateSubscribeRate getSubscribeRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - Unexpected errorCompletableFuture<SubscribeRate> getSubscribeRateAsync(String topic)
topic - SubscribeRate getSubscribeRate(String topic, boolean applied) throws PulsarAdminException
topic - PulsarAdminException - Unexpected errorCompletableFuture<SubscribeRate> getSubscribeRateAsync(String topic, boolean applied)
topic - void removeSubscribeRate(String topic) throws PulsarAdminException
topic - PulsarAdminException - unexpected errorCompletableFuture<Void> removeSubscribeRateAsync(String topic) throws PulsarAdminException
topic - PulsarAdminException - unexpected errororg.apache.pulsar.client.api.Message<byte[]> examineMessage(String topic, String initialPosition, long messagePosition) throws PulsarAdminException
topic - Topic nameinitialPosition - Relative start position to examine message. It can be 'latest' or 'earliest'messagePosition - The position of messages (default 1)PulsarAdminExceptionCompletableFuture<org.apache.pulsar.client.api.Message<byte[]>> examineMessageAsync(String topic, String initialPosition, long messagePosition) throws PulsarAdminException
topic - Topic nameinitialPosition - Relative start position to examine message. It can be 'latest' or 'earliest'messagePosition - The position of messages (default 1)PulsarAdminExceptionvoid truncate(String topic) throws PulsarAdminException
topic - topic namePulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException - Unexpected errorCompletableFuture<Void> truncateAsync(String topic)
topic - topic nameCopyright © 2017–2021 Apache Software Foundation. All rights reserved.