Class: Google::Apis::FirebaseapphostingV1::RunConfig
- Inherits:
-
Object
- Object
- Google::Apis::FirebaseapphostingV1::RunConfig
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/firebaseapphosting_v1/classes.rb,
lib/google/apis/firebaseapphosting_v1/representations.rb,
lib/google/apis/firebaseapphosting_v1/representations.rb
Overview
Configuration applied to the Cloud Run service.
Instance Attribute Summary collapse
-
#concurrency ⇒ Fixnum
Optional.
-
#cpu ⇒ Float
Optional.
-
#max_instances ⇒ Fixnum
Optional.
-
#memory_mib ⇒ Fixnum
Optional.
-
#min_instances ⇒ Fixnum
Optional.
Instance Method Summary collapse
-
#initialize(**args) ⇒ RunConfig
constructor
A new instance of RunConfig.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ RunConfig
Returns a new instance of RunConfig.
1775 1776 1777 |
# File 'lib/google/apis/firebaseapphosting_v1/classes.rb', line 1775 def initialize(**args) update!(**args) end |
Instance Attribute Details
#concurrency ⇒ Fixnum
Optional. Maximum number of requests that each Cloud Run instance can receive.
By default, each instance can receive Cloud Run's default of up to 80 requests
at the same time. Concurrency can be set to any integer value up to 1000.
Corresponds to the JSON property concurrency
1734 1735 1736 |
# File 'lib/google/apis/firebaseapphosting_v1/classes.rb', line 1734 def concurrency @concurrency end |
#cpu ⇒ Float
Optional. Number of CPUs used for each serving instance. By default, cpu
defaults to the Cloud Run's default of 1.0. CPU can be set to value 1, 2, 4, 6,
or 8 CPUs, and for less than 1 CPU, a value from 0.08 to less than 1.00, in
increments of 0.01. If you set a value of less than 1 CPU, you must set
concurrency to 1, and CPU will only be allocated during request processing.
Increasing CPUs limit may require increase in memory limits: - 4 CPUs: at
least 2 GiB - 6 CPUs: at least 4 GiB - 8 CPUs: at least 4 GiB
Corresponds to the JSON property cpu
1745 1746 1747 |
# File 'lib/google/apis/firebaseapphosting_v1/classes.rb', line 1745 def cpu @cpu end |
#max_instances ⇒ Fixnum
Optional. Number of Cloud Run instances to maintain at maximum for each
revision. By default, each Cloud Run service scales
out to Cloud Run's default of a maximum of 100 instances. The maximum
max_instances limit is based on your quota. See https://cloud.google.com/run/
docs/configuring/max-instances#limits.
Corresponds to the JSON property maxInstances
1755 1756 1757 |
# File 'lib/google/apis/firebaseapphosting_v1/classes.rb', line 1755 def max_instances @max_instances end |
#memory_mib ⇒ Fixnum
Optional. Amount of memory allocated for each serving instance in MiB. By
default, memory defaults to the Cloud Run's default where each instance is
allocated 512 MiB of memory. Memory can be set to any integer value between
128 to 32768. Increasing memory limit may require increase in CPUs limits: -
Over 4 GiB: at least 2 CPUs - Over 8 GiB: at least 4 CPUs - Over 16 GiB: at
least 6 CPUs - Over 24 GiB: at least 8 CPUs
Corresponds to the JSON property memoryMib
1765 1766 1767 |
# File 'lib/google/apis/firebaseapphosting_v1/classes.rb', line 1765 def memory_mib @memory_mib end |
#min_instances ⇒ Fixnum
Optional. Number of Cloud Run instances to maintain at minimum for each Cloud
Run Service. By default, there are no minimum. Even if the service splits
traffic across multiple revisions, the total number of instances for a service
will be capped at this value.
Corresponds to the JSON property minInstances
1773 1774 1775 |
# File 'lib/google/apis/firebaseapphosting_v1/classes.rb', line 1773 def min_instances @min_instances end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1780 1781 1782 1783 1784 1785 1786 |
# File 'lib/google/apis/firebaseapphosting_v1/classes.rb', line 1780 def update!(**args) @concurrency = args[:concurrency] if args.key?(:concurrency) @cpu = args[:cpu] if args.key?(:cpu) @max_instances = args[:max_instances] if args.key?(:max_instances) @memory_mib = args[:memory_mib] if args.key?(:memory_mib) @min_instances = args[:min_instances] if args.key?(:min_instances) end |