Package com.google.rpc
Class QuotaFailure.Violation.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite.Builder<QuotaFailure.Violation,QuotaFailure.Violation.Builder>
com.google.rpc.QuotaFailure.Violation.Builder
- All Implemented Interfaces:
com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,QuotaFailure.ViolationOrBuilder
,Cloneable
- Enclosing class:
- QuotaFailure.Violation
public static final class QuotaFailure.Violation.Builder
extends com.google.protobuf.GeneratedMessageLite.Builder<QuotaFailure.Violation,QuotaFailure.Violation.Builder>
implements QuotaFailure.ViolationOrBuilder
A message type used to describe a single quota violation. For example, a daily quota or a custom quota that was exceeded.Protobuf type
google.rpc.QuotaFailure.Violation
-
Field Summary
Fields inherited from class com.google.protobuf.GeneratedMessageLite.Builder
instance
-
Method Summary
Modifier and TypeMethodDescriptionThe API Service from which the `QuotaFailure.Violation` orginates.A description of how the quota check failed.The new quota value being rolled out at the time of the violation.The id of the violated quota.The metric of the violated quota.The enforced quota value at the time of the `QuotaFailure`.The subject on which the quota check failed.boolean
The dimensions of the violated quota.The API Service from which the `QuotaFailure.Violation` orginates.com.google.protobuf.ByteString
The API Service from which the `QuotaFailure.Violation` orginates.A description of how the quota check failed.com.google.protobuf.ByteString
A description of how the quota check failed.long
The new quota value being rolled out at the time of the violation.Deprecated.int
The dimensions of the violated quota.The dimensions of the violated quota.getQuotaDimensionsOrDefault
(String key, String defaultValue) The dimensions of the violated quota.The dimensions of the violated quota.The id of the violated quota.com.google.protobuf.ByteString
The id of the violated quota.The metric of the violated quota.com.google.protobuf.ByteString
The metric of the violated quota.long
The enforced quota value at the time of the `QuotaFailure`.The subject on which the quota check failed.com.google.protobuf.ByteString
The subject on which the quota check failed.boolean
The new quota value being rolled out at the time of the violation.putAllQuotaDimensions
(Map<String, String> values) The dimensions of the violated quota.putQuotaDimensions
(String key, String value) The dimensions of the violated quota.The dimensions of the violated quota.setApiService
(String value) The API Service from which the `QuotaFailure.Violation` orginates.setApiServiceBytes
(com.google.protobuf.ByteString value) The API Service from which the `QuotaFailure.Violation` orginates.setDescription
(String value) A description of how the quota check failed.setDescriptionBytes
(com.google.protobuf.ByteString value) A description of how the quota check failed.setFutureQuotaValue
(long value) The new quota value being rolled out at the time of the violation.setQuotaId
(String value) The id of the violated quota.setQuotaIdBytes
(com.google.protobuf.ByteString value) The id of the violated quota.setQuotaMetric
(String value) The metric of the violated quota.setQuotaMetricBytes
(com.google.protobuf.ByteString value) The metric of the violated quota.setQuotaValue
(long value) The enforced quota value at the time of the `QuotaFailure`.setSubject
(String value) The subject on which the quota check failed.setSubjectBytes
(com.google.protobuf.ByteString value) The subject on which the quota check failed.Methods inherited from class com.google.protobuf.GeneratedMessageLite.Builder
build, buildPartial, clear, clone, copyOnWrite, copyOnWriteInternal, getDefaultInstanceForType, internalMergeFrom, isInitialized, mergeFrom, mergeFrom, mergeFrom, mergeFrom
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Method Details
-
getSubject
The subject on which the quota check failed. For example, "clientip:<ip address of client>" or "project:<Google developer project id>".
string subject = 1 [json_name = "subject"];
- Specified by:
getSubject
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The subject.
-
getSubjectBytes
public com.google.protobuf.ByteString getSubjectBytes()The subject on which the quota check failed. For example, "clientip:<ip address of client>" or "project:<Google developer project id>".
string subject = 1 [json_name = "subject"];
- Specified by:
getSubjectBytes
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The bytes for subject.
-
setSubject
The subject on which the quota check failed. For example, "clientip:<ip address of client>" or "project:<Google developer project id>".
string subject = 1 [json_name = "subject"];
- Parameters:
value
- The subject to set.- Returns:
- This builder for chaining.
-
clearSubject
The subject on which the quota check failed. For example, "clientip:<ip address of client>" or "project:<Google developer project id>".
string subject = 1 [json_name = "subject"];
- Returns:
- This builder for chaining.
-
setSubjectBytes
The subject on which the quota check failed. For example, "clientip:<ip address of client>" or "project:<Google developer project id>".
string subject = 1 [json_name = "subject"];
- Parameters:
value
- The bytes for subject to set.- Returns:
- This builder for chaining.
-
getDescription
A description of how the quota check failed. Clients can use this description to find more about the quota configuration in the service's public documentation, or find the relevant quota limit to adjust through developer console. For example: "Service disabled" or "Daily Limit for read operations exceeded".
string description = 2 [json_name = "description"];
- Specified by:
getDescription
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The description.
-
getDescriptionBytes
public com.google.protobuf.ByteString getDescriptionBytes()A description of how the quota check failed. Clients can use this description to find more about the quota configuration in the service's public documentation, or find the relevant quota limit to adjust through developer console. For example: "Service disabled" or "Daily Limit for read operations exceeded".
string description = 2 [json_name = "description"];
- Specified by:
getDescriptionBytes
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The bytes for description.
-
setDescription
A description of how the quota check failed. Clients can use this description to find more about the quota configuration in the service's public documentation, or find the relevant quota limit to adjust through developer console. For example: "Service disabled" or "Daily Limit for read operations exceeded".
string description = 2 [json_name = "description"];
- Parameters:
value
- The description to set.- Returns:
- This builder for chaining.
-
clearDescription
A description of how the quota check failed. Clients can use this description to find more about the quota configuration in the service's public documentation, or find the relevant quota limit to adjust through developer console. For example: "Service disabled" or "Daily Limit for read operations exceeded".
string description = 2 [json_name = "description"];
- Returns:
- This builder for chaining.
-
setDescriptionBytes
A description of how the quota check failed. Clients can use this description to find more about the quota configuration in the service's public documentation, or find the relevant quota limit to adjust through developer console. For example: "Service disabled" or "Daily Limit for read operations exceeded".
string description = 2 [json_name = "description"];
- Parameters:
value
- The bytes for description to set.- Returns:
- This builder for chaining.
-
getApiService
The API Service from which the `QuotaFailure.Violation` orginates. In some cases, Quota issues originate from an API Service other than the one that was called. In other words, a dependency of the called API Service could be the cause of the `QuotaFailure`, and this field would have the dependency API service name. For example, if the called API is Kubernetes Engine API (container.googleapis.com), and a quota violation occurs in the Kubernetes Engine API itself, this field would be "container.googleapis.com". On the other hand, if the quota violation occurs when the Kubernetes Engine API creates VMs in the Compute Engine API (compute.googleapis.com), this field would be "compute.googleapis.com".
string api_service = 3 [json_name = "apiService"];
- Specified by:
getApiService
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The apiService.
-
getApiServiceBytes
public com.google.protobuf.ByteString getApiServiceBytes()The API Service from which the `QuotaFailure.Violation` orginates. In some cases, Quota issues originate from an API Service other than the one that was called. In other words, a dependency of the called API Service could be the cause of the `QuotaFailure`, and this field would have the dependency API service name. For example, if the called API is Kubernetes Engine API (container.googleapis.com), and a quota violation occurs in the Kubernetes Engine API itself, this field would be "container.googleapis.com". On the other hand, if the quota violation occurs when the Kubernetes Engine API creates VMs in the Compute Engine API (compute.googleapis.com), this field would be "compute.googleapis.com".
string api_service = 3 [json_name = "apiService"];
- Specified by:
getApiServiceBytes
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The bytes for apiService.
-
setApiService
The API Service from which the `QuotaFailure.Violation` orginates. In some cases, Quota issues originate from an API Service other than the one that was called. In other words, a dependency of the called API Service could be the cause of the `QuotaFailure`, and this field would have the dependency API service name. For example, if the called API is Kubernetes Engine API (container.googleapis.com), and a quota violation occurs in the Kubernetes Engine API itself, this field would be "container.googleapis.com". On the other hand, if the quota violation occurs when the Kubernetes Engine API creates VMs in the Compute Engine API (compute.googleapis.com), this field would be "compute.googleapis.com".
string api_service = 3 [json_name = "apiService"];
- Parameters:
value
- The apiService to set.- Returns:
- This builder for chaining.
-
clearApiService
The API Service from which the `QuotaFailure.Violation` orginates. In some cases, Quota issues originate from an API Service other than the one that was called. In other words, a dependency of the called API Service could be the cause of the `QuotaFailure`, and this field would have the dependency API service name. For example, if the called API is Kubernetes Engine API (container.googleapis.com), and a quota violation occurs in the Kubernetes Engine API itself, this field would be "container.googleapis.com". On the other hand, if the quota violation occurs when the Kubernetes Engine API creates VMs in the Compute Engine API (compute.googleapis.com), this field would be "compute.googleapis.com".
string api_service = 3 [json_name = "apiService"];
- Returns:
- This builder for chaining.
-
setApiServiceBytes
The API Service from which the `QuotaFailure.Violation` orginates. In some cases, Quota issues originate from an API Service other than the one that was called. In other words, a dependency of the called API Service could be the cause of the `QuotaFailure`, and this field would have the dependency API service name. For example, if the called API is Kubernetes Engine API (container.googleapis.com), and a quota violation occurs in the Kubernetes Engine API itself, this field would be "container.googleapis.com". On the other hand, if the quota violation occurs when the Kubernetes Engine API creates VMs in the Compute Engine API (compute.googleapis.com), this field would be "compute.googleapis.com".
string api_service = 3 [json_name = "apiService"];
- Parameters:
value
- The bytes for apiService to set.- Returns:
- This builder for chaining.
-
getQuotaMetric
The metric of the violated quota. A quota metric is a named counter to measure usage, such as API requests or CPUs. When an activity occurs in a service, such as Virtual Machine allocation, one or more quota metrics may be affected. For example, "compute.googleapis.com/cpus_per_vm_family", "storage.googleapis.com/internet_egress_bandwidth".
string quota_metric = 4 [json_name = "quotaMetric"];
- Specified by:
getQuotaMetric
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The quotaMetric.
-
getQuotaMetricBytes
public com.google.protobuf.ByteString getQuotaMetricBytes()The metric of the violated quota. A quota metric is a named counter to measure usage, such as API requests or CPUs. When an activity occurs in a service, such as Virtual Machine allocation, one or more quota metrics may be affected. For example, "compute.googleapis.com/cpus_per_vm_family", "storage.googleapis.com/internet_egress_bandwidth".
string quota_metric = 4 [json_name = "quotaMetric"];
- Specified by:
getQuotaMetricBytes
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The bytes for quotaMetric.
-
setQuotaMetric
The metric of the violated quota. A quota metric is a named counter to measure usage, such as API requests or CPUs. When an activity occurs in a service, such as Virtual Machine allocation, one or more quota metrics may be affected. For example, "compute.googleapis.com/cpus_per_vm_family", "storage.googleapis.com/internet_egress_bandwidth".
string quota_metric = 4 [json_name = "quotaMetric"];
- Parameters:
value
- The quotaMetric to set.- Returns:
- This builder for chaining.
-
clearQuotaMetric
The metric of the violated quota. A quota metric is a named counter to measure usage, such as API requests or CPUs. When an activity occurs in a service, such as Virtual Machine allocation, one or more quota metrics may be affected. For example, "compute.googleapis.com/cpus_per_vm_family", "storage.googleapis.com/internet_egress_bandwidth".
string quota_metric = 4 [json_name = "quotaMetric"];
- Returns:
- This builder for chaining.
-
setQuotaMetricBytes
The metric of the violated quota. A quota metric is a named counter to measure usage, such as API requests or CPUs. When an activity occurs in a service, such as Virtual Machine allocation, one or more quota metrics may be affected. For example, "compute.googleapis.com/cpus_per_vm_family", "storage.googleapis.com/internet_egress_bandwidth".
string quota_metric = 4 [json_name = "quotaMetric"];
- Parameters:
value
- The bytes for quotaMetric to set.- Returns:
- This builder for chaining.
-
getQuotaId
The id of the violated quota. Also know as "limit name", this is the unique identifier of a quota in the context of an API service. For example, "CPUS-PER-VM-FAMILY-per-project-region".
string quota_id = 5 [json_name = "quotaId"];
- Specified by:
getQuotaId
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The quotaId.
-
getQuotaIdBytes
public com.google.protobuf.ByteString getQuotaIdBytes()The id of the violated quota. Also know as "limit name", this is the unique identifier of a quota in the context of an API service. For example, "CPUS-PER-VM-FAMILY-per-project-region".
string quota_id = 5 [json_name = "quotaId"];
- Specified by:
getQuotaIdBytes
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The bytes for quotaId.
-
setQuotaId
The id of the violated quota. Also know as "limit name", this is the unique identifier of a quota in the context of an API service. For example, "CPUS-PER-VM-FAMILY-per-project-region".
string quota_id = 5 [json_name = "quotaId"];
- Parameters:
value
- The quotaId to set.- Returns:
- This builder for chaining.
-
clearQuotaId
The id of the violated quota. Also know as "limit name", this is the unique identifier of a quota in the context of an API service. For example, "CPUS-PER-VM-FAMILY-per-project-region".
string quota_id = 5 [json_name = "quotaId"];
- Returns:
- This builder for chaining.
-
setQuotaIdBytes
The id of the violated quota. Also know as "limit name", this is the unique identifier of a quota in the context of an API service. For example, "CPUS-PER-VM-FAMILY-per-project-region".
string quota_id = 5 [json_name = "quotaId"];
- Parameters:
value
- The bytes for quotaId to set.- Returns:
- This builder for chaining.
-
getQuotaDimensionsCount
public int getQuotaDimensionsCount()Description copied from interface:QuotaFailure.ViolationOrBuilder
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
- Specified by:
getQuotaDimensionsCount
in interfaceQuotaFailure.ViolationOrBuilder
-
containsQuotaDimensions
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
- Specified by:
containsQuotaDimensions
in interfaceQuotaFailure.ViolationOrBuilder
-
clearQuotaDimensions
-
removeQuotaDimensions
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
-
getQuotaDimensions
Deprecated.UsegetQuotaDimensionsMap()
instead.- Specified by:
getQuotaDimensions
in interfaceQuotaFailure.ViolationOrBuilder
-
getQuotaDimensionsMap
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
- Specified by:
getQuotaDimensionsMap
in interfaceQuotaFailure.ViolationOrBuilder
-
getQuotaDimensionsOrDefault
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
- Specified by:
getQuotaDimensionsOrDefault
in interfaceQuotaFailure.ViolationOrBuilder
-
getQuotaDimensionsOrThrow
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
- Specified by:
getQuotaDimensionsOrThrow
in interfaceQuotaFailure.ViolationOrBuilder
-
putQuotaDimensions
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
-
putAllQuotaDimensions
The dimensions of the violated quota. Every non-global quota is enforced on a set of dimensions. While quota metric defines what to count, the dimensions specify for what aspects the counter should be increased. For example, the quota "CPUs per region per VM family" enforces a limit on the metric "compute.googleapis.com/cpus_per_vm_family" on dimensions "region" and "vm_family". And if the violation occurred in region "us-central1" and for VM family "n1", the quota_dimensions would be, { "region": "us-central1", "vm_family": "n1", } When a quota is enforced globally, the quota_dimensions would always be empty.
map<string, string> quota_dimensions = 6 [json_name = "quotaDimensions"];
-
getQuotaValue
public long getQuotaValue()The enforced quota value at the time of the `QuotaFailure`. For example, if the enforced quota value at the time of the `QuotaFailure` on the number of CPUs is "10", then the value of this field would reflect this quantity.
int64 quota_value = 7 [json_name = "quotaValue"];
- Specified by:
getQuotaValue
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The quotaValue.
-
setQuotaValue
The enforced quota value at the time of the `QuotaFailure`. For example, if the enforced quota value at the time of the `QuotaFailure` on the number of CPUs is "10", then the value of this field would reflect this quantity.
int64 quota_value = 7 [json_name = "quotaValue"];
- Parameters:
value
- The quotaValue to set.- Returns:
- This builder for chaining.
-
clearQuotaValue
The enforced quota value at the time of the `QuotaFailure`. For example, if the enforced quota value at the time of the `QuotaFailure` on the number of CPUs is "10", then the value of this field would reflect this quantity.
int64 quota_value = 7 [json_name = "quotaValue"];
- Returns:
- This builder for chaining.
-
hasFutureQuotaValue
public boolean hasFutureQuotaValue()The new quota value being rolled out at the time of the violation. At the completion of the rollout, this value will be enforced in place of quota_value. If no rollout is in progress at the time of the violation, this field is not set. For example, if at the time of the violation a rollout is in progress changing the number of CPUs quota from 10 to 20, 20 would be the value of this field.
optional int64 future_quota_value = 8 [json_name = "futureQuotaValue"];
- Specified by:
hasFutureQuotaValue
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- Whether the futureQuotaValue field is set.
-
getFutureQuotaValue
public long getFutureQuotaValue()The new quota value being rolled out at the time of the violation. At the completion of the rollout, this value will be enforced in place of quota_value. If no rollout is in progress at the time of the violation, this field is not set. For example, if at the time of the violation a rollout is in progress changing the number of CPUs quota from 10 to 20, 20 would be the value of this field.
optional int64 future_quota_value = 8 [json_name = "futureQuotaValue"];
- Specified by:
getFutureQuotaValue
in interfaceQuotaFailure.ViolationOrBuilder
- Returns:
- The futureQuotaValue.
-
setFutureQuotaValue
The new quota value being rolled out at the time of the violation. At the completion of the rollout, this value will be enforced in place of quota_value. If no rollout is in progress at the time of the violation, this field is not set. For example, if at the time of the violation a rollout is in progress changing the number of CPUs quota from 10 to 20, 20 would be the value of this field.
optional int64 future_quota_value = 8 [json_name = "futureQuotaValue"];
- Parameters:
value
- The futureQuotaValue to set.- Returns:
- This builder for chaining.
-
clearFutureQuotaValue
The new quota value being rolled out at the time of the violation. At the completion of the rollout, this value will be enforced in place of quota_value. If no rollout is in progress at the time of the violation, this field is not set. For example, if at the time of the violation a rollout is in progress changing the number of CPUs quota from 10 to 20, 20 would be the value of this field.
optional int64 future_quota_value = 8 [json_name = "futureQuotaValue"];
- Returns:
- This builder for chaining.
-