public interface ResourceQuotas
| Modifier and Type | Method and Description |
|---|---|
ResourceQuota |
getDefaultResourceQuota()
Get default resource quota for new resource bundles.
|
CompletableFuture<ResourceQuota> |
getDefaultResourceQuotaAsync()
Get default resource quota for new resource bundles asynchronously.
|
ResourceQuota |
getNamespaceBundleResourceQuota(String namespace,
String bundle)
Get resource quota of a namespace bundle.
|
CompletableFuture<ResourceQuota> |
getNamespaceBundleResourceQuotaAsync(String namespace,
String bundle)
Get resource quota of a namespace bundle asynchronously.
|
void |
resetNamespaceBundleResourceQuota(String namespace,
String bundle)
Reset resource quota for a namespace bundle to default value.
|
CompletableFuture<Void> |
resetNamespaceBundleResourceQuotaAsync(String namespace,
String bundle)
Reset resource quota for a namespace bundle to default value asynchronously.
|
void |
setDefaultResourceQuota(ResourceQuota quota)
Set default resource quota for new namespace bundles.
|
CompletableFuture<Void> |
setDefaultResourceQuotaAsync(ResourceQuota quota)
Set default resource quota for new namespace bundles asynchronously.
|
void |
setNamespaceBundleResourceQuota(String namespace,
String bundle,
ResourceQuota quota)
Set resource quota for a namespace bundle.
|
CompletableFuture<Void> |
setNamespaceBundleResourceQuotaAsync(String namespace,
String bundle,
ResourceQuota quota)
Set resource quota for a namespace bundle asynchronously.
|
ResourceQuota getDefaultResourceQuota() throws PulsarAdminException
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : true
}
PulsarAdminException.NotAuthorizedException - Permission deniedPulsarAdminException - Unexpected errorCompletableFuture<ResourceQuota> getDefaultResourceQuotaAsync()
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : true
}
void setDefaultResourceQuota(ResourceQuota quota) throws PulsarAdminException
msgRateIn : The maximum incoming messages per second.
msgRateOut : The maximum outgoing messages per second.
bandwidthIn : The maximum inbound bandwidth used.
bandwidthOut : The maximum outbound bandwidth used.
memory : The maximum memory used.
dynamic : allow the quota to be dynamically re-calculated.
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : false
}
quota - The new ResourceQuotaPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException - Unexpected errorCompletableFuture<Void> setDefaultResourceQuotaAsync(ResourceQuota quota)
msgRateIn : The maximum incoming messages per second.
msgRateOut : The maximum outgoing messages per second.
bandwidthIn : The maximum inbound bandwidth used.
bandwidthOut : The maximum outbound bandwidth used.
memory : The maximum memory used.
dynamic : allow the quota to be dynamically re-calculated.
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : false
}
quota - The new ResourceQuotaResourceQuota getNamespaceBundleResourceQuota(String namespace, String bundle) throws PulsarAdminException
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : true
}
namespace - Namespace namebundle - Range of bundle {start}_{end}PulsarAdminException.NotAuthorizedException - Permission deniedPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<ResourceQuota> getNamespaceBundleResourceQuotaAsync(String namespace, String bundle)
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : true
}
namespace - Namespace namebundle - Range of bundle {start}_{end}void setNamespaceBundleResourceQuota(String namespace, String bundle, ResourceQuota quota) throws PulsarAdminException
msgRateIn : The maximum incoming messages per second.
msgRateOut : The maximum outgoing messages per second.
bandwidthIn : The maximum inbound bandwidth used.
bandwidthOut : The maximum outbound bandwidth used.
memory : The maximum memory used.
dynamic : allow the quota to be dynamically re-calculated.
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : false
}
namespace - Namespace namebundle - Bundle range {start}_{end}quota - The new ResourceQuotaPulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Void> setNamespaceBundleResourceQuotaAsync(String namespace, String bundle, ResourceQuota quota)
msgRateIn : The maximum incoming messages per second.
msgRateOut : The maximum outgoing messages per second.
bandwidthIn : The maximum inbound bandwidth used.
bandwidthOut : The maximum outbound bandwidth used.
memory : The maximum memory used.
dynamic : allow the quota to be dynamically re-calculated.
{
"msgRateIn" : 10,
"msgRateOut" : 30,
"bandwidthIn" : 10000,
"bandwidthOut" : 30000,
"memory" : 100,
"dynamic" : false
}
namespace - Namespace namebundle - Bundle range {start}_{end}quota - The new ResourceQuotavoid resetNamespaceBundleResourceQuota(String namespace, String bundle) throws PulsarAdminException
namespace - Namespace namebundle - Bundle range {start}_{end}PulsarAdminException.NotAuthorizedException - Don't have admin permissionPulsarAdminException.NotFoundException - Namespace does not existPulsarAdminException - Unexpected errorCompletableFuture<Void> resetNamespaceBundleResourceQuotaAsync(String namespace, String bundle)
namespace - Namespace namebundle - Bundle range {start}_{end}Copyright © 2017–2022 Apache Software Foundation. All rights reserved.