Package org.apache.pulsar.client.admin
Interface Namespaces
-
public interface NamespacesAdmin interface for namespaces management.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description voidclearNamespaceBacklog(java.lang.String namespace)Clear backlog for all topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>clearNamespaceBacklogAsync(java.lang.String namespace)Clear backlog for all topics on a namespace asynchronously.voidclearNamespaceBacklogForSubscription(java.lang.String namespace, java.lang.String subscription)Clear backlog for a given subscription on all topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>clearNamespaceBacklogForSubscriptionAsync(java.lang.String namespace, java.lang.String subscription)Clear backlog for a given subscription on all topics on a namespace asynchronously.voidclearNamespaceBundleBacklog(java.lang.String namespace, java.lang.String bundle)Clear backlog for all topics on a namespace bundle.java.util.concurrent.CompletableFuture<java.lang.Void>clearNamespaceBundleBacklogAsync(java.lang.String namespace, java.lang.String bundle)Clear backlog for all topics on a namespace bundle asynchronously.voidclearNamespaceBundleBacklogForSubscription(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription)Clear backlog for a given subscription on all topics on a namespace bundle.java.util.concurrent.CompletableFuture<java.lang.Void>clearNamespaceBundleBacklogForSubscriptionAsync(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription)Clear backlog for a given subscription on all topics on a namespace bundle asynchronously.voidclearOffloadDeleteLag(java.lang.String namespace)Clear the offload deletion lag for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>clearOffloadDeleteLagAsync(java.lang.String namespace)Clear the offload deletion lag for a namespace asynchronously.voidclearProperties(java.lang.String namespace)Clear all properties of a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>clearPropertiesAsync(java.lang.String namespace)Clear all properties of a namespace asynchronously.voidcreateNamespace(java.lang.String namespace)Create a new namespace.voidcreateNamespace(java.lang.String namespace, int numBundles)Create a new namespace.voidcreateNamespace(java.lang.String namespace, java.util.Set<java.lang.String> clusters)Create a new namespace.voidcreateNamespace(java.lang.String namespace, BundlesData bundlesData)Create a new namespace.voidcreateNamespace(java.lang.String namespace, Policies policies)Create a new namespace.java.util.concurrent.CompletableFuture<java.lang.Void>createNamespaceAsync(java.lang.String namespace)Create a new namespace asynchronously.java.util.concurrent.CompletableFuture<java.lang.Void>createNamespaceAsync(java.lang.String namespace, int numBundles)Create a new namespace.java.util.concurrent.CompletableFuture<java.lang.Void>createNamespaceAsync(java.lang.String namespace, java.util.Set<java.lang.String> clusters)Create a new namespace asynchronously.java.util.concurrent.CompletableFuture<java.lang.Void>createNamespaceAsync(java.lang.String namespace, BundlesData bundlesData)Create a new namespace asynchronously.java.util.concurrent.CompletableFuture<java.lang.Void>createNamespaceAsync(java.lang.String namespace, Policies policies)Create a new namespace asynchronously.voiddeleteBookieAffinityGroup(java.lang.String namespace)Delete bookie affinity group configured for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>deleteBookieAffinityGroupAsync(java.lang.String namespace)Delete bookie affinity group configured for a namespace asynchronously.voiddeleteNamespace(java.lang.String namespace)Delete an existing namespace.voiddeleteNamespace(java.lang.String namespace, boolean force)Delete an existing namespace.voiddeleteNamespaceAntiAffinityGroup(java.lang.String namespace)Delete anti-affinity group name for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>deleteNamespaceAntiAffinityGroupAsync(java.lang.String namespace)Delete anti-affinity group name for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>deleteNamespaceAsync(java.lang.String namespace)Delete an existing namespace asynchronously.java.util.concurrent.CompletableFuture<java.lang.Void>deleteNamespaceAsync(java.lang.String namespace, boolean force)Delete an existing namespace asynchronously.voiddeleteNamespaceBundle(java.lang.String namespace, java.lang.String bundleRange)Delete an existing bundle in a namespace.voiddeleteNamespaceBundle(java.lang.String namespace, java.lang.String bundleRange, boolean force)Delete an existing bundle in a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>deleteNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundleRange)Delete an existing bundle in a namespace asynchronously.java.util.concurrent.CompletableFuture<java.lang.Void>deleteNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundleRange, boolean force)Delete an existing bundle in a namespace asynchronously.java.util.List<java.lang.String>getAntiAffinityNamespaces(java.lang.String tenant, java.lang.String cluster, java.lang.String namespaceAntiAffinityGroup)Get all namespaces that grouped with given anti-affinity group.java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>>getAntiAffinityNamespacesAsync(java.lang.String tenant, java.lang.String cluster, java.lang.String namespaceAntiAffinityGroup)Get all namespaces that grouped with given anti-affinity group asynchronously.java.util.Map<BacklogQuota.BacklogQuotaType,BacklogQuota>getBacklogQuotaMap(java.lang.String namespace)Get backlog quota map on a namespace.java.util.concurrent.CompletableFuture<java.util.Map<BacklogQuota.BacklogQuotaType,BacklogQuota>>getBacklogQuotaMapAsync(java.lang.String namespace)Get backlog quota map on a namespace asynchronously.BookieAffinityGroupDatagetBookieAffinityGroup(java.lang.String namespace)Get bookie affinity group configured for a namespace.java.util.concurrent.CompletableFuture<BookieAffinityGroupData>getBookieAffinityGroupAsync(java.lang.String namespace)Get bookie affinity group configured for a namespace asynchronously.BundlesDatagetBundles(java.lang.String namespace)Get the list of bundles.java.util.concurrent.CompletableFuture<BundlesData>getBundlesAsync(java.lang.String namespace)Get the list of bundles asynchronously.java.lang.LonggetCompactionThreshold(java.lang.String namespace)Get the compactionThreshold for a namespace.java.util.concurrent.CompletableFuture<java.lang.Long>getCompactionThresholdAsync(java.lang.String namespace)Get the compactionThreshold for a namespace asynchronously.java.lang.IntegergetDeduplicationSnapshotInterval(java.lang.String namespace)Get the deduplicationSnapshotInterval for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getDeduplicationSnapshotIntervalAsync(java.lang.String namespace)Get the deduplicationSnapshotInterval for a namespace asynchronously.java.lang.BooleangetDeduplicationStatus(java.lang.String namespace)Get the deduplication status for all topics within a namespace .java.util.concurrent.CompletableFuture<java.lang.Boolean>getDeduplicationStatusAsync(java.lang.String namespace)Get the deduplication status for all topics within a namespace asynchronously.DelayedDeliveryPoliciesgetDelayedDelivery(java.lang.String namespace)Get the delayed delivery messages for all topics within a namespace.java.util.concurrent.CompletableFuture<DelayedDeliveryPolicies>getDelayedDeliveryAsync(java.lang.String namespace)Get the delayed delivery messages for all topics within a namespace asynchronously.DispatchRategetDispatchRate(java.lang.String namespace)Get message-dispatch-rate (topics under this namespace can dispatch this many messages per second).java.util.concurrent.CompletableFuture<DispatchRate>getDispatchRateAsync(java.lang.String namespace)Get message-dispatch-rate asynchronously.InactiveTopicPoliciesgetInactiveTopicPolicies(java.lang.String namespace)Get the inactive deletion strategy for all topics within a namespace synchronously.java.util.concurrent.CompletableFuture<InactiveTopicPolicies>getInactiveTopicPoliciesAsync(java.lang.String namespace)Get the inactive deletion strategy for all topics within a namespace asynchronously.booleangetIsAllowAutoUpdateSchema(java.lang.String namespace)Get whether allow auto update schema.java.util.concurrent.CompletableFuture<java.lang.Boolean>getIsAllowAutoUpdateSchemaAsync(java.lang.String namespace)Get whether allow auto update schema asynchronously.java.lang.IntegergetMaxConsumersPerSubscription(java.lang.String namespace)Get the maxConsumersPerSubscription for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getMaxConsumersPerSubscriptionAsync(java.lang.String namespace)Get the maxConsumersPerSubscription for a namespace asynchronously.java.lang.IntegergetMaxConsumersPerTopic(java.lang.String namespace)Get the maxProducersPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getMaxConsumersPerTopicAsync(java.lang.String namespace)Get the maxProducersPerTopic for a namespace asynchronously.java.lang.IntegergetMaxProducersPerTopic(java.lang.String namespace)Get the maxProducersPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getMaxProducersPerTopicAsync(java.lang.String namespace)Get the maxProducersPerTopic for a namespace asynchronously.java.lang.IntegergetMaxSubscriptionsPerTopic(java.lang.String namespace)Get the maxSubscriptionsPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getMaxSubscriptionsPerTopicAsync(java.lang.String namespace)Get the maxSubscriptionsPerTopic for a namespace asynchronously.intgetMaxTopicsPerNamespace(java.lang.String namespace)Get maxTopicsPerNamespace for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getMaxTopicsPerNamespaceAsync(java.lang.String namespace)Get maxTopicsPerNamespace for a namespace asynchronously.java.lang.IntegergetMaxUnackedMessagesPerConsumer(java.lang.String namespace)Get the maxUnackedMessagesPerConsumer for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getMaxUnackedMessagesPerConsumerAsync(java.lang.String namespace)Get the maxUnackedMessagesPerConsumer for a namespace asynchronously.java.lang.IntegergetMaxUnackedMessagesPerSubscription(java.lang.String namespace)Get the maxUnackedMessagesPerSubscription for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getMaxUnackedMessagesPerSubscriptionAsync(java.lang.String namespace)Get the maxUnackedMessagesPerSubscription for a namespace asynchronously.java.lang.StringgetNamespaceAntiAffinityGroup(java.lang.String namespace)Get anti-affinity group name for a namespace.java.util.concurrent.CompletableFuture<java.lang.String>getNamespaceAntiAffinityGroupAsync(java.lang.String namespace)Get anti-affinity group name for a namespace asynchronously.java.lang.IntegergetNamespaceMessageTTL(java.lang.String namespace)Get the message TTL for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getNamespaceMessageTTLAsync(java.lang.String namespace)Get the message TTL for a namespace asynchronously.java.util.List<java.lang.String>getNamespaceReplicationClusters(java.lang.String namespace)Get the replication clusters for a namespace.java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>>getNamespaceReplicationClustersAsync(java.lang.String namespace)Get the replication clusters for a namespace asynchronously.java.lang.StringgetNamespaceResourceGroup(java.lang.String namespace)Get the ResourceGroup for a namespace.java.util.concurrent.CompletableFuture<java.lang.String>getNamespaceResourceGroupAsync(java.lang.String namespace)Get the ResourceGroup for a namespace asynchronously.java.util.List<java.lang.String>getNamespaces(java.lang.String tenant)Get the list of namespaces.java.util.List<java.lang.String>getNamespaces(java.lang.String tenant, java.lang.String cluster)Deprecated.java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>>getNamespacesAsync(java.lang.String tenant)Get the list of namespaces asynchronously.java.lang.LonggetOffloadDeleteLagMs(java.lang.String namespace)Get the offload deletion lag for a namespace, in milliseconds.java.util.concurrent.CompletableFuture<java.lang.Long>getOffloadDeleteLagMsAsync(java.lang.String namespace)Get the offload deletion lag asynchronously for a namespace, in milliseconds.OffloadPoliciesgetOffloadPolicies(java.lang.String namespace)Get the offload configuration for a namespace.java.util.concurrent.CompletableFuture<OffloadPolicies>getOffloadPoliciesAsync(java.lang.String namespace)Get the offload configuration for a namespace asynchronously.longgetOffloadThreshold(java.lang.String namespace)Get the offloadThreshold for a namespace.java.util.concurrent.CompletableFuture<java.lang.Long>getOffloadThresholdAsync(java.lang.String namespace)Get the offloadThreshold for a namespace asynchronously.java.util.Map<java.lang.String,java.util.Set<AuthAction>>getPermissions(java.lang.String namespace)Get permissions on a namespace.java.util.concurrent.CompletableFuture<java.util.Map<java.lang.String,java.util.Set<AuthAction>>>getPermissionsAsync(java.lang.String namespace)Get permissions on a namespace asynchronously.PersistencePoliciesgetPersistence(java.lang.String namespace)Get the persistence configuration for a namespace.java.util.concurrent.CompletableFuture<PersistencePolicies>getPersistenceAsync(java.lang.String namespace)Get the persistence configuration for a namespace asynchronously.PoliciesgetPolicies(java.lang.String namespace)Get policies for a namespace.java.util.concurrent.CompletableFuture<Policies>getPoliciesAsync(java.lang.String namespace)Get policies for a namespace asynchronously.java.util.Map<java.lang.String,java.lang.String>getProperties(java.lang.String namespace)Get all properties of a namespace.java.util.concurrent.CompletableFuture<java.util.Map<java.lang.String,java.lang.String>>getPropertiesAsync(java.lang.String namespace)Get all properties of a namespace asynchronously.java.lang.StringgetProperty(java.lang.String namespace, java.lang.String key)Get property value for a given key.java.util.concurrent.CompletableFuture<java.lang.String>getPropertyAsync(java.lang.String namespace, java.lang.String key)Get property value for a given key.PublishRategetPublishRate(java.lang.String namespace)Get message-publish-rate (topics under this namespace can publish this many messages per second).java.util.concurrent.CompletableFuture<PublishRate>getPublishRateAsync(java.lang.String namespace)Get message-publish-rate (topics under this namespace can publish this many messages per second) asynchronously.java.lang.StringgetReplicationConfigVersion(java.lang.String namespace)Get the replication configuration version for a given namespace.java.util.concurrent.CompletableFuture<java.lang.String>getReplicationConfigVersionAsync(java.lang.String namespace)Get the replication configuration version for a given namespace asynchronously.DispatchRategetReplicatorDispatchRate(java.lang.String namespace)Get replicator-message-dispatch-rate.java.util.concurrent.CompletableFuture<DispatchRate>getReplicatorDispatchRateAsync(java.lang.String namespace)Get replicator-message-dispatch-rate asynchronously.RetentionPoliciesgetRetention(java.lang.String namespace)Get the retention configuration for a namespace.java.util.concurrent.CompletableFuture<RetentionPolicies>getRetentionAsync(java.lang.String namespace)Get the retention configuration for a namespace asynchronously.SchemaAutoUpdateCompatibilityStrategygetSchemaAutoUpdateCompatibilityStrategy(java.lang.String namespace)Deprecated.SchemaCompatibilityStrategygetSchemaCompatibilityStrategy(java.lang.String namespace)Get the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed.java.util.concurrent.CompletableFuture<SchemaCompatibilityStrategy>getSchemaCompatibilityStrategyAsync(java.lang.String namespace)Get the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed asynchronously.booleangetSchemaValidationEnforced(java.lang.String namespace)Get schema validation enforced for namespace.java.util.concurrent.CompletableFuture<java.lang.Boolean>getSchemaValidationEnforcedAsync(java.lang.String namespace)Get schema validation enforced for namespace asynchronously.SubscribeRategetSubscribeRate(java.lang.String namespace)Get namespace-subscribe-rate (topics under this namespace allow subscribe times per consumer in a period).java.util.concurrent.CompletableFuture<SubscribeRate>getSubscribeRateAsync(java.lang.String namespace)Get namespace-subscribe-rate asynchronously.DispatchRategetSubscriptionDispatchRate(java.lang.String namespace)Get subscription-message-dispatch-rate.java.util.concurrent.CompletableFuture<DispatchRate>getSubscriptionDispatchRateAsync(java.lang.String namespace)Get subscription-message-dispatch-rate asynchronously.intgetSubscriptionExpirationTime(java.lang.String namespace)Get the subscription expiration time for a namespace.java.util.concurrent.CompletableFuture<java.lang.Integer>getSubscriptionExpirationTimeAsync(java.lang.String namespace)Get the subscription expiration time for a namespace asynchronously.java.util.Set<org.apache.pulsar.client.api.SubscriptionType>getSubscriptionTypesEnabled(java.lang.String namespace)Get the subscriptionTypesEnabled policy for a given namespace, overriding broker settings.java.util.concurrent.CompletableFuture<java.util.Set<org.apache.pulsar.client.api.SubscriptionType>>getSubscriptionTypesEnabledAsync(java.lang.String namespace)Get the subscriptionTypesEnabled policy for a given namespace, overriding broker settings.java.util.List<java.lang.String>getTopics(java.lang.String namespace)Get the list of topics.java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>>getTopicsAsync(java.lang.String namespace)Get the list of topics asynchronously.voidgrantPermissionOnNamespace(java.lang.String namespace, java.lang.String role, java.util.Set<AuthAction> actions)Grant permission on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>grantPermissionOnNamespaceAsync(java.lang.String namespace, java.lang.String role, java.util.Set<AuthAction> actions)Grant permission on a namespace asynchronously.voidgrantPermissionOnSubscription(java.lang.String namespace, java.lang.String subscription, java.util.Set<java.lang.String> roles)Grant permission to role to access subscription's admin-api.java.util.concurrent.CompletableFuture<java.lang.Void>grantPermissionOnSubscriptionAsync(java.lang.String namespace, java.lang.String subscription, java.util.Set<java.lang.String> roles)Grant permission to role to access subscription's admin-api asynchronously.voidremoveAutoSubscriptionCreation(java.lang.String namespace)Removes the autoSubscriptionCreation policy for a given namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeAutoSubscriptionCreationAsync(java.lang.String namespace)Removes the autoSubscriptionCreation policy for a given namespace asynchronously.voidremoveAutoTopicCreation(java.lang.String namespace)Removes the autoTopicCreation policy for a given namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeAutoTopicCreationAsync(java.lang.String namespace)Removes the autoTopicCreation policy for a given namespace asynchronously.voidremoveBacklogQuota(java.lang.String namespace)Remove a backlog quota policy from a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeBacklogQuotaAsync(java.lang.String namespace)Remove a backlog quota policy from a namespace asynchronously.voidremoveCompactionThreshold(java.lang.String namespace)Delete the compactionThreshold for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeCompactionThresholdAsync(java.lang.String namespace)Delete the compactionThreshold for a namespace asynchronously.voidremoveDeduplicationSnapshotInterval(java.lang.String namespace)Remove the deduplicationSnapshotInterval for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeDeduplicationSnapshotIntervalAsync(java.lang.String namespace)Remove the deduplicationSnapshotInterval for a namespace asynchronously.voidremoveDeduplicationStatus(java.lang.String namespace)Remove the deduplication status for all topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeDeduplicationStatusAsync(java.lang.String namespace)Get the deduplication status for all topics within a namespace asynchronously.voidremoveDelayedDeliveryMessages(java.lang.String namespace)Remove the delayed delivery messages for all topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeDelayedDeliveryMessagesAsync(java.lang.String namespace)Remove the delayed delivery messages for all topics within a namespace asynchronously.voidremoveDispatchRate(java.lang.String namespace)Remove message-dispatch-rate.java.util.concurrent.CompletableFuture<java.lang.Void>removeDispatchRateAsync(java.lang.String namespace)Remove message-dispatch-rate asynchronously.voidremoveInactiveTopicPolicies(java.lang.String namespace)Remove inactive topic policies from a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeInactiveTopicPoliciesAsync(java.lang.String namespace)remove InactiveTopicPolicies from a namespace asynchronously.voidremoveMaxConsumersPerSubscription(java.lang.String namespace)Remove maxConsumersPerSubscription for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeMaxConsumersPerSubscriptionAsync(java.lang.String namespace)Remove maxConsumersPerSubscription for a namespace asynchronously.voidremoveMaxConsumersPerTopic(java.lang.String namespace)Remove maxConsumersPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeMaxConsumersPerTopicAsync(java.lang.String namespace)Remove maxConsumersPerTopic for a namespace asynchronously.voidremoveMaxProducersPerTopic(java.lang.String namespace)Remove maxProducersPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeMaxProducersPerTopicAsync(java.lang.String namespace)Set maxProducersPerTopic for a namespace asynchronously.voidremoveMaxSubscriptionsPerTopic(java.lang.String namespace)Remove the maxSubscriptionsPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeMaxSubscriptionsPerTopicAsync(java.lang.String namespace)Remove the maxSubscriptionsPerTopic for a namespace asynchronously.voidremoveMaxTopicsPerNamespace(java.lang.String namespace)remove maxTopicsPerNamespace for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeMaxTopicsPerNamespaceAsync(java.lang.String namespace)remove maxTopicsPerNamespace for a namespace asynchronously.voidremoveMaxUnackedMessagesPerConsumer(java.lang.String namespace)Remove maxUnackedMessagesPerConsumer for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeMaxUnackedMessagesPerConsumerAsync(java.lang.String namespace)Remove maxUnackedMessagesPerConsumer for a namespace asynchronously.voidremoveMaxUnackedMessagesPerSubscription(java.lang.String namespace)Remove maxUnackedMessagesPerSubscription for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeMaxUnackedMessagesPerSubscriptionAsync(java.lang.String namespace)Remove maxUnackedMessagesPerSubscription for a namespace asynchronously.voidremoveNamespaceMessageTTL(java.lang.String namespace)Remove the messages Time to Live for all the topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeNamespaceMessageTTLAsync(java.lang.String namespace)Remove the messages Time to Live for all the topics within a namespace asynchronously.voidremoveNamespaceResourceGroup(java.lang.String namespace)Remove the ResourceGroup on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeNamespaceResourceGroupAsync(java.lang.String namespace)Remove the ResourceGroup on a namespace asynchronously.voidremoveOffloadPolicies(java.lang.String namespace)Remove the offload configuration for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeOffloadPoliciesAsync(java.lang.String namespace)Remove the offload configuration for a namespace asynchronously.voidremovePersistence(java.lang.String namespace)Remove the persistence configuration on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removePersistenceAsync(java.lang.String namespace)Remove the persistence configuration on a namespace asynchronously.java.lang.StringremoveProperty(java.lang.String namespace, java.lang.String key)Remove a property for a given key.java.util.concurrent.CompletableFuture<java.lang.String>removePropertyAsync(java.lang.String namespace, java.lang.String key)Remove a property for a given key.voidremovePublishRate(java.lang.String namespace)Remove message-publish-rate (topics under this namespace can publish this many messages per second).java.util.concurrent.CompletableFuture<java.lang.Void>removePublishRateAsync(java.lang.String namespace)Remove message-publish-rate asynchronously.voidremoveReplicatorDispatchRate(java.lang.String namespace)Remove replicator-message-dispatch-rate.java.util.concurrent.CompletableFuture<java.lang.Void>removeReplicatorDispatchRateAsync(java.lang.String namespace)Set replicator-message-dispatch-rate asynchronously.voidremoveRetention(java.lang.String namespace)Remove the retention configuration for all the topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>removeRetentionAsync(java.lang.String namespace)Remove the retention configuration for all the topics on a namespace asynchronously.voidremoveSubscribeRate(java.lang.String namespace)Remove namespace-subscribe-rate (topics under this namespace will limit by subscribeRate).java.util.concurrent.CompletableFuture<java.lang.Void>removeSubscribeRateAsync(java.lang.String namespace)Remove namespace-subscribe-rate (topics under this namespace will limit by subscribeRate) asynchronously.voidremoveSubscriptionDispatchRate(java.lang.String namespace)Remove subscription-message-dispatch-rate.java.util.concurrent.CompletableFuture<java.lang.Void>removeSubscriptionDispatchRateAsync(java.lang.String namespace)Remove subscription-message-dispatch-rate asynchronously.voidrevokePermissionOnSubscription(java.lang.String namespace, java.lang.String subscription, java.lang.String role)Revoke permissions on a subscription's admin-api access.java.util.concurrent.CompletableFuture<java.lang.Void>revokePermissionOnSubscriptionAsync(java.lang.String namespace, java.lang.String subscription, java.lang.String role)Revoke permissions on a subscription's admin-api access asynchronously.voidrevokePermissionsOnNamespace(java.lang.String namespace, java.lang.String role)Revoke permissions on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>revokePermissionsOnNamespaceAsync(java.lang.String namespace, java.lang.String role)Revoke permissions on a namespace asynchronously.voidsetAutoSubscriptionCreation(java.lang.String namespace, AutoSubscriptionCreationOverride autoSubscriptionCreationOverride)Sets the autoSubscriptionCreation policy for a given namespace, overriding broker settings.java.util.concurrent.CompletableFuture<java.lang.Void>setAutoSubscriptionCreationAsync(java.lang.String namespace, AutoSubscriptionCreationOverride autoSubscriptionCreationOverride)Sets the autoSubscriptionCreation policy for a given namespace, overriding broker settings asynchronously.voidsetAutoTopicCreation(java.lang.String namespace, AutoTopicCreationOverride autoTopicCreationOverride)Sets the autoTopicCreation policy for a given namespace, overriding broker settings.java.util.concurrent.CompletableFuture<java.lang.Void>setAutoTopicCreationAsync(java.lang.String namespace, AutoTopicCreationOverride autoTopicCreationOverride)Sets the autoTopicCreation policy for a given namespace, overriding broker settings asynchronously.voidsetBacklogQuota(java.lang.String namespace, BacklogQuota backlogQuota)Set a backlog quota for all the topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setBacklogQuotaAsync(java.lang.String namespace, BacklogQuota backlogQuota)Set a backlog quota for all the topics on a namespace asynchronously.voidsetBookieAffinityGroup(java.lang.String namespace, BookieAffinityGroupData bookieAffinityGroup)Set bookie affinity group for a namespace to isolate namespace write to bookies that are part of given affinity group.java.util.concurrent.CompletableFuture<java.lang.Void>setBookieAffinityGroupAsync(java.lang.String namespace, BookieAffinityGroupData bookieAffinityGroup)Set bookie affinity group for a namespace to isolate namespace write to bookies that are part of given affinity group asynchronously.voidsetCompactionThreshold(java.lang.String namespace, long compactionThreshold)Set the compactionThreshold for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setCompactionThresholdAsync(java.lang.String namespace, long compactionThreshold)Set the compactionThreshold for a namespace asynchronously.voidsetDeduplicationSnapshotInterval(java.lang.String namespace, java.lang.Integer interval)Set the deduplicationSnapshotInterval for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setDeduplicationSnapshotIntervalAsync(java.lang.String namespace, java.lang.Integer interval)Set the deduplicationSnapshotInterval for a namespace asynchronously.voidsetDeduplicationStatus(java.lang.String namespace, boolean enableDeduplication)Set the deduplication status for all topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setDeduplicationStatusAsync(java.lang.String namespace, boolean enableDeduplication)Set the deduplication status for all topics within a namespace asynchronously.voidsetDelayedDeliveryMessages(java.lang.String namespace, DelayedDeliveryPolicies delayedDeliveryPolicies)Set the delayed delivery messages for all topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setDelayedDeliveryMessagesAsync(java.lang.String namespace, DelayedDeliveryPolicies delayedDeliveryPolicies)Set the delayed delivery messages for all topics within a namespace asynchronously.voidsetDispatchRate(java.lang.String namespace, DispatchRate dispatchRate)Set message-dispatch-rate (topics under this namespace can dispatch this many messages per second).java.util.concurrent.CompletableFuture<java.lang.Void>setDispatchRateAsync(java.lang.String namespace, DispatchRate dispatchRate)Set message-dispatch-rate asynchronously.voidsetEncryptionRequiredStatus(java.lang.String namespace, boolean encryptionRequired)Set the encryption required status for all topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setEncryptionRequiredStatusAsync(java.lang.String namespace, boolean encryptionRequired)Set the encryption required status for all topics within a namespace asynchronously.voidsetInactiveTopicPolicies(java.lang.String namespace, InactiveTopicPolicies inactiveTopicPolicies)As same as setInactiveTopicPoliciesAsync,but it is synchronous.java.util.concurrent.CompletableFuture<java.lang.Void>setInactiveTopicPoliciesAsync(java.lang.String namespace, InactiveTopicPolicies inactiveTopicPolicies)You can set the inactive deletion strategy at the namespace level.voidsetIsAllowAutoUpdateSchema(java.lang.String namespace, boolean isAllowAutoUpdateSchema)Set whether to allow automatic schema updates.java.util.concurrent.CompletableFuture<java.lang.Void>setIsAllowAutoUpdateSchemaAsync(java.lang.String namespace, boolean isAllowAutoUpdateSchema)Set whether to allow automatic schema updates asynchronously.voidsetMaxConsumersPerSubscription(java.lang.String namespace, int maxConsumersPerSubscription)Set maxConsumersPerSubscription for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setMaxConsumersPerSubscriptionAsync(java.lang.String namespace, int maxConsumersPerSubscription)Set maxConsumersPerSubscription for a namespace asynchronously.voidsetMaxConsumersPerTopic(java.lang.String namespace, int maxConsumersPerTopic)Set maxConsumersPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setMaxConsumersPerTopicAsync(java.lang.String namespace, int maxConsumersPerTopic)Set maxConsumersPerTopic for a namespace asynchronously.voidsetMaxProducersPerTopic(java.lang.String namespace, int maxProducersPerTopic)Set maxProducersPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setMaxProducersPerTopicAsync(java.lang.String namespace, int maxProducersPerTopic)Set maxProducersPerTopic for a namespace asynchronously.voidsetMaxSubscriptionsPerTopic(java.lang.String namespace, int maxSubscriptionsPerTopic)Set the maxSubscriptionsPerTopic for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setMaxSubscriptionsPerTopicAsync(java.lang.String namespace, int maxSubscriptionsPerTopic)Set the maxSubscriptionsPerTopic for a namespace asynchronously.voidsetMaxTopicsPerNamespace(java.lang.String namespace, int maxTopicsPerNamespace)Set maxTopicsPerNamespace for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setMaxTopicsPerNamespaceAsync(java.lang.String namespace, int maxTopicsPerNamespace)Set maxTopicsPerNamespace for a namespace asynchronously.voidsetMaxUnackedMessagesPerConsumer(java.lang.String namespace, int maxUnackedMessagesPerConsumer)Set maxUnackedMessagesPerConsumer for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setMaxUnackedMessagesPerConsumerAsync(java.lang.String namespace, int maxUnackedMessagesPerConsumer)Set maxUnackedMessagesPerConsumer for a namespace asynchronously.voidsetMaxUnackedMessagesPerSubscription(java.lang.String namespace, int maxUnackedMessagesPerSubscription)Set maxUnackedMessagesPerSubscription for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setMaxUnackedMessagesPerSubscriptionAsync(java.lang.String namespace, int maxUnackedMessagesPerSubscription)Set maxUnackedMessagesPerSubscription for a namespace asynchronously.voidsetNamespaceAntiAffinityGroup(java.lang.String namespace, java.lang.String namespaceAntiAffinityGroup)Set anti-affinity group name for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setNamespaceAntiAffinityGroupAsync(java.lang.String namespace, java.lang.String namespaceAntiAffinityGroup)Set anti-affinity group name for a namespace asynchronously.voidsetNamespaceMessageTTL(java.lang.String namespace, int ttlInSeconds)Set the messages Time to Live for all the topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setNamespaceMessageTTLAsync(java.lang.String namespace, int ttlInSeconds)Set the messages Time to Live for all the topics within a namespace asynchronously.voidsetNamespaceReplicationClusters(java.lang.String namespace, java.util.Set<java.lang.String> clusterIds)Set the replication clusters for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setNamespaceReplicationClustersAsync(java.lang.String namespace, java.util.Set<java.lang.String> clusterIds)Set the replication clusters for a namespace asynchronously.voidsetNamespaceResourceGroup(java.lang.String namespace, java.lang.String resourcegroupname)Set the ResourceGroup for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setNamespaceResourceGroupAsync(java.lang.String namespace, java.lang.String resourcegroupname)Set the ResourceGroup for a namespace asynchronously.voidsetOffloadDeleteLag(java.lang.String namespace, long lag, java.util.concurrent.TimeUnit unit)Set the offload deletion lag for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setOffloadDeleteLagAsync(java.lang.String namespace, long lag, java.util.concurrent.TimeUnit unit)Set the offload deletion lag for a namespace asynchronously.voidsetOffloadPolicies(java.lang.String namespace, OffloadPolicies offloadPolicies)Set the offload configuration for all the topics in a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setOffloadPoliciesAsync(java.lang.String namespace, OffloadPolicies offloadPolicies)Set the offload configuration for all the topics in a namespace asynchronously.voidsetOffloadThreshold(java.lang.String namespace, long offloadThreshold)Set the offloadThreshold for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setOffloadThresholdAsync(java.lang.String namespace, long offloadThreshold)Set the offloadThreshold for a namespace asynchronously.voidsetPersistence(java.lang.String namespace, PersistencePolicies persistence)Set the persistence configuration for all the topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setPersistenceAsync(java.lang.String namespace, PersistencePolicies persistence)Set the persistence configuration for all the topics on a namespace asynchronously.voidsetProperties(java.lang.String namespace, java.util.Map<java.lang.String,java.lang.String> properties)Set key value pair properties for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setPropertiesAsync(java.lang.String namespace, java.util.Map<java.lang.String,java.lang.String> properties)Set key value pair properties for a namespace asynchronously.voidsetProperty(java.lang.String namespace, java.lang.String key, java.lang.String value)Set key value pair property for a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setPropertyAsync(java.lang.String namespace, java.lang.String key, java.lang.String value)<<<<<<< HEAD Set key value pair property for a namespace.voidsetPublishRate(java.lang.String namespace, PublishRate publishMsgRate)Set message-publish-rate (topics under this namespace can publish this many messages per second).java.util.concurrent.CompletableFuture<java.lang.Void>setPublishRateAsync(java.lang.String namespace, PublishRate publishMsgRate)Set message-publish-rate (topics under this namespace can publish this many messages per second) asynchronously.voidsetReplicatorDispatchRate(java.lang.String namespace, DispatchRate dispatchRate)Set replicator-message-dispatch-rate.java.util.concurrent.CompletableFuture<java.lang.Void>setReplicatorDispatchRateAsync(java.lang.String namespace, DispatchRate dispatchRate)Set replicator-message-dispatch-rate asynchronously.voidsetRetention(java.lang.String namespace, RetentionPolicies retention)Set the retention configuration for all the topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setRetentionAsync(java.lang.String namespace, RetentionPolicies retention)Set the retention configuration for all the topics on a namespace asynchronously.voidsetSchemaAutoUpdateCompatibilityStrategy(java.lang.String namespace, SchemaAutoUpdateCompatibilityStrategy strategy)Deprecated.voidsetSchemaCompatibilityStrategy(java.lang.String namespace, SchemaCompatibilityStrategy strategy)Set the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed.java.util.concurrent.CompletableFuture<java.lang.Void>setSchemaCompatibilityStrategyAsync(java.lang.String namespace, SchemaCompatibilityStrategy strategy)Set the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed asynchronously.voidsetSchemaValidationEnforced(java.lang.String namespace, boolean schemaValidationEnforced)Set schema validation enforced for namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setSchemaValidationEnforcedAsync(java.lang.String namespace, boolean schemaValidationEnforced)Set schema validation enforced for namespace asynchronously.voidsetSubscribeRate(java.lang.String namespace, SubscribeRate subscribeRate)Set namespace-subscribe-rate (topics under this namespace will limit by subscribeRate).java.util.concurrent.CompletableFuture<java.lang.Void>setSubscribeRateAsync(java.lang.String namespace, SubscribeRate subscribeRate)Set namespace-subscribe-rate (topics under this namespace will limit by subscribeRate) asynchronously.voidsetSubscriptionAuthMode(java.lang.String namespace, SubscriptionAuthMode subscriptionAuthMode)Set the given subscription auth mode on all topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setSubscriptionAuthModeAsync(java.lang.String namespace, SubscriptionAuthMode subscriptionAuthMode)Set the given subscription auth mode on all topics on a namespace asynchronously.voidsetSubscriptionDispatchRate(java.lang.String namespace, DispatchRate dispatchRate)Set subscription-message-dispatch-rate.java.util.concurrent.CompletableFuture<java.lang.Void>setSubscriptionDispatchRateAsync(java.lang.String namespace, DispatchRate dispatchRate)Set subscription-message-dispatch-rate asynchronously.voidsetSubscriptionExpirationTime(java.lang.String namespace, int expirationTime)Set the subscription expiration time in minutes for all the topics within a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>setSubscriptionExpirationTimeAsync(java.lang.String namespace, int expirationTime)Set the subscription expiration time in minutes for all the topics within a namespace asynchronously.voidsetSubscriptionTypesEnabled(java.lang.String namespace, java.util.Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled)Sets the subscriptionTypesEnabled policy for a given namespace, overriding broker settings.java.util.concurrent.CompletableFuture<java.lang.Void>setSubscriptionTypesEnabledAsync(java.lang.String namespace, java.util.Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled)Sets the subscriptionTypesEnabled policy for a given namespace, overriding broker settings.voidsplitNamespaceBundle(java.lang.String namespace, java.lang.String bundle, boolean unloadSplitBundles, java.lang.String splitAlgorithmName)Split namespace bundle.java.util.concurrent.CompletableFuture<java.lang.Void>splitNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundle, boolean unloadSplitBundles, java.lang.String splitAlgorithmName)Split namespace bundle asynchronously.voidunload(java.lang.String namespace)Unload a namespace from the current serving broker.java.util.concurrent.CompletableFuture<java.lang.Void>unloadAsync(java.lang.String namespace)Unload a namespace from the current serving broker asynchronously.voidunloadNamespaceBundle(java.lang.String namespace, java.lang.String bundle)Unload namespace bundle.java.util.concurrent.CompletableFuture<java.lang.Void>unloadNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundle)Unload namespace bundle asynchronously.voidunsubscribeNamespace(java.lang.String namespace, java.lang.String subscription)Unsubscribe the given subscription on all topics on a namespace.java.util.concurrent.CompletableFuture<java.lang.Void>unsubscribeNamespaceAsync(java.lang.String namespace, java.lang.String subscription)Unsubscribe the given subscription on all topics on a namespace asynchronously.voidunsubscribeNamespaceBundle(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription)Unsubscribe the given subscription on all topics on a namespace bundle.java.util.concurrent.CompletableFuture<java.lang.Void>unsubscribeNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription)Unsubscribe the given subscription on all topics on a namespace bundle asynchronously.
-
-
-
Method Detail
-
getNamespaces
java.util.List<java.lang.String> getNamespaces(java.lang.String tenant) throws PulsarAdminExceptionGet the list of namespaces. Get the list of all the namespaces for a certain tenant. Response Example:["my-tenant/c1/namespace1", "my-tenant/global/namespace2", "my-tenant/c2/namespace3"]- Parameters:
tenant- Tenant name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Tenant does not existPulsarAdminException- Unexpected error
-
getNamespacesAsync
java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>> getNamespacesAsync(java.lang.String tenant)
Get the list of namespaces asynchronously. Get the list of all the namespaces for a certain tenant. Response Example:["my-tenant/c1/namespace1", "my-tenant/global/namespace2", "my-tenant/c2/namespace3"]- Parameters:
tenant- Tenant name
-
getNamespaces
@Deprecated java.util.List<java.lang.String> getNamespaces(java.lang.String tenant, java.lang.String cluster) throws PulsarAdminExceptionDeprecated.Get the list of namespaces. Get the list of all the namespaces for a certain tenant on single cluster. Response Example:["my-tenant/use/namespace1", "my-tenant/use/namespace2"]- Parameters:
tenant- Tenant namecluster- Cluster name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Tenant or cluster does not existPulsarAdminException- Unexpected error
-
getTopics
java.util.List<java.lang.String> getTopics(java.lang.String namespace) throws PulsarAdminExceptionGet the list of topics. Get the list of all the topics under a certain namespace. Response Example:["persistent://my-tenant/use/namespace1/my-topic-1", "persistent://my-tenant/use/namespace1/my-topic-2"]- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getTopicsAsync
java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>> getTopicsAsync(java.lang.String namespace)
Get the list of topics asynchronously. Get the list of all the topics under a certain namespace. Response Example:["persistent://my-tenant/use/namespace1/my-topic-1", "persistent://my-tenant/use/namespace1/my-topic-2"]- Parameters:
namespace- Namespace name
-
getBundles
BundlesData getBundles(java.lang.String namespace) throws PulsarAdminException
Get the list of bundles. Get the list of all the bundles under a certain namespace.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getBundlesAsync
java.util.concurrent.CompletableFuture<BundlesData> getBundlesAsync(java.lang.String namespace)
Get the list of bundles asynchronously. Get the list of all the bundles under a certain namespace.- Parameters:
namespace- Namespace name
-
getPolicies
Policies getPolicies(java.lang.String namespace) throws PulsarAdminException
Get policies for a namespace. Get the dump all the policies specified for a namespace. Response example:{ "auth_policies" : { "namespace_auth" : { "my-role" : [ "produce" ] }, "destination_auth" : { "persistent://prop/local/ns1/my-topic" : { "role-1" : [ "produce" ], "role-2" : [ "consume" ] } } }, "replication_clusters" : ["use", "usw"], "message_ttl_in_seconds" : 300 }- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error- See Also:
Policies
-
getPoliciesAsync
java.util.concurrent.CompletableFuture<Policies> getPoliciesAsync(java.lang.String namespace)
Get policies for a namespace asynchronously. Get the dump all the policies specified for a namespace. Response example:{ "auth_policies" : { "namespace_auth" : { "my-role" : [ "produce" ] }, "destination_auth" : { "persistent://prop/local/ns1/my-topic" : { "role-1" : [ "produce" ], "role-2" : [ "consume" ] } } }, "replication_clusters" : ["use", "usw"], "message_ttl_in_seconds" : 300 }- Parameters:
namespace- Namespace name- See Also:
Policies
-
createNamespace
void createNamespace(java.lang.String namespace, int numBundles) throws PulsarAdminExceptionCreate a new namespace. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace namenumBundles- Number of bundles- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Tenant or cluster does not existPulsarAdminException.ConflictException- Namespace already existsPulsarAdminException- Unexpected error
-
createNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> createNamespaceAsync(java.lang.String namespace, int numBundles)Create a new namespace. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace namenumBundles- Number of bundles
-
createNamespace
void createNamespace(java.lang.String namespace, BundlesData bundlesData) throws PulsarAdminExceptionCreate a new namespace. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace namebundlesData- Bundles Data- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Tenant or cluster does not existPulsarAdminException.ConflictException- Namespace already existsPulsarAdminException- Unexpected error
-
createNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> createNamespaceAsync(java.lang.String namespace, BundlesData bundlesData)Create a new namespace asynchronously. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace namebundlesData- Bundles Data
-
createNamespace
void createNamespace(java.lang.String namespace) throws PulsarAdminExceptionCreate a new namespace. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Tenant or cluster does not existPulsarAdminException.ConflictException- Namespace already existsPulsarAdminException- Unexpected error
-
createNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> createNamespaceAsync(java.lang.String namespace)
Create a new namespace asynchronously. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace name
-
createNamespace
void createNamespace(java.lang.String namespace, java.util.Set<java.lang.String> clusters) throws PulsarAdminExceptionCreate a new namespace. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace nameclusters- Clusters in which the namespace will be present. If more than one cluster is present, replication across clusters will be enabled.- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Tenant or cluster does not existPulsarAdminException.ConflictException- Namespace already existsPulsarAdminException- Unexpected error
-
createNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> createNamespaceAsync(java.lang.String namespace, java.util.Set<java.lang.String> clusters)Create a new namespace asynchronously. Creates a new empty namespace with no policies attached.- Parameters:
namespace- Namespace nameclusters- Clusters in which the namespace will be present. If more than one cluster is present, replication across clusters will be enabled.
-
createNamespace
void createNamespace(java.lang.String namespace, Policies policies) throws PulsarAdminExceptionCreate a new namespace. Creates a new namespace with the specified policies.- Parameters:
namespace- Namespace namepolicies- Policies for the namespace- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Tenant or cluster does not existPulsarAdminException.ConflictException- Namespace already existsPulsarAdminException- Unexpected error- Since:
- 2.0
-
createNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> createNamespaceAsync(java.lang.String namespace, Policies policies)Create a new namespace asynchronously. Creates a new namespace with the specified policies.- Parameters:
namespace- Namespace namepolicies- Policies for the namespace
-
deleteNamespace
void deleteNamespace(java.lang.String namespace) throws PulsarAdminExceptionDelete an existing namespace. The namespace needs to be empty.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Namespace is not emptyPulsarAdminException- Unexpected error
-
deleteNamespace
void deleteNamespace(java.lang.String namespace, boolean force) throws PulsarAdminExceptionDelete an existing namespace. Force flag deletes namespace forcefully by force deleting all topics under it.- Parameters:
namespace- Namespace nameforce- Delete namespace forcefully- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Namespace is not emptyPulsarAdminException- Unexpected error
-
deleteNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> deleteNamespaceAsync(java.lang.String namespace)
Delete an existing namespace asynchronously. The namespace needs to be empty.- Parameters:
namespace- Namespace name
-
deleteNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> deleteNamespaceAsync(java.lang.String namespace, boolean force)Delete an existing namespace asynchronously. Force flag deletes namespace forcefully by force deleting all topics under it.- Parameters:
namespace- Namespace nameforce- Delete namespace forcefully
-
deleteNamespaceBundle
void deleteNamespaceBundle(java.lang.String namespace, java.lang.String bundleRange) throws PulsarAdminExceptionDelete an existing bundle in a namespace. The bundle needs to be empty.- Parameters:
namespace- Namespace namebundleRange- range of the bundle- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace/bundle does not existPulsarAdminException.ConflictException- Bundle is not emptyPulsarAdminException- Unexpected error
-
deleteNamespaceBundle
void deleteNamespaceBundle(java.lang.String namespace, java.lang.String bundleRange, boolean force) throws PulsarAdminExceptionDelete an existing bundle in a namespace. Force flag deletes bundle forcefully.- Parameters:
namespace- Namespace namebundleRange- range of the bundleforce- Delete bundle forcefully- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace/bundle does not existPulsarAdminException.ConflictException- Bundle is not emptyPulsarAdminException- Unexpected error
-
deleteNamespaceBundleAsync
java.util.concurrent.CompletableFuture<java.lang.Void> deleteNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundleRange)Delete an existing bundle in a namespace asynchronously. The bundle needs to be empty.- Parameters:
namespace- Namespace namebundleRange- range of the bundle- Returns:
- a future that can be used to track when the bundle is deleted
-
deleteNamespaceBundleAsync
java.util.concurrent.CompletableFuture<java.lang.Void> deleteNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundleRange, boolean force)Delete an existing bundle in a namespace asynchronously. Force flag deletes bundle forcefully.- Parameters:
namespace- Namespace namebundleRange- range of the bundleforce- Delete bundle forcefully- Returns:
- a future that can be used to track when the bundle is deleted
-
getPermissions
java.util.Map<java.lang.String,java.util.Set<AuthAction>> getPermissions(java.lang.String namespace) throws PulsarAdminException
Get permissions on a namespace. Retrieve the permissions for a namespace. Response example:{ "my-role" : [ "produce" ] "other-role" : [ "consume" ] }- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getPermissionsAsync
java.util.concurrent.CompletableFuture<java.util.Map<java.lang.String,java.util.Set<AuthAction>>> getPermissionsAsync(java.lang.String namespace)
Get permissions on a namespace asynchronously. Retrieve the permissions for a namespace. Response example:{ "my-role" : [ "produce" ] "other-role" : [ "consume" ] }- Parameters:
namespace- Namespace name
-
grantPermissionOnNamespace
void grantPermissionOnNamespace(java.lang.String namespace, java.lang.String role, java.util.Set<AuthAction> actions) throws PulsarAdminExceptionGrant permission on a namespace. Grant a new permission to a client role on a namespace. Request parameter example:["produce", "consume"]- Parameters:
namespace- Namespace namerole- Client role to which grant permissionactions- Auth actions (produce and consume)- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
grantPermissionOnNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> grantPermissionOnNamespaceAsync(java.lang.String namespace, java.lang.String role, java.util.Set<AuthAction> actions)Grant permission on a namespace asynchronously. Grant a new permission to a client role on a namespace. Request parameter example:["produce", "consume"]- Parameters:
namespace- Namespace namerole- Client role to which grant permissionactions- Auth actions (produce and consume)
-
revokePermissionsOnNamespace
void revokePermissionsOnNamespace(java.lang.String namespace, java.lang.String role) throws PulsarAdminExceptionRevoke permissions on a namespace. Revoke all permissions to a client role on a namespace.- Parameters:
namespace- Namespace namerole- Client role to which remove permissions- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
revokePermissionsOnNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> revokePermissionsOnNamespaceAsync(java.lang.String namespace, java.lang.String role)Revoke permissions on a namespace asynchronously. Revoke all permissions to a client role on a namespace.- Parameters:
namespace- Namespace namerole- Client role to which remove permissions
-
grantPermissionOnSubscription
void grantPermissionOnSubscription(java.lang.String namespace, java.lang.String subscription, java.util.Set<java.lang.String> roles) throws PulsarAdminExceptionGrant permission to role to access subscription's admin-api.- Parameters:
namespace-subscription-roles-- Throws:
PulsarAdminException
-
grantPermissionOnSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> grantPermissionOnSubscriptionAsync(java.lang.String namespace, java.lang.String subscription, java.util.Set<java.lang.String> roles)Grant permission to role to access subscription's admin-api asynchronously.- Parameters:
namespace-subscription-roles-
-
revokePermissionOnSubscription
void revokePermissionOnSubscription(java.lang.String namespace, java.lang.String subscription, java.lang.String role) throws PulsarAdminExceptionRevoke permissions on a subscription's admin-api access.- Parameters:
namespace-subscription-role-- Throws:
PulsarAdminException
-
revokePermissionOnSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> revokePermissionOnSubscriptionAsync(java.lang.String namespace, java.lang.String subscription, java.lang.String role)Revoke permissions on a subscription's admin-api access asynchronously.- Parameters:
namespace-subscription-role-
-
getNamespaceReplicationClusters
java.util.List<java.lang.String> getNamespaceReplicationClusters(java.lang.String namespace) throws PulsarAdminExceptionGet the replication clusters for a namespace. Response example:["use", "usw", "usc"]- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.PreconditionFailedException- Namespace is not globalPulsarAdminException- Unexpected error
-
getNamespaceReplicationClustersAsync
java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>> getNamespaceReplicationClustersAsync(java.lang.String namespace)
Get the replication clusters for a namespace asynchronously. Response example:["use", "usw", "usc"]- Parameters:
namespace- Namespace name
-
setNamespaceReplicationClusters
void setNamespaceReplicationClusters(java.lang.String namespace, java.util.Set<java.lang.String> clusterIds) throws PulsarAdminExceptionSet the replication clusters for a namespace. Request example:["us-west", "us-east", "us-cent"]- Parameters:
namespace- Namespace nameclusterIds- Pulsar Cluster Ids- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.PreconditionFailedException- Namespace is not globalPulsarAdminException.PreconditionFailedException- Invalid cluster idsPulsarAdminException- Unexpected error
-
setNamespaceReplicationClustersAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setNamespaceReplicationClustersAsync(java.lang.String namespace, java.util.Set<java.lang.String> clusterIds)Set the replication clusters for a namespace asynchronously. Request example:["us-west", "us-east", "us-cent"]- Parameters:
namespace- Namespace nameclusterIds- Pulsar Cluster Ids
-
getNamespaceMessageTTL
java.lang.Integer getNamespaceMessageTTL(java.lang.String namespace) throws PulsarAdminExceptionGet the message TTL for a namespace. Response example:60- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getNamespaceMessageTTLAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getNamespaceMessageTTLAsync(java.lang.String namespace)
Get the message TTL for a namespace asynchronously. Response example:60- Parameters:
namespace- Namespace name
-
setNamespaceMessageTTL
void setNamespaceMessageTTL(java.lang.String namespace, int ttlInSeconds) throws PulsarAdminExceptionSet the messages Time to Live for all the topics within a namespace. Request example:60- Parameters:
namespace- Namespace namettlInSeconds- TTL values for all messages for all topics in this namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setNamespaceMessageTTLAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setNamespaceMessageTTLAsync(java.lang.String namespace, int ttlInSeconds)Set the messages Time to Live for all the topics within a namespace asynchronously. Request example:60- Parameters:
namespace- Namespace namettlInSeconds- TTL values for all messages for all topics in this namespace
-
removeNamespaceMessageTTL
void removeNamespaceMessageTTL(java.lang.String namespace) throws PulsarAdminExceptionRemove the messages Time to Live for all the topics within a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeNamespaceMessageTTLAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeNamespaceMessageTTLAsync(java.lang.String namespace)
Remove the messages Time to Live for all the topics within a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getSubscriptionExpirationTime
int getSubscriptionExpirationTime(java.lang.String namespace) throws PulsarAdminExceptionGet the subscription expiration time for a namespace. Response example:1440- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getSubscriptionExpirationTimeAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getSubscriptionExpirationTimeAsync(java.lang.String namespace)
Get the subscription expiration time for a namespace asynchronously. Response example:1440- Parameters:
namespace- Namespace name
-
setSubscriptionExpirationTime
void setSubscriptionExpirationTime(java.lang.String namespace, int expirationTime) throws PulsarAdminExceptionSet the subscription expiration time in minutes for all the topics within a namespace. Request example:1440- Parameters:
namespace- Namespace nameexpirationTime- Expiration time values for all subscriptions for all topics in this namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setSubscriptionExpirationTimeAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setSubscriptionExpirationTimeAsync(java.lang.String namespace, int expirationTime)Set the subscription expiration time in minutes for all the topics within a namespace asynchronously. Request example:1440- Parameters:
namespace- Namespace nameexpirationTime- Expiration time values for all subscriptions for all topics in this namespace
-
setNamespaceAntiAffinityGroup
void setNamespaceAntiAffinityGroup(java.lang.String namespace, java.lang.String namespaceAntiAffinityGroup) throws PulsarAdminExceptionSet anti-affinity group name for a namespace. Request example:- Parameters:
namespace- Namespace namenamespaceAntiAffinityGroup- anti-affinity group name for a namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setNamespaceAntiAffinityGroupAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setNamespaceAntiAffinityGroupAsync(java.lang.String namespace, java.lang.String namespaceAntiAffinityGroup)Set anti-affinity group name for a namespace asynchronously. Request example:- Parameters:
namespace- Namespace namenamespaceAntiAffinityGroup- anti-affinity group name for a namespace
-
getAntiAffinityNamespaces
java.util.List<java.lang.String> getAntiAffinityNamespaces(java.lang.String tenant, java.lang.String cluster, java.lang.String namespaceAntiAffinityGroup) throws PulsarAdminExceptionGet all namespaces that grouped with given anti-affinity group.- Parameters:
tenant- tenant is only used for authorization. Client has to be admin of any of the tenant to access this api api.cluster- cluster namenamespaceAntiAffinityGroup- Anti-affinity group name- Returns:
- list of namespace grouped under a given anti-affinity group
- Throws:
PulsarAdminException
-
getAntiAffinityNamespacesAsync
java.util.concurrent.CompletableFuture<java.util.List<java.lang.String>> getAntiAffinityNamespacesAsync(java.lang.String tenant, java.lang.String cluster, java.lang.String namespaceAntiAffinityGroup)Get all namespaces that grouped with given anti-affinity group asynchronously.- Parameters:
tenant- tenant is only used for authorization. Client has to be admin of any of the tenant to access this api api.cluster- cluster namenamespaceAntiAffinityGroup- Anti-affinity group name- Returns:
- list of namespace grouped under a given anti-affinity group
-
getNamespaceAntiAffinityGroup
java.lang.String getNamespaceAntiAffinityGroup(java.lang.String namespace) throws PulsarAdminExceptionGet anti-affinity group name for a namespace. Response example:60- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getNamespaceAntiAffinityGroupAsync
java.util.concurrent.CompletableFuture<java.lang.String> getNamespaceAntiAffinityGroupAsync(java.lang.String namespace)
Get anti-affinity group name for a namespace asynchronously. Response example:60- Parameters:
namespace- Namespace name
-
deleteNamespaceAntiAffinityGroup
void deleteNamespaceAntiAffinityGroup(java.lang.String namespace) throws PulsarAdminExceptionDelete anti-affinity group name for a namespace.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- You don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
deleteNamespaceAntiAffinityGroupAsync
java.util.concurrent.CompletableFuture<java.lang.Void> deleteNamespaceAntiAffinityGroupAsync(java.lang.String namespace)
Delete anti-affinity group name for a namespace.- Parameters:
namespace- Namespace name
-
removeDeduplicationStatus
void removeDeduplicationStatus(java.lang.String namespace) throws PulsarAdminExceptionRemove the deduplication status for all topics within a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeDeduplicationStatusAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeDeduplicationStatusAsync(java.lang.String namespace)
Get the deduplication status for all topics within a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getDeduplicationStatus
java.lang.Boolean getDeduplicationStatus(java.lang.String namespace) throws PulsarAdminExceptionGet the deduplication status for all topics within a namespace .- Parameters:
namespace-- Returns:
- Throws:
PulsarAdminException
-
getDeduplicationStatusAsync
java.util.concurrent.CompletableFuture<java.lang.Boolean> getDeduplicationStatusAsync(java.lang.String namespace)
Get the deduplication status for all topics within a namespace asynchronously.- Parameters:
namespace-- Returns:
-
setDeduplicationStatus
void setDeduplicationStatus(java.lang.String namespace, boolean enableDeduplication) throws PulsarAdminExceptionSet the deduplication status for all topics within a namespace. When deduplication is enabled, the broker will prevent to store the same message multiple times. Request example:true- Parameters:
namespace- Namespace nameenableDeduplication- wether to enable or disable deduplication feature- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setDeduplicationStatusAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setDeduplicationStatusAsync(java.lang.String namespace, boolean enableDeduplication)Set the deduplication status for all topics within a namespace asynchronously. When deduplication is enabled, the broker will prevent to store the same message multiple times. Request example:true- Parameters:
namespace- Namespace nameenableDeduplication- wether to enable or disable deduplication feature
-
setAutoTopicCreation
void setAutoTopicCreation(java.lang.String namespace, AutoTopicCreationOverride autoTopicCreationOverride) throws PulsarAdminExceptionSets the autoTopicCreation policy for a given namespace, overriding broker settings. When autoTopicCreationOverride is enabled, new topics will be created upon connection, regardless of the broker level configuration. Request example:{ "allowAutoTopicCreation" : true, "topicType" : "partitioned", "defaultNumPartitions": 2 }- Parameters:
namespace- Namespace nameautoTopicCreationOverride- Override policies for auto topic creation- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setAutoTopicCreationAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setAutoTopicCreationAsync(java.lang.String namespace, AutoTopicCreationOverride autoTopicCreationOverride)Sets the autoTopicCreation policy for a given namespace, overriding broker settings asynchronously. When autoTopicCreationOverride is enabled, new topics will be created upon connection, regardless of the broker level configuration. Request example:{ "allowAutoTopicCreation" : true, "topicType" : "partitioned", "defaultNumPartitions": 2 }- Parameters:
namespace- Namespace nameautoTopicCreationOverride- Override policies for auto topic creation
-
removeAutoTopicCreation
void removeAutoTopicCreation(java.lang.String namespace) throws PulsarAdminExceptionRemoves the autoTopicCreation policy for a given namespace. Allowing the broker to dictate the auto-creation policy.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
removeAutoTopicCreationAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeAutoTopicCreationAsync(java.lang.String namespace)
Removes the autoTopicCreation policy for a given namespace asynchronously. Allowing the broker to dictate the auto-creation policy.- Parameters:
namespace- Namespace name
-
setAutoSubscriptionCreation
void setAutoSubscriptionCreation(java.lang.String namespace, AutoSubscriptionCreationOverride autoSubscriptionCreationOverride) throws PulsarAdminExceptionSets the autoSubscriptionCreation policy for a given namespace, overriding broker settings. When autoSubscriptionCreationOverride is enabled, new subscriptions will be created upon connection, regardless of the broker level configuration. Request example:{ "allowAutoSubscriptionCreation" : true }- Parameters:
namespace- Namespace nameautoSubscriptionCreationOverride- Override policies for auto subscription creation- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setAutoSubscriptionCreationAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setAutoSubscriptionCreationAsync(java.lang.String namespace, AutoSubscriptionCreationOverride autoSubscriptionCreationOverride)Sets the autoSubscriptionCreation policy for a given namespace, overriding broker settings asynchronously. When autoSubscriptionCreationOverride is enabled, new subscriptions will be created upon connection, regardless of the broker level configuration. Request example:{ "allowAutoSubscriptionCreation" : true }- Parameters:
namespace- Namespace nameautoSubscriptionCreationOverride- Override policies for auto subscription creation
-
setSubscriptionTypesEnabled
void setSubscriptionTypesEnabled(java.lang.String namespace, java.util.Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled) throws PulsarAdminExceptionSets the subscriptionTypesEnabled policy for a given namespace, overriding broker settings. Request example:{ "subscriptionTypesEnabled" : {"Shared", "Failover"} }- Parameters:
namespace- Namespace namesubscriptionTypesEnabled- is enable subscription types- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setSubscriptionTypesEnabledAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setSubscriptionTypesEnabledAsync(java.lang.String namespace, java.util.Set<org.apache.pulsar.client.api.SubscriptionType> subscriptionTypesEnabled)Sets the subscriptionTypesEnabled policy for a given namespace, overriding broker settings. Request example:{ "subscriptionTypesEnabled" : {"Shared", "Failover"} }- Parameters:
namespace- Namespace namesubscriptionTypesEnabled- is enable subscription types
-
getSubscriptionTypesEnabled
java.util.Set<org.apache.pulsar.client.api.SubscriptionType> getSubscriptionTypesEnabled(java.lang.String namespace) throws PulsarAdminExceptionGet the subscriptionTypesEnabled policy for a given namespace, overriding broker settings.- Parameters:
namespace- Namespace name- Returns:
- subscription types
Setthe subscription types - Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getSubscriptionTypesEnabledAsync
java.util.concurrent.CompletableFuture<java.util.Set<org.apache.pulsar.client.api.SubscriptionType>> getSubscriptionTypesEnabledAsync(java.lang.String namespace)
Get the subscriptionTypesEnabled policy for a given namespace, overriding broker settings.- Parameters:
namespace- Namespace name- Returns:
- the future of subscription types
Setthe subscription types
-
removeAutoSubscriptionCreation
void removeAutoSubscriptionCreation(java.lang.String namespace) throws PulsarAdminExceptionRemoves the autoSubscriptionCreation policy for a given namespace. Allowing the broker to dictate the subscription auto-creation policy.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
removeAutoSubscriptionCreationAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeAutoSubscriptionCreationAsync(java.lang.String namespace)
Removes the autoSubscriptionCreation policy for a given namespace asynchronously. Allowing the broker to dictate the subscription auto-creation policy.- Parameters:
namespace- Namespace name
-
getBacklogQuotaMap
java.util.Map<BacklogQuota.BacklogQuotaType,BacklogQuota> getBacklogQuotaMap(java.lang.String namespace) throws PulsarAdminException
Get backlog quota map on a namespace. Get backlog quota map on a namespace. Response example:{ "namespace_memory" : { "limit" : "134217728", "policy" : "consumer_backlog_eviction" }, "destination_storage" : { "limit" : "-1", "policy" : "producer_exception" } }- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Permission deniedPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getBacklogQuotaMapAsync
java.util.concurrent.CompletableFuture<java.util.Map<BacklogQuota.BacklogQuotaType,BacklogQuota>> getBacklogQuotaMapAsync(java.lang.String namespace)
Get backlog quota map on a namespace asynchronously. Get backlog quota map on a namespace. Response example:{ "namespace_memory" : { "limit" : "134217728", "policy" : "consumer_backlog_eviction" }, "destination_storage" : { "limit" : "-1", "policy" : "producer_exception" } }- Parameters:
namespace- Namespace name
-
setBacklogQuota
void setBacklogQuota(java.lang.String namespace, BacklogQuota backlogQuota) throws PulsarAdminExceptionSet a backlog quota for all the topics on a namespace. Set a backlog quota on a namespace. The backlog quota can be set on this resource: Request parameter example:{ "limit" : "134217728", "policy" : "consumer_backlog_eviction" }- Parameters:
namespace- Namespace namebacklogQuota- the new BacklogQuota- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setBacklogQuotaAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setBacklogQuotaAsync(java.lang.String namespace, BacklogQuota backlogQuota)Set a backlog quota for all the topics on a namespace asynchronously. Set a backlog quota on a namespace. The backlog quota can be set on this resource: Request parameter example:{ "limit" : "134217728", "policy" : "consumer_backlog_eviction" }- Parameters:
namespace- Namespace namebacklogQuota- the new BacklogQuota
-
removeBacklogQuota
void removeBacklogQuota(java.lang.String namespace) throws PulsarAdminExceptionRemove a backlog quota policy from a namespace. Remove a backlog quota policy from a namespace. The backlog retention policy will fall back to the default.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
removeBacklogQuotaAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeBacklogQuotaAsync(java.lang.String namespace)
Remove a backlog quota policy from a namespace asynchronously. Remove a backlog quota policy from a namespace. The backlog retention policy will fall back to the default.- Parameters:
namespace- Namespace name
-
removePersistence
void removePersistence(java.lang.String namespace) throws PulsarAdminExceptionRemove the persistence configuration on a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removePersistenceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removePersistenceAsync(java.lang.String namespace)
Remove the persistence configuration on a namespace asynchronously.- Parameters:
namespace-
-
setPersistence
void setPersistence(java.lang.String namespace, PersistencePolicies persistence) throws PulsarAdminExceptionSet the persistence configuration for all the topics on a namespace. Set the persistence configuration on a namespace. Request parameter example:{ "bookkeeperEnsemble" : 3, // Number of bookies to use for a topic "bookkeeperWriteQuorum" : 2, // How many writes to make of each entry "bookkeeperAckQuorum" : 2, // Number of acks (guaranteed copies) to wait for each entry "managedLedgerMaxMarkDeleteRate" : 10.0, // Throttling rate of mark-delete operation // to avoid high number of updates for each // consumer }- Parameters:
namespace- Namespace namepersistence- Persistence policies object- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
setPersistenceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setPersistenceAsync(java.lang.String namespace, PersistencePolicies persistence)Set the persistence configuration for all the topics on a namespace asynchronously. Set the persistence configuration on a namespace. Request parameter example:{ "bookkeeperEnsemble" : 3, // Number of bookies to use for a topic "bookkeeperWriteQuorum" : 2, // How many writes to make of each entry "bookkeeperAckQuorum" : 2, // Number of acks (guaranteed copies) to wait for each entry "managedLedgerMaxMarkDeleteRate" : 10.0, // Throttling rate of mark-delete operation // to avoid high number of updates for each // consumer }- Parameters:
namespace- Namespace namepersistence- Persistence policies object
-
getPersistence
PersistencePolicies getPersistence(java.lang.String namespace) throws PulsarAdminException
Get the persistence configuration for a namespace. Get the persistence configuration for a namespace. Response example:{ "bookkeeperEnsemble" : 3, // Number of bookies to use for a topic "bookkeeperWriteQuorum" : 2, // How many writes to make of each entry "bookkeeperAckQuorum" : 2, // Number of acks (guaranteed copies) to wait for each entry "managedLedgerMaxMarkDeleteRate" : 10.0, // Throttling rate of mark-delete operation // to avoid high number of updates for each // consumer }- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
getPersistenceAsync
java.util.concurrent.CompletableFuture<PersistencePolicies> getPersistenceAsync(java.lang.String namespace)
Get the persistence configuration for a namespace asynchronously. Get the persistence configuration for a namespace. Response example:{ "bookkeeperEnsemble" : 3, // Number of bookies to use for a topic "bookkeeperWriteQuorum" : 2, // How many writes to make of each entry "bookkeeperAckQuorum" : 2, // Number of acks (guaranteed copies) to wait for each entry "managedLedgerMaxMarkDeleteRate" : 10.0, // Throttling rate of mark-delete operation // to avoid high number of updates for each // consumer }- Parameters:
namespace- Namespace name
-
setBookieAffinityGroup
void setBookieAffinityGroup(java.lang.String namespace, BookieAffinityGroupData bookieAffinityGroup) throws PulsarAdminExceptionSet bookie affinity group for a namespace to isolate namespace write to bookies that are part of given affinity group.- Parameters:
namespace- namespace namebookieAffinityGroup- bookie affinity group- Throws:
PulsarAdminException
-
setBookieAffinityGroupAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setBookieAffinityGroupAsync(java.lang.String namespace, BookieAffinityGroupData bookieAffinityGroup)Set bookie affinity group for a namespace to isolate namespace write to bookies that are part of given affinity group asynchronously.- Parameters:
namespace- namespace namebookieAffinityGroup- bookie affinity group
-
deleteBookieAffinityGroup
void deleteBookieAffinityGroup(java.lang.String namespace) throws PulsarAdminExceptionDelete bookie affinity group configured for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
deleteBookieAffinityGroupAsync
java.util.concurrent.CompletableFuture<java.lang.Void> deleteBookieAffinityGroupAsync(java.lang.String namespace)
Delete bookie affinity group configured for a namespace asynchronously.- Parameters:
namespace-
-
getBookieAffinityGroup
BookieAffinityGroupData getBookieAffinityGroup(java.lang.String namespace) throws PulsarAdminException
Get bookie affinity group configured for a namespace.- Parameters:
namespace-- Returns:
- Throws:
PulsarAdminException
-
getBookieAffinityGroupAsync
java.util.concurrent.CompletableFuture<BookieAffinityGroupData> getBookieAffinityGroupAsync(java.lang.String namespace)
Get bookie affinity group configured for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
setRetention
void setRetention(java.lang.String namespace, RetentionPolicies retention) throws PulsarAdminExceptionSet the retention configuration for all the topics on a namespace. Set the retention configuration on a namespace. This operation requires Pulsar super-user access. Request parameter example:{ "retentionTimeInMinutes" : 60, // how long to retain messages "retentionSizeInMB" : 1024, // retention backlog limit }- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
setRetentionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setRetentionAsync(java.lang.String namespace, RetentionPolicies retention)Set the retention configuration for all the topics on a namespace asynchronously. Set the retention configuration on a namespace. This operation requires Pulsar super-user access. Request parameter example:{ "retentionTimeInMinutes" : 60, // how long to retain messages "retentionSizeInMB" : 1024, // retention backlog limit }- Parameters:
namespace- Namespace name
-
removeRetention
void removeRetention(java.lang.String namespace) throws PulsarAdminExceptionRemove the retention configuration for all the topics on a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeRetentionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeRetentionAsync(java.lang.String namespace)
Remove the retention configuration for all the topics on a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getRetention
RetentionPolicies getRetention(java.lang.String namespace) throws PulsarAdminException
Get the retention configuration for a namespace. Get the retention configuration for a namespace. Response example:{ "retentionTimeInMinutes" : 60, // how long to retain messages "retentionSizeInMB" : 1024, // retention backlog limit }- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
getRetentionAsync
java.util.concurrent.CompletableFuture<RetentionPolicies> getRetentionAsync(java.lang.String namespace)
Get the retention configuration for a namespace asynchronously. Get the retention configuration for a namespace. Response example:{ "retentionTimeInMinutes" : 60, // how long to retain messages "retentionSizeInMB" : 1024, // retention backlog limit }- Parameters:
namespace- Namespace name
-
unload
void unload(java.lang.String namespace) throws PulsarAdminExceptionUnload a namespace from the current serving broker.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.PreconditionFailedException- Namespace is already unloadedPulsarAdminException- Unexpected error
-
unloadAsync
java.util.concurrent.CompletableFuture<java.lang.Void> unloadAsync(java.lang.String namespace)
Unload a namespace from the current serving broker asynchronously.- Parameters:
namespace- Namespace name
-
getReplicationConfigVersion
java.lang.String getReplicationConfigVersion(java.lang.String namespace) throws PulsarAdminExceptionGet the replication configuration version for a given namespace.- Parameters:
namespace-- Returns:
- Replication configuration version
- Throws:
PulsarAdminException- Unexpected error
-
getReplicationConfigVersionAsync
java.util.concurrent.CompletableFuture<java.lang.String> getReplicationConfigVersionAsync(java.lang.String namespace)
Get the replication configuration version for a given namespace asynchronously.- Parameters:
namespace-- Returns:
- Replication configuration version
-
unloadNamespaceBundle
void unloadNamespaceBundle(java.lang.String namespace, java.lang.String bundle) throws PulsarAdminExceptionUnload namespace bundle.- Parameters:
namespace-bundle- range of bundle to unload- Throws:
PulsarAdminException- Unexpected error
-
unloadNamespaceBundleAsync
java.util.concurrent.CompletableFuture<java.lang.Void> unloadNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundle)Unload namespace bundle asynchronously.- Parameters:
namespace-bundle- range of bundle to unload- Returns:
- a future that can be used to track when the bundle is unloaded
-
splitNamespaceBundle
void splitNamespaceBundle(java.lang.String namespace, java.lang.String bundle, boolean unloadSplitBundles, java.lang.String splitAlgorithmName) throws PulsarAdminExceptionSplit namespace bundle.- Parameters:
namespace-bundle- range of bundle to splitunloadSplitBundles-splitAlgorithmName-- Throws:
PulsarAdminException
-
splitNamespaceBundleAsync
java.util.concurrent.CompletableFuture<java.lang.Void> splitNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundle, boolean unloadSplitBundles, java.lang.String splitAlgorithmName)Split namespace bundle asynchronously.- Parameters:
namespace-bundle- range of bundle to splitunloadSplitBundles-splitAlgorithmName-
-
setPublishRate
void setPublishRate(java.lang.String namespace, PublishRate publishMsgRate) throws PulsarAdminExceptionSet message-publish-rate (topics under this namespace can publish this many messages per second).- Parameters:
namespace-publishMsgRate- number of messages per second- Throws:
PulsarAdminException- Unexpected error
-
removePublishRate
void removePublishRate(java.lang.String namespace) throws PulsarAdminExceptionRemove message-publish-rate (topics under this namespace can publish this many messages per second).- Parameters:
namespace-- Throws:
PulsarAdminException- Unexpected error
-
setPublishRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setPublishRateAsync(java.lang.String namespace, PublishRate publishMsgRate)Set message-publish-rate (topics under this namespace can publish this many messages per second) asynchronously.- Parameters:
namespace-publishMsgRate- number of messages per second
-
removePublishRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removePublishRateAsync(java.lang.String namespace)
Remove message-publish-rate asynchronously. topics under this namespace can publish this many messages per second- Parameters:
namespace-
-
getPublishRate
PublishRate getPublishRate(java.lang.String namespace) throws PulsarAdminException
Get message-publish-rate (topics under this namespace can publish this many messages per second).- Parameters:
namespace-- Returns:
- number of messages per second
- Throws:
PulsarAdminException- Unexpected error
-
getPublishRateAsync
java.util.concurrent.CompletableFuture<PublishRate> getPublishRateAsync(java.lang.String namespace)
Get message-publish-rate (topics under this namespace can publish this many messages per second) asynchronously.- Parameters:
namespace-- Returns:
- number of messages per second
-
removeDispatchRate
void removeDispatchRate(java.lang.String namespace) throws PulsarAdminExceptionRemove message-dispatch-rate.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeDispatchRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeDispatchRateAsync(java.lang.String namespace)
Remove message-dispatch-rate asynchronously.- Parameters:
namespace-- Returns:
-
setDispatchRate
void setDispatchRate(java.lang.String namespace, DispatchRate dispatchRate) throws PulsarAdminExceptionSet message-dispatch-rate (topics under this namespace can dispatch this many messages per second).- Parameters:
namespace-dispatchRate- number of messages per second- Throws:
PulsarAdminException- Unexpected error
-
setDispatchRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setDispatchRateAsync(java.lang.String namespace, DispatchRate dispatchRate)Set message-dispatch-rate asynchronously. topics under this namespace can dispatch this many messages per second- Parameters:
namespace-dispatchRate- number of messages per second
-
getDispatchRate
DispatchRate getDispatchRate(java.lang.String namespace) throws PulsarAdminException
Get message-dispatch-rate (topics under this namespace can dispatch this many messages per second).- Parameters:
namespace-- Throws:
PulsarAdminException- Unexpected error
-
getDispatchRateAsync
java.util.concurrent.CompletableFuture<DispatchRate> getDispatchRateAsync(java.lang.String namespace)
Get message-dispatch-rate asynchronously. Topics under this namespace can dispatch this many messages per second.- Parameters:
namespace-
-
setSubscribeRate
void setSubscribeRate(java.lang.String namespace, SubscribeRate subscribeRate) throws PulsarAdminExceptionSet namespace-subscribe-rate (topics under this namespace will limit by subscribeRate).- Parameters:
namespace-subscribeRate- consumer subscribe limit by this subscribeRate- Throws:
PulsarAdminException- Unexpected error
-
setSubscribeRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setSubscribeRateAsync(java.lang.String namespace, SubscribeRate subscribeRate)Set namespace-subscribe-rate (topics under this namespace will limit by subscribeRate) asynchronously.- Parameters:
namespace-subscribeRate- consumer subscribe limit by this subscribeRate
-
removeSubscribeRate
void removeSubscribeRate(java.lang.String namespace) throws PulsarAdminExceptionRemove namespace-subscribe-rate (topics under this namespace will limit by subscribeRate).- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeSubscribeRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeSubscribeRateAsync(java.lang.String namespace)
Remove namespace-subscribe-rate (topics under this namespace will limit by subscribeRate) asynchronously.- Parameters:
namespace-
-
getSubscribeRate
SubscribeRate getSubscribeRate(java.lang.String namespace) throws PulsarAdminException
Get namespace-subscribe-rate (topics under this namespace allow subscribe times per consumer in a period).- Parameters:
namespace-- Throws:
PulsarAdminException- Unexpected error
-
getSubscribeRateAsync
java.util.concurrent.CompletableFuture<SubscribeRate> getSubscribeRateAsync(java.lang.String namespace)
Get namespace-subscribe-rate asynchronously. Topics under this namespace allow subscribe times per consumer in a period.- Parameters:
namespace-
-
removeSubscriptionDispatchRate
void removeSubscriptionDispatchRate(java.lang.String namespace) throws PulsarAdminExceptionRemove subscription-message-dispatch-rate.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeSubscriptionDispatchRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeSubscriptionDispatchRateAsync(java.lang.String namespace)
Remove subscription-message-dispatch-rate asynchronously.- Parameters:
namespace-- Returns:
-
setSubscriptionDispatchRate
void setSubscriptionDispatchRate(java.lang.String namespace, DispatchRate dispatchRate) throws PulsarAdminExceptionSet subscription-message-dispatch-rate. Subscriptions under this namespace can dispatch this many messages per second- Parameters:
namespace-dispatchRate- number of messages per second- Throws:
PulsarAdminException- Unexpected error
-
setSubscriptionDispatchRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setSubscriptionDispatchRateAsync(java.lang.String namespace, DispatchRate dispatchRate)Set subscription-message-dispatch-rate asynchronously. Subscriptions under this namespace can dispatch this many messages per second.- Parameters:
namespace-dispatchRate- number of messages per second
-
getSubscriptionDispatchRate
DispatchRate getSubscriptionDispatchRate(java.lang.String namespace) throws PulsarAdminException
Get subscription-message-dispatch-rate. Subscriptions under this namespace can dispatch this many messages per second.- Parameters:
namespace-- Throws:
PulsarAdminException- Unexpected error
-
getSubscriptionDispatchRateAsync
java.util.concurrent.CompletableFuture<DispatchRate> getSubscriptionDispatchRateAsync(java.lang.String namespace)
Get subscription-message-dispatch-rate asynchronously. Subscriptions under this namespace can dispatch this many messages per second.- Parameters:
namespace-
-
setReplicatorDispatchRate
void setReplicatorDispatchRate(java.lang.String namespace, DispatchRate dispatchRate) throws PulsarAdminExceptionSet replicator-message-dispatch-rate. Replicators under this namespace can dispatch this many messages per second.- Parameters:
namespace-dispatchRate- number of messages per second- Throws:
PulsarAdminException- Unexpected error
-
setReplicatorDispatchRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setReplicatorDispatchRateAsync(java.lang.String namespace, DispatchRate dispatchRate)Set replicator-message-dispatch-rate asynchronously. Replicators under this namespace can dispatch this many messages per second.- Parameters:
namespace-dispatchRate- number of messages per second
-
removeReplicatorDispatchRate
void removeReplicatorDispatchRate(java.lang.String namespace) throws PulsarAdminExceptionRemove replicator-message-dispatch-rate.- Parameters:
namespace-- Throws:
PulsarAdminException- Unexpected error
-
removeReplicatorDispatchRateAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeReplicatorDispatchRateAsync(java.lang.String namespace)
Set replicator-message-dispatch-rate asynchronously.- Parameters:
namespace-
-
getReplicatorDispatchRate
DispatchRate getReplicatorDispatchRate(java.lang.String namespace) throws PulsarAdminException
Get replicator-message-dispatch-rate. Replicators under this namespace can dispatch this many messages per second.- Parameters:
namespace-- Throws:
PulsarAdminException- Unexpected error
-
getReplicatorDispatchRateAsync
java.util.concurrent.CompletableFuture<DispatchRate> getReplicatorDispatchRateAsync(java.lang.String namespace)
Get replicator-message-dispatch-rate asynchronously. Replicators under this namespace can dispatch this many messages per second.- Parameters:
namespace-
-
clearNamespaceBacklog
void clearNamespaceBacklog(java.lang.String namespace) throws PulsarAdminExceptionClear backlog for all topics on a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException- Unexpected error
-
clearNamespaceBacklogAsync
java.util.concurrent.CompletableFuture<java.lang.Void> clearNamespaceBacklogAsync(java.lang.String namespace)
Clear backlog for all topics on a namespace asynchronously.- Parameters:
namespace-
-
clearNamespaceBacklogForSubscription
void clearNamespaceBacklogForSubscription(java.lang.String namespace, java.lang.String subscription) throws PulsarAdminExceptionClear backlog for a given subscription on all topics on a namespace.- Parameters:
namespace-subscription-- Throws:
PulsarAdminException- Unexpected error
-
clearNamespaceBacklogForSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> clearNamespaceBacklogForSubscriptionAsync(java.lang.String namespace, java.lang.String subscription)Clear backlog for a given subscription on all topics on a namespace asynchronously.- Parameters:
namespace-subscription-
-
clearNamespaceBundleBacklog
void clearNamespaceBundleBacklog(java.lang.String namespace, java.lang.String bundle) throws PulsarAdminExceptionClear backlog for all topics on a namespace bundle.- Parameters:
namespace-bundle-- Throws:
PulsarAdminException- Unexpected error
-
clearNamespaceBundleBacklogAsync
java.util.concurrent.CompletableFuture<java.lang.Void> clearNamespaceBundleBacklogAsync(java.lang.String namespace, java.lang.String bundle)Clear backlog for all topics on a namespace bundle asynchronously.- Parameters:
namespace-bundle-- Returns:
- a future that can be used to track when the bundle is cleared
-
clearNamespaceBundleBacklogForSubscription
void clearNamespaceBundleBacklogForSubscription(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription) throws PulsarAdminExceptionClear backlog for a given subscription on all topics on a namespace bundle.- Parameters:
namespace-bundle-subscription-- Throws:
PulsarAdminException- Unexpected error
-
clearNamespaceBundleBacklogForSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> clearNamespaceBundleBacklogForSubscriptionAsync(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription)Clear backlog for a given subscription on all topics on a namespace bundle asynchronously.- Parameters:
namespace-bundle-subscription-- Returns:
- a future that can be used to track when the bundle is cleared
-
unsubscribeNamespace
void unsubscribeNamespace(java.lang.String namespace, java.lang.String subscription) throws PulsarAdminExceptionUnsubscribe the given subscription on all topics on a namespace.- Parameters:
namespace-subscription-- Throws:
PulsarAdminException
-
unsubscribeNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> unsubscribeNamespaceAsync(java.lang.String namespace, java.lang.String subscription)Unsubscribe the given subscription on all topics on a namespace asynchronously.- Parameters:
namespace-subscription-
-
unsubscribeNamespaceBundle
void unsubscribeNamespaceBundle(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription) throws PulsarAdminExceptionUnsubscribe the given subscription on all topics on a namespace bundle.- Parameters:
namespace-bundle-subscription-- Throws:
PulsarAdminException
-
unsubscribeNamespaceBundleAsync
java.util.concurrent.CompletableFuture<java.lang.Void> unsubscribeNamespaceBundleAsync(java.lang.String namespace, java.lang.String bundle, java.lang.String subscription)Unsubscribe the given subscription on all topics on a namespace bundle asynchronously.- Parameters:
namespace-bundle-subscription-- Returns:
- a future that can be used to track when the subscription is unsubscribed
-
setEncryptionRequiredStatus
void setEncryptionRequiredStatus(java.lang.String namespace, boolean encryptionRequired) throws PulsarAdminExceptionSet the encryption required status for all topics within a namespace. When encryption required is true, the broker will prevent to store unencrypted messages. Request example:true- Parameters:
namespace- Namespace nameencryptionRequired- whether message encryption is required or not- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setEncryptionRequiredStatusAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setEncryptionRequiredStatusAsync(java.lang.String namespace, boolean encryptionRequired)Set the encryption required status for all topics within a namespace asynchronously. When encryption required is true, the broker will prevent to store unencrypted messages. Request example:true- Parameters:
namespace- Namespace nameencryptionRequired- whether message encryption is required or not
-
getDelayedDelivery
DelayedDeliveryPolicies getDelayedDelivery(java.lang.String namespace) throws PulsarAdminException
Get the delayed delivery messages for all topics within a namespace. If disabled, messages will be immediately delivered and there will be no tracking overhead. Request example:{ "active" : true, // Enable or disable delayed delivery for messages on a namespace "tickTime" : 1000, // The tick time for when retrying on delayed delivery messages }- Parameters:
namespace- Namespace name- Returns:
- delayedDeliveryPolicies Whether to enable the delayed delivery for messages.
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getDelayedDeliveryAsync
java.util.concurrent.CompletableFuture<DelayedDeliveryPolicies> getDelayedDeliveryAsync(java.lang.String namespace)
Get the delayed delivery messages for all topics within a namespace asynchronously. If disabled, messages will be immediately delivered and there will be no tracking overhead. Request example:{ "active" : true, // Enable or disable delayed delivery for messages on a namespace "tickTime" : 1000, // The tick time for when retrying on delayed delivery messages }- Parameters:
namespace- Namespace name- Returns:
- delayedDeliveryPolicies Whether to enable the delayed delivery for messages.
-
setDelayedDeliveryMessages
void setDelayedDeliveryMessages(java.lang.String namespace, DelayedDeliveryPolicies delayedDeliveryPolicies) throws PulsarAdminExceptionSet the delayed delivery messages for all topics within a namespace. If disabled, messages will be immediately delivered and there will be no tracking overhead. Request example:{ "tickTime" : 1000, // Enable or disable delayed delivery for messages on a namespace "active" : true, // The tick time for when retrying on delayed delivery messages }- Parameters:
namespace- Namespace namedelayedDeliveryPolicies- Whether to enable the delayed delivery for messages.- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setDelayedDeliveryMessagesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setDelayedDeliveryMessagesAsync(java.lang.String namespace, DelayedDeliveryPolicies delayedDeliveryPolicies)Set the delayed delivery messages for all topics within a namespace asynchronously. If disabled, messages will be immediately delivered and there will be no tracking overhead. Request example:{ "tickTime" : 1000, // Enable or disable delayed delivery for messages on a namespace "active" : true, // The tick time for when retrying on delayed delivery messages }- Parameters:
namespace- Namespace namedelayedDeliveryPolicies- Whether to enable the delayed delivery for messages.
-
removeDelayedDeliveryMessages
void removeDelayedDeliveryMessages(java.lang.String namespace) throws PulsarAdminExceptionRemove the delayed delivery messages for all topics within a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeDelayedDeliveryMessagesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeDelayedDeliveryMessagesAsync(java.lang.String namespace)
Remove the delayed delivery messages for all topics within a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getInactiveTopicPolicies
InactiveTopicPolicies getInactiveTopicPolicies(java.lang.String namespace) throws PulsarAdminException
Get the inactive deletion strategy for all topics within a namespace synchronously.- Parameters:
namespace-- Returns:
- Throws:
PulsarAdminException
-
removeInactiveTopicPoliciesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeInactiveTopicPoliciesAsync(java.lang.String namespace)
remove InactiveTopicPolicies from a namespace asynchronously.- Parameters:
namespace-- Returns:
-
removeInactiveTopicPolicies
void removeInactiveTopicPolicies(java.lang.String namespace) throws PulsarAdminExceptionRemove inactive topic policies from a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
getInactiveTopicPoliciesAsync
java.util.concurrent.CompletableFuture<InactiveTopicPolicies> getInactiveTopicPoliciesAsync(java.lang.String namespace)
Get the inactive deletion strategy for all topics within a namespace asynchronously.- Parameters:
namespace-- Returns:
-
setInactiveTopicPolicies
void setInactiveTopicPolicies(java.lang.String namespace, InactiveTopicPolicies inactiveTopicPolicies) throws PulsarAdminExceptionAs same as setInactiveTopicPoliciesAsync,but it is synchronous.- Parameters:
namespace-inactiveTopicPolicies-- Throws:
PulsarAdminException
-
setInactiveTopicPoliciesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setInactiveTopicPoliciesAsync(java.lang.String namespace, InactiveTopicPolicies inactiveTopicPolicies)You can set the inactive deletion strategy at the namespace level. Its priority is higher than the inactive deletion strategy at the broker level. All topics under this namespace will follow this strategy.- Parameters:
namespace-inactiveTopicPolicies-- Returns:
-
setSubscriptionAuthMode
void setSubscriptionAuthMode(java.lang.String namespace, SubscriptionAuthMode subscriptionAuthMode) throws PulsarAdminExceptionSet the given subscription auth mode on all topics on a namespace.- Parameters:
namespace-subscriptionAuthMode-- Throws:
PulsarAdminException
-
setSubscriptionAuthModeAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setSubscriptionAuthModeAsync(java.lang.String namespace, SubscriptionAuthMode subscriptionAuthMode)Set the given subscription auth mode on all topics on a namespace asynchronously.- Parameters:
namespace-subscriptionAuthMode-
-
getDeduplicationSnapshotInterval
java.lang.Integer getDeduplicationSnapshotInterval(java.lang.String namespace) throws PulsarAdminExceptionGet the deduplicationSnapshotInterval for a namespace.- Parameters:
namespace-- Returns:
- Throws:
PulsarAdminException
-
getDeduplicationSnapshotIntervalAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getDeduplicationSnapshotIntervalAsync(java.lang.String namespace)
Get the deduplicationSnapshotInterval for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
setDeduplicationSnapshotInterval
void setDeduplicationSnapshotInterval(java.lang.String namespace, java.lang.Integer interval) throws PulsarAdminExceptionSet the deduplicationSnapshotInterval for a namespace.- Parameters:
namespace-interval-- Throws:
PulsarAdminException
-
setDeduplicationSnapshotIntervalAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setDeduplicationSnapshotIntervalAsync(java.lang.String namespace, java.lang.Integer interval)Set the deduplicationSnapshotInterval for a namespace asynchronously.- Parameters:
namespace-interval-- Returns:
-
removeDeduplicationSnapshotInterval
void removeDeduplicationSnapshotInterval(java.lang.String namespace) throws PulsarAdminExceptionRemove the deduplicationSnapshotInterval for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeDeduplicationSnapshotIntervalAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeDeduplicationSnapshotIntervalAsync(java.lang.String namespace)
Remove the deduplicationSnapshotInterval for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getMaxSubscriptionsPerTopic
java.lang.Integer getMaxSubscriptionsPerTopic(java.lang.String namespace) throws PulsarAdminExceptionGet the maxSubscriptionsPerTopic for a namespace.- Parameters:
namespace-- Returns:
- Throws:
PulsarAdminException
-
getMaxSubscriptionsPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getMaxSubscriptionsPerTopicAsync(java.lang.String namespace)
Get the maxSubscriptionsPerTopic for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
setMaxSubscriptionsPerTopic
void setMaxSubscriptionsPerTopic(java.lang.String namespace, int maxSubscriptionsPerTopic) throws PulsarAdminExceptionSet the maxSubscriptionsPerTopic for a namespace.- Parameters:
namespace-maxSubscriptionsPerTopic-- Throws:
PulsarAdminException
-
setMaxSubscriptionsPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setMaxSubscriptionsPerTopicAsync(java.lang.String namespace, int maxSubscriptionsPerTopic)Set the maxSubscriptionsPerTopic for a namespace asynchronously.- Parameters:
namespace-maxSubscriptionsPerTopic-- Returns:
-
removeMaxSubscriptionsPerTopic
void removeMaxSubscriptionsPerTopic(java.lang.String namespace) throws PulsarAdminExceptionRemove the maxSubscriptionsPerTopic for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeMaxSubscriptionsPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeMaxSubscriptionsPerTopicAsync(java.lang.String namespace)
Remove the maxSubscriptionsPerTopic for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getMaxProducersPerTopic
java.lang.Integer getMaxProducersPerTopic(java.lang.String namespace) throws PulsarAdminExceptionGet the maxProducersPerTopic for a namespace. Response example:0- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getMaxProducersPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getMaxProducersPerTopicAsync(java.lang.String namespace)
Get the maxProducersPerTopic for a namespace asynchronously. Response example:0- Parameters:
namespace- Namespace name
-
setMaxProducersPerTopic
void setMaxProducersPerTopic(java.lang.String namespace, int maxProducersPerTopic) throws PulsarAdminExceptionSet maxProducersPerTopic for a namespace. Request example:10- Parameters:
namespace- Namespace namemaxProducersPerTopic- maxProducersPerTopic value for a namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setMaxProducersPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setMaxProducersPerTopicAsync(java.lang.String namespace, int maxProducersPerTopic)Set maxProducersPerTopic for a namespace asynchronously. Request example:10- Parameters:
namespace- Namespace namemaxProducersPerTopic- maxProducersPerTopic value for a namespace
-
removeMaxProducersPerTopic
void removeMaxProducersPerTopic(java.lang.String namespace) throws PulsarAdminExceptionRemove maxProducersPerTopic for a namespace.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
removeMaxProducersPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeMaxProducersPerTopicAsync(java.lang.String namespace)
Set maxProducersPerTopic for a namespace asynchronously.- Parameters:
namespace- Namespace name
-
getMaxConsumersPerTopic
java.lang.Integer getMaxConsumersPerTopic(java.lang.String namespace) throws PulsarAdminExceptionGet the maxProducersPerTopic for a namespace. Response example:0- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getMaxConsumersPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getMaxConsumersPerTopicAsync(java.lang.String namespace)
Get the maxProducersPerTopic for a namespace asynchronously. Response example:0- Parameters:
namespace- Namespace name
-
setMaxConsumersPerTopic
void setMaxConsumersPerTopic(java.lang.String namespace, int maxConsumersPerTopic) throws PulsarAdminExceptionSet maxConsumersPerTopic for a namespace. Request example:10- Parameters:
namespace- Namespace namemaxConsumersPerTopic- maxConsumersPerTopic value for a namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setMaxConsumersPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setMaxConsumersPerTopicAsync(java.lang.String namespace, int maxConsumersPerTopic)Set maxConsumersPerTopic for a namespace asynchronously. Request example:10- Parameters:
namespace- Namespace namemaxConsumersPerTopic- maxConsumersPerTopic value for a namespace
-
removeMaxConsumersPerTopic
void removeMaxConsumersPerTopic(java.lang.String namespace) throws PulsarAdminExceptionRemove maxConsumersPerTopic for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeMaxConsumersPerTopicAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeMaxConsumersPerTopicAsync(java.lang.String namespace)
Remove maxConsumersPerTopic for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getMaxConsumersPerSubscription
java.lang.Integer getMaxConsumersPerSubscription(java.lang.String namespace) throws PulsarAdminExceptionGet the maxConsumersPerSubscription for a namespace. Response example:0- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getMaxConsumersPerSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getMaxConsumersPerSubscriptionAsync(java.lang.String namespace)
Get the maxConsumersPerSubscription for a namespace asynchronously. Response example:0- Parameters:
namespace- Namespace name
-
setMaxConsumersPerSubscription
void setMaxConsumersPerSubscription(java.lang.String namespace, int maxConsumersPerSubscription) throws PulsarAdminExceptionSet maxConsumersPerSubscription for a namespace. Request example:10- Parameters:
namespace- Namespace namemaxConsumersPerSubscription- maxConsumersPerSubscription value for a namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setMaxConsumersPerSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setMaxConsumersPerSubscriptionAsync(java.lang.String namespace, int maxConsumersPerSubscription)Set maxConsumersPerSubscription for a namespace asynchronously. Request example:10- Parameters:
namespace- Namespace namemaxConsumersPerSubscription- maxConsumersPerSubscription value for a namespace
-
removeMaxConsumersPerSubscription
void removeMaxConsumersPerSubscription(java.lang.String namespace) throws PulsarAdminExceptionRemove maxConsumersPerSubscription for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeMaxConsumersPerSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeMaxConsumersPerSubscriptionAsync(java.lang.String namespace)
Remove maxConsumersPerSubscription for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getMaxUnackedMessagesPerConsumer
java.lang.Integer getMaxUnackedMessagesPerConsumer(java.lang.String namespace) throws PulsarAdminExceptionGet the maxUnackedMessagesPerConsumer for a namespace. Response example:0- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getMaxUnackedMessagesPerConsumerAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getMaxUnackedMessagesPerConsumerAsync(java.lang.String namespace)
Get the maxUnackedMessagesPerConsumer for a namespace asynchronously. Response example:0- Parameters:
namespace- Namespace name
-
setMaxUnackedMessagesPerConsumer
void setMaxUnackedMessagesPerConsumer(java.lang.String namespace, int maxUnackedMessagesPerConsumer) throws PulsarAdminExceptionSet maxUnackedMessagesPerConsumer for a namespace. Request example:10- Parameters:
namespace- Namespace namemaxUnackedMessagesPerConsumer- maxUnackedMessagesPerConsumer value for a namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setMaxUnackedMessagesPerConsumerAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setMaxUnackedMessagesPerConsumerAsync(java.lang.String namespace, int maxUnackedMessagesPerConsumer)Set maxUnackedMessagesPerConsumer for a namespace asynchronously. Request example:10- Parameters:
namespace- Namespace namemaxUnackedMessagesPerConsumer- maxUnackedMessagesPerConsumer value for a namespace
-
removeMaxUnackedMessagesPerConsumer
void removeMaxUnackedMessagesPerConsumer(java.lang.String namespace) throws PulsarAdminExceptionRemove maxUnackedMessagesPerConsumer for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeMaxUnackedMessagesPerConsumerAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeMaxUnackedMessagesPerConsumerAsync(java.lang.String namespace)
Remove maxUnackedMessagesPerConsumer for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getMaxUnackedMessagesPerSubscription
java.lang.Integer getMaxUnackedMessagesPerSubscription(java.lang.String namespace) throws PulsarAdminExceptionGet the maxUnackedMessagesPerSubscription for a namespace. Response example:0- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getMaxUnackedMessagesPerSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getMaxUnackedMessagesPerSubscriptionAsync(java.lang.String namespace)
Get the maxUnackedMessagesPerSubscription for a namespace asynchronously. Response example:0- Parameters:
namespace- Namespace name
-
setMaxUnackedMessagesPerSubscription
void setMaxUnackedMessagesPerSubscription(java.lang.String namespace, int maxUnackedMessagesPerSubscription) throws PulsarAdminExceptionSet maxUnackedMessagesPerSubscription for a namespace. Request example:10- Parameters:
namespace- Namespace namemaxUnackedMessagesPerSubscription- Max number of unacknowledged messages allowed per shared subscription.- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setMaxUnackedMessagesPerSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setMaxUnackedMessagesPerSubscriptionAsync(java.lang.String namespace, int maxUnackedMessagesPerSubscription)Set maxUnackedMessagesPerSubscription for a namespace asynchronously. Request example:10- Parameters:
namespace- Namespace namemaxUnackedMessagesPerSubscription- Max number of unacknowledged messages allowed per shared subscription.
-
removeMaxUnackedMessagesPerSubscription
void removeMaxUnackedMessagesPerSubscription(java.lang.String namespace) throws PulsarAdminExceptionRemove maxUnackedMessagesPerSubscription for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeMaxUnackedMessagesPerSubscriptionAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeMaxUnackedMessagesPerSubscriptionAsync(java.lang.String namespace)
Remove maxUnackedMessagesPerSubscription for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getCompactionThreshold
java.lang.Long getCompactionThreshold(java.lang.String namespace) throws PulsarAdminExceptionGet the compactionThreshold for a namespace. The maximum number of bytes topics in the namespace can have before compaction is triggered. 0 disables. Response example:10000000- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getCompactionThresholdAsync
java.util.concurrent.CompletableFuture<java.lang.Long> getCompactionThresholdAsync(java.lang.String namespace)
Get the compactionThreshold for a namespace asynchronously. The maximum number of bytes topics in the namespace can have before compaction is triggered. 0 disables. Response example:10000000- Parameters:
namespace- Namespace name
-
setCompactionThreshold
void setCompactionThreshold(java.lang.String namespace, long compactionThreshold) throws PulsarAdminExceptionSet the compactionThreshold for a namespace. The maximum number of bytes topics in the namespace can have before compaction is triggered. 0 disables. Request example:10000000- Parameters:
namespace- Namespace namecompactionThreshold- maximum number of backlog bytes before compaction is triggered- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setCompactionThresholdAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setCompactionThresholdAsync(java.lang.String namespace, long compactionThreshold)Set the compactionThreshold for a namespace asynchronously. The maximum number of bytes topics in the namespace can have before compaction is triggered. 0 disables. Request example:10000000- Parameters:
namespace- Namespace namecompactionThreshold- maximum number of backlog bytes before compaction is triggered
-
removeCompactionThreshold
void removeCompactionThreshold(java.lang.String namespace) throws PulsarAdminExceptionDelete the compactionThreshold for a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeCompactionThresholdAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeCompactionThresholdAsync(java.lang.String namespace)
Delete the compactionThreshold for a namespace asynchronously.- Parameters:
namespace-- Returns:
-
getOffloadThreshold
long getOffloadThreshold(java.lang.String namespace) throws PulsarAdminExceptionGet the offloadThreshold for a namespace. The maximum number of bytes stored on the pulsar cluster for topics in the namespace before data starts being offloaded to longterm storage. Response example:10000000- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getOffloadThresholdAsync
java.util.concurrent.CompletableFuture<java.lang.Long> getOffloadThresholdAsync(java.lang.String namespace)
Get the offloadThreshold for a namespace asynchronously. The maximum number of bytes stored on the pulsar cluster for topics in the namespace before data starts being offloaded to longterm storage. Response example:10000000- Parameters:
namespace- Namespace name
-
setOffloadThreshold
void setOffloadThreshold(java.lang.String namespace, long offloadThreshold) throws PulsarAdminExceptionSet the offloadThreshold for a namespace. The maximum number of bytes stored on the pulsar cluster for topics in the namespace before data starts being offloaded to longterm storage. Negative values disabled automatic offloading. Setting a threshold of 0 will offload data as soon as possible. Request example:10000000- Parameters:
namespace- Namespace nameoffloadThreshold- maximum number of bytes stored before offloading is triggered- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setOffloadThresholdAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setOffloadThresholdAsync(java.lang.String namespace, long offloadThreshold)Set the offloadThreshold for a namespace asynchronously. The maximum number of bytes stored on the pulsar cluster for topics in the namespace before data starts being offloaded to longterm storage. Negative values disabled automatic offloading. Setting a threshold of 0 will offload data as soon as possible. Request example:10000000- Parameters:
namespace- Namespace nameoffloadThreshold- maximum number of bytes stored before offloading is triggered
-
getOffloadDeleteLagMs
java.lang.Long getOffloadDeleteLagMs(java.lang.String namespace) throws PulsarAdminExceptionGet the offload deletion lag for a namespace, in milliseconds. The number of milliseconds to wait before deleting a ledger segment which has been offloaded from the Pulsar cluster's local storage (i.e. BookKeeper). If the offload deletion lag has not been set for the namespace, the method returns 'null' and the namespace will use the configured default of the pulsar broker. A negative value disables deletion of the local ledger completely, though it will still be deleted if it exceeds the topics retention policy, along with the offloaded copy. Response example:3600000- Parameters:
namespace- Namespace name- Returns:
- the offload deletion lag for the namespace in milliseconds, or null if not set
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getOffloadDeleteLagMsAsync
java.util.concurrent.CompletableFuture<java.lang.Long> getOffloadDeleteLagMsAsync(java.lang.String namespace)
Get the offload deletion lag asynchronously for a namespace, in milliseconds. The number of milliseconds to wait before deleting a ledger segment which has been offloaded from the Pulsar cluster's local storage (i.e. BookKeeper). If the offload deletion lag has not been set for the namespace, the method returns 'null' and the namespace will use the configured default of the pulsar broker. A negative value disables deletion of the local ledger completely, though it will still be deleted if it exceeds the topics retention policy, along with the offloaded copy. Response example:3600000- Parameters:
namespace- Namespace name- Returns:
- the offload deletion lag for the namespace in milliseconds, or null if not set
-
setOffloadDeleteLag
void setOffloadDeleteLag(java.lang.String namespace, long lag, java.util.concurrent.TimeUnit unit) throws PulsarAdminExceptionSet the offload deletion lag for a namespace. The offload deletion lag is the amount of time to wait after offloading a ledger segment to long term storage, before deleting its copy stored on the Pulsar cluster's local storage (i.e. BookKeeper). A negative value disables deletion of the local ledger completely, though it will still be deleted if it exceeds the topics retention policy, along with the offloaded copy.- Parameters:
namespace- Namespace namelag- the duration to wait before deleting the local copyunit- the timeunit of the duration- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setOffloadDeleteLagAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setOffloadDeleteLagAsync(java.lang.String namespace, long lag, java.util.concurrent.TimeUnit unit)Set the offload deletion lag for a namespace asynchronously. The offload deletion lag is the amount of time to wait after offloading a ledger segment to long term storage, before deleting its copy stored on the Pulsar cluster's local storage (i.e. BookKeeper). A negative value disables deletion of the local ledger completely, though it will still be deleted if it exceeds the topics retention policy, along with the offloaded copy.- Parameters:
namespace- Namespace namelag- the duration to wait before deleting the local copyunit- the timeunit of the duration
-
clearOffloadDeleteLag
void clearOffloadDeleteLag(java.lang.String namespace) throws PulsarAdminExceptionClear the offload deletion lag for a namespace. The namespace will fall back to using the configured default of the pulsar broker.- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
clearOffloadDeleteLagAsync
java.util.concurrent.CompletableFuture<java.lang.Void> clearOffloadDeleteLagAsync(java.lang.String namespace)
Clear the offload deletion lag for a namespace asynchronously. The namespace will fall back to using the configured default of the pulsar broker.
-
getSchemaAutoUpdateCompatibilityStrategy
@Deprecated SchemaAutoUpdateCompatibilityStrategy getSchemaAutoUpdateCompatibilityStrategy(java.lang.String namespace) throws PulsarAdminException
Deprecated.Get the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed. If this isSchemaAutoUpdateCompatibilityStrategy.AutoUpdateDisabled, then all new schemas provided via the producer are rejected, and schemas must be updated through the REST api.- Parameters:
namespace- The namespace in whose policy we are interested- Returns:
- the strategy used to check compatibility
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setSchemaAutoUpdateCompatibilityStrategy
@Deprecated void setSchemaAutoUpdateCompatibilityStrategy(java.lang.String namespace, SchemaAutoUpdateCompatibilityStrategy strategy) throws PulsarAdminExceptionDeprecated.Set the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed. To disable all new schema updates through the producer, set this toSchemaAutoUpdateCompatibilityStrategy.AutoUpdateDisabled.- Parameters:
namespace- The namespace in whose policy should be setstrategy-- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getSchemaValidationEnforced
boolean getSchemaValidationEnforced(java.lang.String namespace) throws PulsarAdminExceptionGet schema validation enforced for namespace.- Returns:
- the schema validation enforced flag
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Tenant or Namespace does not existPulsarAdminException- Unexpected error
-
getSchemaValidationEnforcedAsync
java.util.concurrent.CompletableFuture<java.lang.Boolean> getSchemaValidationEnforcedAsync(java.lang.String namespace)
Get schema validation enforced for namespace asynchronously.- Returns:
- the schema validation enforced flag
-
setSchemaValidationEnforced
void setSchemaValidationEnforced(java.lang.String namespace, boolean schemaValidationEnforced) throws PulsarAdminExceptionSet schema validation enforced for namespace. if a producer without a schema attempts to produce to a topic with schema in this the namespace, the producer will be failed to connect. PLEASE be carefully on using this, since non-java clients don't support schema. if you enable this setting, it will cause non-java clients failed to produce.- Parameters:
namespace- pulsar namespace nameschemaValidationEnforced- flag to enable or disable schema validation for the given namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Tenant or Namespace does not existPulsarAdminException- Unexpected error
-
setSchemaValidationEnforcedAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setSchemaValidationEnforcedAsync(java.lang.String namespace, boolean schemaValidationEnforced)Set schema validation enforced for namespace asynchronously. if a producer without a schema attempts to produce to a topic with schema in this the namespace, the producer will be failed to connect. PLEASE be carefully on using this, since non-java clients don't support schema. if you enable this setting, it will cause non-java clients failed to produce.- Parameters:
namespace- pulsar namespace nameschemaValidationEnforced- flag to enable or disable schema validation for the given namespace
-
getSchemaCompatibilityStrategy
SchemaCompatibilityStrategy getSchemaCompatibilityStrategy(java.lang.String namespace) throws PulsarAdminException
Get the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed.- Parameters:
namespace- The namespace in whose policy we are interested- Returns:
- the strategy used to check compatibility
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getSchemaCompatibilityStrategyAsync
java.util.concurrent.CompletableFuture<SchemaCompatibilityStrategy> getSchemaCompatibilityStrategyAsync(java.lang.String namespace)
Get the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed asynchronously.- Parameters:
namespace- The namespace in whose policy we are interested- Returns:
- the strategy used to check compatibility
-
setSchemaCompatibilityStrategy
void setSchemaCompatibilityStrategy(java.lang.String namespace, SchemaCompatibilityStrategy strategy) throws PulsarAdminExceptionSet the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed.- Parameters:
namespace- The namespace in whose policy should be setstrategy- The schema compatibility strategy- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setSchemaCompatibilityStrategyAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setSchemaCompatibilityStrategyAsync(java.lang.String namespace, SchemaCompatibilityStrategy strategy)Set the strategy used to check the a new schema provided by a producer is compatible with the current schema before it is installed asynchronously.- Parameters:
namespace- The namespace in whose policy should be setstrategy- The schema compatibility strategy
-
getIsAllowAutoUpdateSchema
boolean getIsAllowAutoUpdateSchema(java.lang.String namespace) throws PulsarAdminExceptionGet whether allow auto update schema.- Parameters:
namespace- pulsar namespace name- Returns:
- the schema validation enforced flag
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Tenant or Namespace does not existPulsarAdminException- Unexpected error
-
getIsAllowAutoUpdateSchemaAsync
java.util.concurrent.CompletableFuture<java.lang.Boolean> getIsAllowAutoUpdateSchemaAsync(java.lang.String namespace)
Get whether allow auto update schema asynchronously.- Parameters:
namespace- pulsar namespace name- Returns:
- the schema validation enforced flag
-
setIsAllowAutoUpdateSchema
void setIsAllowAutoUpdateSchema(java.lang.String namespace, boolean isAllowAutoUpdateSchema) throws PulsarAdminExceptionSet whether to allow automatic schema updates. The flag is when producer bring a new schema and the schema pass compatibility check whether allow schema auto registered- Parameters:
namespace- pulsar namespace nameisAllowAutoUpdateSchema- flag to enable or disable auto update schema- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Tenant or Namespace does not existPulsarAdminException- Unexpected error
-
setIsAllowAutoUpdateSchemaAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setIsAllowAutoUpdateSchemaAsync(java.lang.String namespace, boolean isAllowAutoUpdateSchema)Set whether to allow automatic schema updates asynchronously. The flag is when producer bring a new schema and the schema pass compatibility check whether allow schema auto registered- Parameters:
namespace- pulsar namespace nameisAllowAutoUpdateSchema- flag to enable or disable auto update schema
-
setOffloadPolicies
void setOffloadPolicies(java.lang.String namespace, OffloadPolicies offloadPolicies) throws PulsarAdminExceptionSet the offload configuration for all the topics in a namespace. Set the offload configuration in a namespace. This operation requires pulsar tenant access. Request parameter example:{ "region" : "us-east-2", // The long term storage region "bucket" : "bucket", // Bucket to place offloaded ledger into "endpoint" : "endpoint", // Alternative endpoint to connect to "maxBlockSize" : 1024, // Max Block Size, default 64MB "readBufferSize" : 1024, // Read Buffer Size, default 1MB }- Parameters:
namespace- Namespace nameoffloadPolicies- Offload configuration- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
removeOffloadPolicies
void removeOffloadPolicies(java.lang.String namespace) throws PulsarAdminExceptionRemove the offload configuration for a namespace. Remove the offload configuration in a namespace. This operation requires pulsar tenant access.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
setOffloadPoliciesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setOffloadPoliciesAsync(java.lang.String namespace, OffloadPolicies offloadPolicies)Set the offload configuration for all the topics in a namespace asynchronously. Set the offload configuration in a namespace. This operation requires pulsar tenant access. Request parameter example:{ "region" : "us-east-2", // The long term storage region "bucket" : "bucket", // Bucket to place offloaded ledger into "endpoint" : "endpoint", // Alternative endpoint to connect to "maxBlockSize" : 1024, // Max Block Size, default 64MB "readBufferSize" : 1024, // Read Buffer Size, default 1MB }- Parameters:
namespace- Namespace nameoffloadPolicies- Offload configuration
-
removeOffloadPoliciesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeOffloadPoliciesAsync(java.lang.String namespace)
Remove the offload configuration for a namespace asynchronously. Remove the offload configuration in a namespace. This operation requires pulsar tenant access.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
getOffloadPolicies
OffloadPolicies getOffloadPolicies(java.lang.String namespace) throws PulsarAdminException
Get the offload configuration for a namespace. Get the offload configuration for a namespace. Response example:{ "region" : "us-east-2", // The long term storage region "bucket" : "bucket", // Bucket to place offloaded ledger into "endpoint" : "endpoint", // Alternative endpoint to connect to "maxBlockSize" : 1024, // Max Block Size, default 64MB "readBufferSize" : 1024, // Read Buffer Size, default 1MB }- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException.ConflictException- Concurrent modificationPulsarAdminException- Unexpected error
-
getOffloadPoliciesAsync
java.util.concurrent.CompletableFuture<OffloadPolicies> getOffloadPoliciesAsync(java.lang.String namespace)
Get the offload configuration for a namespace asynchronously. Get the offload configuration for a namespace. Response example:{ "region" : "us-east-2", // The long term storage region "bucket" : "bucket", // Bucket to place offloaded ledger into "endpoint" : "endpoint", // Alternative endpoint to connect to "maxBlockSize" : 1024, // Max Block Size, default 64MB "readBufferSize" : 1024, // Read Buffer Size, default 1MB }- Parameters:
namespace- Namespace name
-
getMaxTopicsPerNamespace
int getMaxTopicsPerNamespace(java.lang.String namespace) throws PulsarAdminExceptionGet maxTopicsPerNamespace for a namespace. Response example:0- Parameters:
namespace- Namespace name- Returns:
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace dost not existPulsarAdminException- Unexpected error
-
getMaxTopicsPerNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Integer> getMaxTopicsPerNamespaceAsync(java.lang.String namespace)
Get maxTopicsPerNamespace for a namespace asynchronously. Response example:0- Parameters:
namespace- Namespace name- Returns:
-
setMaxTopicsPerNamespace
void setMaxTopicsPerNamespace(java.lang.String namespace, int maxTopicsPerNamespace) throws PulsarAdminExceptionSet maxTopicsPerNamespace for a namespace. Request example:100- Parameters:
namespace- Namespace namemaxTopicsPerNamespace- maxTopicsPerNamespace value for a namespace- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setMaxTopicsPerNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setMaxTopicsPerNamespaceAsync(java.lang.String namespace, int maxTopicsPerNamespace)Set maxTopicsPerNamespace for a namespace asynchronously. Request example:100- Parameters:
namespace- Namespace namemaxTopicsPerNamespace- maxTopicsPerNamespace value for a namespace- Returns:
-
removeMaxTopicsPerNamespace
void removeMaxTopicsPerNamespace(java.lang.String namespace) throws PulsarAdminExceptionremove maxTopicsPerNamespace for a namespace.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
removeMaxTopicsPerNamespaceAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeMaxTopicsPerNamespaceAsync(java.lang.String namespace)
remove maxTopicsPerNamespace for a namespace asynchronously.- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setPropertyAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setPropertyAsync(java.lang.String namespace, java.lang.String key, java.lang.String value)<<<<<<< HEAD Set key value pair property for a namespace. If the property absents, a new property will added. Otherwise, the new value will overwrite. Example:admin.namespaces().setProperty("a", "a"); admin.namespaces().setProperty("b", "b");- Parameters:
namespace- Namespace namekey- key of the propertyvalue- value of the property
-
setProperty
void setProperty(java.lang.String namespace, java.lang.String key, java.lang.String value) throws PulsarAdminExceptionSet key value pair property for a namespace. If the property absents, a new property will added. Otherwise, the new value will overwrite. Example:admin.namespaces().setProperty("a", "a"); admin.namespaces().setProperty("b", "b");- Parameters:
namespace- Namespace namekey- key of the propertyvalue- value of the property- Throws:
PulsarAdminException
-
setPropertiesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setPropertiesAsync(java.lang.String namespace, java.util.Map<java.lang.String,java.lang.String> properties)Set key value pair properties for a namespace asynchronously. If the property absents, a new property will added. Otherwise, the new value will overwrite.- Parameters:
namespace- Namespace nameproperties- key value pair properties
-
setProperties
void setProperties(java.lang.String namespace, java.util.Map<java.lang.String,java.lang.String> properties) throws PulsarAdminExceptionSet key value pair properties for a namespace. If the property absents, a new property will added. Otherwise, the new value will overwrite.- Parameters:
namespace- Namespace nameproperties- key value pair properties- Throws:
PulsarAdminException
-
getPropertyAsync
java.util.concurrent.CompletableFuture<java.lang.String> getPropertyAsync(java.lang.String namespace, java.lang.String key)Get property value for a given key. If the property absents, will return null. Example:admin.namespaces().getProperty("a"); admin.namespaces().getProperty("b");- Parameters:
namespace- Namespace namekey- key of the property- Returns:
- value of the property.
-
getProperty
java.lang.String getProperty(java.lang.String namespace, java.lang.String key) throws PulsarAdminExceptionGet property value for a given key. If the property absents, will return null. Example:admin.namespaces().getProperty("a"); admin.namespaces().getProperty("b");- Parameters:
namespace- Namespace namekey- key of the property- Returns:
- value of the property.
- Throws:
PulsarAdminException
-
getPropertiesAsync
java.util.concurrent.CompletableFuture<java.util.Map<java.lang.String,java.lang.String>> getPropertiesAsync(java.lang.String namespace)
Get all properties of a namespace asynchronously. Example:admin.namespaces().getPropertiesAsync();- Parameters:
namespace- Namespace name- Returns:
- key value pair properties.
-
getProperties
java.util.Map<java.lang.String,java.lang.String> getProperties(java.lang.String namespace) throws PulsarAdminExceptionGet all properties of a namespace. Example:admin.namespaces().getProperties();- Parameters:
namespace- Namespace name- Returns:
- key value pair properties.
- Throws:
PulsarAdminException
-
removePropertyAsync
java.util.concurrent.CompletableFuture<java.lang.String> removePropertyAsync(java.lang.String namespace, java.lang.String key)Remove a property for a given key. Return value of the property if the property exists, otherwise return null. Example:admin.namespaces().removeProperty("a"); admin.namespaces().removeProperty("b");- Parameters:
namespace- Namespace namekey- key of the property- Returns:
- value of the property.
-
removeProperty
java.lang.String removeProperty(java.lang.String namespace, java.lang.String key) throws PulsarAdminExceptionRemove a property for a given key. Return value of the property if the property exists, otherwise return null. Example:admin.namespaces().removeProperty("a"); admin.namespaces().removeProperty("b");- Parameters:
namespace- Namespace namekey- key of the property- Returns:
- value of the property.
- Throws:
PulsarAdminException
-
clearPropertiesAsync
java.util.concurrent.CompletableFuture<java.lang.Void> clearPropertiesAsync(java.lang.String namespace)
Clear all properties of a namespace asynchronously. Example:admin.namespaces().clearPropertiesAsync();- Parameters:
namespace- Namespace name
-
clearProperties
void clearProperties(java.lang.String namespace) throws PulsarAdminExceptionClear all properties of a namespace. Example:admin.namespaces().clearProperties();- Parameters:
namespace- Namespace name- Throws:
PulsarAdminException
-
getNamespaceResourceGroup
java.lang.String getNamespaceResourceGroup(java.lang.String namespace) throws PulsarAdminExceptionGet the ResourceGroup for a namespace. Response example:60- Parameters:
namespace- Namespace name- Returns:
- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
getNamespaceResourceGroupAsync
java.util.concurrent.CompletableFuture<java.lang.String> getNamespaceResourceGroupAsync(java.lang.String namespace)
Get the ResourceGroup for a namespace asynchronously. Response example:60- Parameters:
namespace- Namespace name
-
setNamespaceResourceGroup
void setNamespaceResourceGroup(java.lang.String namespace, java.lang.String resourcegroupname) throws PulsarAdminExceptionSet the ResourceGroup for a namespace. Request example:60- Parameters:
namespace- Namespace nameresourcegroupname- ResourceGroup name- Throws:
PulsarAdminException.NotAuthorizedException- Don't have admin permissionPulsarAdminException.NotFoundException- Namespace does not existPulsarAdminException- Unexpected error
-
setNamespaceResourceGroupAsync
java.util.concurrent.CompletableFuture<java.lang.Void> setNamespaceResourceGroupAsync(java.lang.String namespace, java.lang.String resourcegroupname)Set the ResourceGroup for a namespace asynchronously. Request example:60- Parameters:
namespace- Namespace nameresourcegroupname- TTL values for all messages for all topics in this namespace
-
removeNamespaceResourceGroup
void removeNamespaceResourceGroup(java.lang.String namespace) throws PulsarAdminExceptionRemove the ResourceGroup on a namespace.- Parameters:
namespace-- Throws:
PulsarAdminException
-
removeNamespaceResourceGroupAsync
java.util.concurrent.CompletableFuture<java.lang.Void> removeNamespaceResourceGroupAsync(java.lang.String namespace)
Remove the ResourceGroup on a namespace asynchronously.- Parameters:
namespace-- Returns:
-
-