Class: Google::Apis::ServicecontrolV1::AllocateQuotaResponse

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/servicecontrol_v1/classes.rb,
generated/google/apis/servicecontrol_v1/representations.rb,
generated/google/apis/servicecontrol_v1/representations.rb

Overview

Response message for the AllocateQuota method.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ AllocateQuotaResponse

Returns a new instance of AllocateQuotaResponse



63
64
65
# File 'generated/google/apis/servicecontrol_v1/classes.rb', line 63

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#allocate_errorsArray<Google::Apis::ServicecontrolV1::QuotaError>

Indicates the decision of the allocate. Corresponds to the JSON property allocateErrors



43
44
45
# File 'generated/google/apis/servicecontrol_v1/classes.rb', line 43

def allocate_errors
  @allocate_errors
end

#operation_idString

The same operation_id value used in the AllocateQuotaRequest. Used for logging and diagnostics purposes. Corresponds to the JSON property operationId

Returns:

  • (String)


33
34
35
# File 'generated/google/apis/servicecontrol_v1/classes.rb', line 33

def operation_id
  @operation_id
end

#quota_metricsArray<Google::Apis::ServicecontrolV1::MetricValueSet>

Quota metrics to indicate the result of allocation. Depending on the request, one or more of the following metrics will be included:

  1. For rate quota, per quota group or per quota metric incremental usage will be specified using the following delta metric: "serviceruntime.googleapis.com/api/consumer/quota_used_count"
  2. For allocation quota, per quota metric total usage will be specified using the following gauge metric: "serviceruntime.googleapis.com/allocation/consumer/quota_used_count"
  3. For both rate quota and allocation quota, the quota limit reached condition will be specified using the following boolean metric: "serviceruntime.googleapis.com/quota/exceeded"
  4. For allocation quota, value for each quota limit associated with the metrics will be specified using the following gauge metric: "serviceruntime.googleapis.com/quota/limit" Corresponds to the JSON property quotaMetrics


61
62
63
# File 'generated/google/apis/servicecontrol_v1/classes.rb', line 61

def quota_metrics
  @quota_metrics
end

#service_config_idString

ID of the actual config used to process the request. Corresponds to the JSON property serviceConfigId

Returns:

  • (String)


38
39
40
# File 'generated/google/apis/servicecontrol_v1/classes.rb', line 38

def service_config_id
  @service_config_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



68
69
70
71
72
73
# File 'generated/google/apis/servicecontrol_v1/classes.rb', line 68

def update!(**args)
  @operation_id = args[:operation_id] if args.key?(:operation_id)
  @service_config_id = args[:service_config_id] if args.key?(:service_config_id)
  @allocate_errors = args[:allocate_errors] if args.key?(:allocate_errors)
  @quota_metrics = args[:quota_metrics] if args.key?(:quota_metrics)
end