class Google::Apis::RunV1::ResourceRequirements

ResourceRequirements describes the compute resource requirements.

Attributes

limits[RW]

(Optional) Only memory and CPU are supported. Note: The only supported values for CPU are '1', '2', and '4'. Setting 4 CPU requires at least 2Gi of memory. Limits describes the maximum amount of compute resources allowed. The values of the map is string form of the 'quantity' k8s type: github.com/ kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/ resource/quantity.go Corresponds to the JSON property `limits` @return [Hash<String,String>]

requests[RW]

(Optional) Only memory and CPU are supported. Note: The only supported values for CPU are '1' and '2'. Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. The values of the map is string form of the 'quantity' k8s type: https:/ /github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/ pkg/api/resource/quantity.go Corresponds to the JSON property `requests` @return [Hash<String,String>]

Public Class Methods

new(**args) click to toggle source
# File lib/google/apis/run_v1/classes.rb, line 1954
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File lib/google/apis/run_v1/classes.rb, line 1959
def update!(**args)
  @limits = args[:limits] if args.key?(:limits)
  @requests = args[:requests] if args.key?(:requests)
end