google-apis-run_v2 0.9.0 → 0.12.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -34,12 +34,6 @@ module Google
34
34
  # @return [String]
35
35
  attr_accessor :breakglass_justification
36
36
 
37
- # The path to a binary authorization policy. Format: projects/`project`/
38
- # platforms/cloudRun/`policy-name`
39
- # Corresponds to the JSON property `policy`
40
- # @return [String]
41
- attr_accessor :policy
42
-
43
37
  # If True, indicates to use the default project's binary authorization policy.
44
38
  # If False, binary authorization will be disabled.
45
39
  # Corresponds to the JSON property `useDefault`
@@ -54,7 +48,6 @@ module Google
54
48
  # Update properties of this object
55
49
  def update!(**args)
56
50
  @breakglass_justification = args[:breakglass_justification] if args.key?(:breakglass_justification)
57
- @policy = args[:policy] if args.key?(:policy)
58
51
  @use_default = args[:use_default] if args.key?(:use_default)
59
52
  end
60
53
  end
@@ -67,9 +60,9 @@ module Google
67
60
  # cloud.google.com/sql/instances. Visit https://cloud.google.com/sql/docs/mysql/
68
61
  # connect-run for more information on how to connect Cloud SQL and Cloud Run.
69
62
  # Format: `project`:`location`:`instance`
70
- # Corresponds to the JSON property `connections`
63
+ # Corresponds to the JSON property `instances`
71
64
  # @return [Array<String>]
72
- attr_accessor :connections
65
+ attr_accessor :instances
73
66
 
74
67
  def initialize(**args)
75
68
  update!(**args)
@@ -77,7 +70,7 @@ module Google
77
70
 
78
71
  # Update properties of this object
79
72
  def update!(**args)
80
- @connections = args[:connections] if args.key?(:connections)
73
+ @instances = args[:instances] if args.key?(:instances)
81
74
  end
82
75
  end
83
76
 
@@ -266,6 +259,32 @@ module Google
266
259
  end
267
260
  end
268
261
 
262
+ # ContainerStatus holds the information of container name and image digest value.
263
+ class GoogleCloudRunV2ContainerStatus
264
+ include Google::Apis::Core::Hashable
265
+
266
+ # ImageDigest holds the resolved digest for the image specified, regardless of
267
+ # whether a tag or digest was originally specified in the Container object.
268
+ # Corresponds to the JSON property `imageDigest`
269
+ # @return [String]
270
+ attr_accessor :image_digest
271
+
272
+ # The name of the container, if specified.
273
+ # Corresponds to the JSON property `name`
274
+ # @return [String]
275
+ attr_accessor :name
276
+
277
+ def initialize(**args)
278
+ update!(**args)
279
+ end
280
+
281
+ # Update properties of this object
282
+ def update!(**args)
283
+ @image_digest = args[:image_digest] if args.key?(:image_digest)
284
+ @name = args[:name] if args.key?(:name)
285
+ end
286
+ end
287
+
269
288
  # EnvVar represents an environment variable present in a Container.
270
289
  class GoogleCloudRunV2EnvVar
271
290
  include Google::Apis::Core::Hashable
@@ -323,92 +342,10 @@ module Google
323
342
  end
324
343
  end
325
344
 
326
- # Response message containing a list of Revisions.
327
- class GoogleCloudRunV2ListRevisionsResponse
328
- include Google::Apis::Core::Hashable
329
-
330
- # A token indicating there are more items than page_size. Use it in the next
331
- # ListRevisions request to continue.
332
- # Corresponds to the JSON property `nextPageToken`
333
- # @return [String]
334
- attr_accessor :next_page_token
335
-
336
- # The resulting list of Revisions.
337
- # Corresponds to the JSON property `revisions`
338
- # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Revision>]
339
- attr_accessor :revisions
340
-
341
- def initialize(**args)
342
- update!(**args)
343
- end
344
-
345
- # Update properties of this object
346
- def update!(**args)
347
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
348
- @revisions = args[:revisions] if args.key?(:revisions)
349
- end
350
- end
351
-
352
- # Response message containing a list of Services.
353
- class GoogleCloudRunV2ListServicesResponse
354
- include Google::Apis::Core::Hashable
355
-
356
- # A token indicating there are more items than page_size. Use it in the next
357
- # ListServices request to continue.
358
- # Corresponds to the JSON property `nextPageToken`
359
- # @return [String]
360
- attr_accessor :next_page_token
361
-
362
- # The resulting list of Services.
363
- # Corresponds to the JSON property `services`
364
- # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Service>]
365
- attr_accessor :services
366
-
367
- def initialize(**args)
368
- update!(**args)
369
- end
370
-
371
- # Update properties of this object
372
- def update!(**args)
373
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
374
- @services = args[:services] if args.key?(:services)
375
- end
376
- end
377
-
378
- # ResourceRequirements describes the compute resource requirements.
379
- class GoogleCloudRunV2ResourceRequirements
380
- include Google::Apis::Core::Hashable
381
-
382
- # Determines whether CPU should be throttled or not outside of requests.
383
- # Corresponds to the JSON property `cpuIdle`
384
- # @return [Boolean]
385
- attr_accessor :cpu_idle
386
- alias_method :cpu_idle?, :cpu_idle
387
-
388
- # Only memory and CPU are supported. Note: The only supported values for CPU are
389
- # '1', '2', and '4'. Setting 4 CPU requires at least 2Gi of memory. The values
390
- # of the map is string form of the 'quantity' k8s type: https://github.com/
391
- # kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/
392
- # resource/quantity.go
393
- # Corresponds to the JSON property `limits`
394
- # @return [Hash<String,String>]
395
- attr_accessor :limits
396
-
397
- def initialize(**args)
398
- update!(**args)
399
- end
400
-
401
- # Update properties of this object
402
- def update!(**args)
403
- @cpu_idle = args[:cpu_idle] if args.key?(:cpu_idle)
404
- @limits = args[:limits] if args.key?(:limits)
405
- end
406
- end
407
-
408
- # A Revision is an immutable snapshot of code and configuration. A Revision
409
- # references a container image. Revisions are only created by updates to its
410
- # parent Service.
411
- class GoogleCloudRunV2Revision
345
+ # Execution represents the configuration of a single execution. A execution an
346
+ # immutable resource that references a container image which is run to
347
+ # completion.
348
+ class GoogleCloudRunV2Execution
412
349
  include Google::Apis::Core::Hashable
413
350
 
414
351
  # KRM-style annotations for the resource.
@@ -416,30 +353,21 @@ module Google
416
353
  # @return [Hash<String,String>]
417
354
  attr_accessor :annotations
418
355
 
419
- # Output only. The Condition of this Revision, containing its readiness status,
420
- # and detailed error information in case it did not reach a serving state.
356
+ # Output only. Represents time when the execution was completed. It is not
357
+ # guaranteed to be set in happens-before order across separate operations.
358
+ # Corresponds to the JSON property `completionTime`
359
+ # @return [String]
360
+ attr_accessor :completion_time
361
+
362
+ # Output only. The Condition of this Execution, containing its readiness status,
363
+ # and detailed error information in case it did not reach the desired state.
421
364
  # Corresponds to the JSON property `conditions`
422
365
  # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Condition>]
423
366
  attr_accessor :conditions
424
367
 
425
- # Indicates whether Confidential Cloud Run is enabled in this Revision.
426
- # Corresponds to the JSON property `confidential`
427
- # @return [Boolean]
428
- attr_accessor :confidential
429
- alias_method :confidential?, :confidential
430
-
431
- # Sets the maximum number of requests that each serving instance can receive.
432
- # Corresponds to the JSON property `containerConcurrency`
433
- # @return [Fixnum]
434
- attr_accessor :container_concurrency
435
-
436
- # Holds the single container that defines the unit of execution for this
437
- # Revision.
438
- # Corresponds to the JSON property `containers`
439
- # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Container>]
440
- attr_accessor :containers
441
-
442
- # Output only. The creation time.
368
+ # Output only. Represents time when the execution was acknowledged by the
369
+ # execution controller. It is not guaranteed to be set in happens-before order
370
+ # across separate operations.
443
371
  # Corresponds to the JSON property `createTime`
444
372
  # @return [String]
445
373
  attr_accessor :create_time
@@ -450,36 +378,34 @@ module Google
450
378
  # @return [String]
451
379
  attr_accessor :delete_time
452
380
 
453
- # A reference to a customer managed encryption key (CMEK) to use to encrypt this
454
- # container image. For more information, go to https://cloud.google.com/run/docs/
455
- # securing/using-cmek
456
- # Corresponds to the JSON property `encryptionKey`
457
- # @return [String]
458
- attr_accessor :encryption_key
459
-
460
381
  # Output only. A system-generated fingerprint for this version of the resource.
461
382
  # May be used to detect modification conflict during updates.
462
383
  # Corresponds to the JSON property `etag`
463
384
  # @return [String]
464
385
  attr_accessor :etag
465
386
 
466
- # The execution environment being used to host this Revision.
467
- # Corresponds to the JSON property `executionEnvironment`
468
- # @return [String]
469
- attr_accessor :execution_environment
470
-
471
387
  # Output only. For a deleted resource, the time after which it will be
472
388
  # permamently deleted. It is only populated as a response to a Delete request.
473
389
  # Corresponds to the JSON property `expireTime`
474
390
  # @return [String]
475
391
  attr_accessor :expire_time
476
392
 
393
+ # Output only. The number of tasks which reached phase Failed.
394
+ # Corresponds to the JSON property `failedCount`
395
+ # @return [Fixnum]
396
+ attr_accessor :failed_count
397
+
477
398
  # Output only. A number that monotonically increases every time the user
478
399
  # modifies the desired state.
479
400
  # Corresponds to the JSON property `generation`
480
401
  # @return [Fixnum]
481
402
  attr_accessor :generation
482
403
 
404
+ # Output only. The name of the parent Job.
405
+ # Corresponds to the JSON property `job`
406
+ # @return [String]
407
+ attr_accessor :job
408
+
483
409
  # KRM-style labels for the resource. User-provided labels are shared with Google'
484
410
  # s billing system, so they can be used to filter, or break down billing charges
485
411
  # by team, component, environment, state, etc. For more information, visit https:
@@ -499,54 +425,66 @@ module Google
499
425
  # @return [String]
500
426
  attr_accessor :launch_stage
501
427
 
502
- # Output only. The Google Console URI to obtain logs for the Revision.
503
- # Corresponds to the JSON property `logUri`
504
- # @return [String]
505
- attr_accessor :log_uri
506
-
507
- # Output only. The unique name of this Revision.
428
+ # Output only. The unique name of this Execution.
508
429
  # Corresponds to the JSON property `name`
509
430
  # @return [String]
510
431
  attr_accessor :name
511
432
 
512
- # Output only. The generation of this Revision currently serving traffic. See
513
- # comments in `reconciling` for additional information on reconciliation process
514
- # in Cloud Run.
433
+ # Output only. The generation of this Execution. See comments in `reconciling`
434
+ # for additional information on reconciliation process in Cloud Run.
515
435
  # Corresponds to the JSON property `observedGeneration`
516
436
  # @return [Fixnum]
517
437
  attr_accessor :observed_generation
518
438
 
439
+ # Output only. Specifies the maximum desired number of tasks the execution
440
+ # should run at any given time. Must be <= task_count. The actual number of
441
+ # tasks running in steady state will be less than this number when ((.spec.
442
+ # task_count - .status.successful) < .spec.parallelism), i.e. when the work left
443
+ # to do is less than max parallelism. More info: https://kubernetes.io/docs/
444
+ # concepts/workloads/controllers/jobs-run-to-completion/
445
+ # Corresponds to the JSON property `parallelism`
446
+ # @return [Fixnum]
447
+ attr_accessor :parallelism
448
+
519
449
  # Output only. Indicates whether the resource's reconciliation is still in
520
- # progress. See comments in `Service.reconciling` for additional information on
450
+ # progress. See comments in `Job.reconciling` for additional information on
521
451
  # reconciliation process in Cloud Run.
522
452
  # Corresponds to the JSON property `reconciling`
523
453
  # @return [Boolean]
524
454
  attr_accessor :reconciling
525
455
  alias_method :reconciling?, :reconciling
526
456
 
527
- # Settings for revision-level scaling settings.
528
- # Corresponds to the JSON property `scaling`
529
- # @return [Google::Apis::RunV2::GoogleCloudRunV2RevisionScaling]
530
- attr_accessor :scaling
457
+ # Output only. The number of actively running tasks.
458
+ # Corresponds to the JSON property `runningCount`
459
+ # @return [Fixnum]
460
+ attr_accessor :running_count
531
461
 
532
- # Output only. The name of the parent service.
533
- # Corresponds to the JSON property `service`
462
+ # Output only. Represents time when the execution started to run. It is not
463
+ # guaranteed to be set in happens-before order across separate operations.
464
+ # Corresponds to the JSON property `startTime`
534
465
  # @return [String]
535
- attr_accessor :service
466
+ attr_accessor :start_time
536
467
 
537
- # Email address of the IAM service account associated with the revision of the
538
- # service. The service account represents the identity of the running revision,
539
- # and determines what permissions the revision has.
540
- # Corresponds to the JSON property `serviceAccount`
541
- # @return [String]
542
- attr_accessor :service_account
468
+ # Output only. The number of tasks which reached phase Succeeded.
469
+ # Corresponds to the JSON property `succeededCount`
470
+ # @return [Fixnum]
471
+ attr_accessor :succeeded_count
543
472
 
544
- # Max allowed time for an instance to respond to a request.
545
- # Corresponds to the JSON property `timeout`
546
- # @return [String]
547
- attr_accessor :timeout
473
+ # Output only. Specifies the desired number of tasks the execution should run.
474
+ # Setting to 1 means that parallelism is limited to 1 and the success of that
475
+ # task signals the success of the execution. More info: https://kubernetes.io/
476
+ # docs/concepts/workloads/controllers/jobs-run-to-completion/
477
+ # Corresponds to the JSON property `taskCount`
478
+ # @return [Fixnum]
479
+ attr_accessor :task_count
548
480
 
549
- # Output only. Server assigned unique identifier for the Revision. The value is
481
+ # TaskTemplate describes the data a task should have when created from a
482
+ # template.
483
+ # Corresponds to the JSON property `template`
484
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2TaskTemplate]
485
+ attr_accessor :template
486
+
487
+ # Output only. Server assigned unique identifier for the Execution. The value is
550
488
  # a UUID4 string and guaranteed to remain unchanged until the resource is
551
489
  # deleted.
552
490
  # Corresponds to the JSON property `uid`
@@ -558,19 +496,6 @@ module Google
558
496
  # @return [String]
559
497
  attr_accessor :update_time
560
498
 
561
- # A list of Volumes to make available to containers.
562
- # Corresponds to the JSON property `volumes`
563
- # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Volume>]
564
- attr_accessor :volumes
565
-
566
- # VPC Access settings. For more information on creating a VPC Connector, visit
567
- # https://cloud.google.com/vpc/docs/configure-serverless-vpc-access For
568
- # information on how to configure Cloud Run with an existing VPC Connector,
569
- # visit https://cloud.google.com/run/docs/configuring/connecting-vpc
570
- # Corresponds to the JSON property `vpcAccess`
571
- # @return [Google::Apis::RunV2::GoogleCloudRunV2VpcAccess]
572
- attr_accessor :vpc_access
573
-
574
499
  def initialize(**args)
575
500
  update!(**args)
576
501
  end
@@ -578,47 +503,45 @@ module Google
578
503
  # Update properties of this object
579
504
  def update!(**args)
580
505
  @annotations = args[:annotations] if args.key?(:annotations)
506
+ @completion_time = args[:completion_time] if args.key?(:completion_time)
581
507
  @conditions = args[:conditions] if args.key?(:conditions)
582
- @confidential = args[:confidential] if args.key?(:confidential)
583
- @container_concurrency = args[:container_concurrency] if args.key?(:container_concurrency)
584
- @containers = args[:containers] if args.key?(:containers)
585
508
  @create_time = args[:create_time] if args.key?(:create_time)
586
509
  @delete_time = args[:delete_time] if args.key?(:delete_time)
587
- @encryption_key = args[:encryption_key] if args.key?(:encryption_key)
588
510
  @etag = args[:etag] if args.key?(:etag)
589
- @execution_environment = args[:execution_environment] if args.key?(:execution_environment)
590
511
  @expire_time = args[:expire_time] if args.key?(:expire_time)
512
+ @failed_count = args[:failed_count] if args.key?(:failed_count)
591
513
  @generation = args[:generation] if args.key?(:generation)
514
+ @job = args[:job] if args.key?(:job)
592
515
  @labels = args[:labels] if args.key?(:labels)
593
516
  @launch_stage = args[:launch_stage] if args.key?(:launch_stage)
594
- @log_uri = args[:log_uri] if args.key?(:log_uri)
595
517
  @name = args[:name] if args.key?(:name)
596
518
  @observed_generation = args[:observed_generation] if args.key?(:observed_generation)
519
+ @parallelism = args[:parallelism] if args.key?(:parallelism)
597
520
  @reconciling = args[:reconciling] if args.key?(:reconciling)
598
- @scaling = args[:scaling] if args.key?(:scaling)
599
- @service = args[:service] if args.key?(:service)
600
- @service_account = args[:service_account] if args.key?(:service_account)
601
- @timeout = args[:timeout] if args.key?(:timeout)
521
+ @running_count = args[:running_count] if args.key?(:running_count)
522
+ @start_time = args[:start_time] if args.key?(:start_time)
523
+ @succeeded_count = args[:succeeded_count] if args.key?(:succeeded_count)
524
+ @task_count = args[:task_count] if args.key?(:task_count)
525
+ @template = args[:template] if args.key?(:template)
602
526
  @uid = args[:uid] if args.key?(:uid)
603
527
  @update_time = args[:update_time] if args.key?(:update_time)
604
- @volumes = args[:volumes] if args.key?(:volumes)
605
- @vpc_access = args[:vpc_access] if args.key?(:vpc_access)
606
528
  end
607
529
  end
608
530
 
609
- # Settings for revision-level scaling settings.
610
- class GoogleCloudRunV2RevisionScaling
531
+ # Reference to an Execution. Use /Executions.GetExecution with the given name to
532
+ # get full execution including the latest status.
533
+ class GoogleCloudRunV2ExecutionReference
611
534
  include Google::Apis::Core::Hashable
612
535
 
613
- # Maximum number of serving instances that this resource should have.
614
- # Corresponds to the JSON property `maxInstanceCount`
615
- # @return [Fixnum]
616
- attr_accessor :max_instance_count
536
+ # Creation timestamp of the execution.
537
+ # Corresponds to the JSON property `createTime`
538
+ # @return [String]
539
+ attr_accessor :create_time
617
540
 
618
- # Minimum number of serving instances that this resource should have.
619
- # Corresponds to the JSON property `minInstanceCount`
620
- # @return [Fixnum]
621
- attr_accessor :min_instance_count
541
+ # Name of the execution.
542
+ # Corresponds to the JSON property `name`
543
+ # @return [String]
544
+ attr_accessor :name
622
545
 
623
546
  def initialize(**args)
624
547
  update!(**args)
@@ -626,14 +549,14 @@ module Google
626
549
 
627
550
  # Update properties of this object
628
551
  def update!(**args)
629
- @max_instance_count = args[:max_instance_count] if args.key?(:max_instance_count)
630
- @min_instance_count = args[:min_instance_count] if args.key?(:min_instance_count)
552
+ @create_time = args[:create_time] if args.key?(:create_time)
553
+ @name = args[:name] if args.key?(:name)
631
554
  end
632
555
  end
633
556
 
634
- # RevisionTemplate describes the data a revision should have when created from a
635
- # template.
636
- class GoogleCloudRunV2RevisionTemplate
557
+ # ExecutionTemplate describes the data an execution should have when created
558
+ # from a template.
559
+ class GoogleCloudRunV2ExecutionTemplate
637
560
  include Google::Apis::Core::Hashable
638
561
 
639
562
  # KRM-style annotations for the resource.
@@ -641,27 +564,665 @@ module Google
641
564
  # @return [Hash<String,String>]
642
565
  attr_accessor :annotations
643
566
 
644
- # Enables Confidential Cloud Run in Revisions created using this template.
645
- # Corresponds to the JSON property `confidential`
646
- # @return [Boolean]
647
- attr_accessor :confidential
648
- alias_method :confidential?, :confidential
567
+ # KRM-style labels for the resource.
568
+ # Corresponds to the JSON property `labels`
569
+ # @return [Hash<String,String>]
570
+ attr_accessor :labels
649
571
 
650
- # Sets the maximum number of requests that each serving instance can receive.
651
- # Corresponds to the JSON property `containerConcurrency`
572
+ # Specifies the maximum desired number of tasks the execution should run at
573
+ # given time. Must be <= task_count. When the job is run, if this field is 0 or
574
+ # unset, the maximum possible value will be used for that execution. The actual
575
+ # number of tasks running in steady state will be less than this number when
576
+ # there are fewer tasks waiting to be completed remaining, i.e. when the work
577
+ # left to do is less than max parallelism.
578
+ # Corresponds to the JSON property `parallelism`
652
579
  # @return [Fixnum]
653
- attr_accessor :container_concurrency
580
+ attr_accessor :parallelism
654
581
 
655
- # Holds the single container that defines the unit of execution for this
656
- # Revision.
657
- # Corresponds to the JSON property `containers`
658
- # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Container>]
659
- attr_accessor :containers
582
+ # Specifies the desired number of tasks the execution should run. Setting to 1
583
+ # means that parallelism is limited to 1 and the success of that task signals
584
+ # the success of the execution. More info: https://kubernetes.io/docs/concepts/
585
+ # workloads/controllers/jobs-run-to-completion/
586
+ # Corresponds to the JSON property `taskCount`
587
+ # @return [Fixnum]
588
+ attr_accessor :task_count
660
589
 
661
- # A reference to a customer managed encryption key (CMEK) to use to encrypt this
662
- # container image. For more information, go to https://cloud.google.com/run/docs/
663
- # securing/using-cmek
664
- # Corresponds to the JSON property `encryptionKey`
590
+ # TaskTemplate describes the data a task should have when created from a
591
+ # template.
592
+ # Corresponds to the JSON property `template`
593
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2TaskTemplate]
594
+ attr_accessor :template
595
+
596
+ def initialize(**args)
597
+ update!(**args)
598
+ end
599
+
600
+ # Update properties of this object
601
+ def update!(**args)
602
+ @annotations = args[:annotations] if args.key?(:annotations)
603
+ @labels = args[:labels] if args.key?(:labels)
604
+ @parallelism = args[:parallelism] if args.key?(:parallelism)
605
+ @task_count = args[:task_count] if args.key?(:task_count)
606
+ @template = args[:template] if args.key?(:template)
607
+ end
608
+ end
609
+
610
+ # Job represents the configuration of a single job. A job an immutable resource
611
+ # that references a container image which is run to completion.
612
+ class GoogleCloudRunV2Job
613
+ include Google::Apis::Core::Hashable
614
+
615
+ # KRM-style annotations for the resource. Unstructured key value map that may be
616
+ # set by external tools to store and arbitrary metadata. They are not queryable
617
+ # and should be preserved when modifying objects. Cloud Run will populate some
618
+ # annotations using 'run.googleapis.com' or 'serving.knative.dev' namespaces.
619
+ # This field follows Kubernetes annotations' namespacing, limits, and rules.
620
+ # More info: https://kubernetes.io/docs/user-guide/annotations
621
+ # Corresponds to the JSON property `annotations`
622
+ # @return [Hash<String,String>]
623
+ attr_accessor :annotations
624
+
625
+ # Settings for Binary Authorization feature.
626
+ # Corresponds to the JSON property `binaryAuthorization`
627
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2BinaryAuthorization]
628
+ attr_accessor :binary_authorization
629
+
630
+ # Arbitrary identifier for the API client.
631
+ # Corresponds to the JSON property `client`
632
+ # @return [String]
633
+ attr_accessor :client
634
+
635
+ # Arbitrary version identifier for the API client.
636
+ # Corresponds to the JSON property `clientVersion`
637
+ # @return [String]
638
+ attr_accessor :client_version
639
+
640
+ # Output only. The Conditions of all other associated sub-resources. They
641
+ # contain additional diagnostics information in case the Job does not reach its
642
+ # desired state. See comments in `reconciling` for additional information on
643
+ # reconciliation process in Cloud Run.
644
+ # Corresponds to the JSON property `conditions`
645
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Condition>]
646
+ attr_accessor :conditions
647
+
648
+ # Output only. Status information for each of the containers specified.
649
+ # Corresponds to the JSON property `containerStatuses`
650
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2ContainerStatus>]
651
+ attr_accessor :container_statuses
652
+
653
+ # Output only. The creation time.
654
+ # Corresponds to the JSON property `createTime`
655
+ # @return [String]
656
+ attr_accessor :create_time
657
+
658
+ # Output only. Email address of the authenticated creator.
659
+ # Corresponds to the JSON property `creator`
660
+ # @return [String]
661
+ attr_accessor :creator
662
+
663
+ # Output only. The deletion time.
664
+ # Corresponds to the JSON property `deleteTime`
665
+ # @return [String]
666
+ attr_accessor :delete_time
667
+
668
+ # Output only. A system-generated fingerprint for this version of the resource.
669
+ # May be used to detect modification conflict during updates.
670
+ # Corresponds to the JSON property `etag`
671
+ # @return [String]
672
+ attr_accessor :etag
673
+
674
+ # Output only. Number of executions created for this job.
675
+ # Corresponds to the JSON property `executionCount`
676
+ # @return [Fixnum]
677
+ attr_accessor :execution_count
678
+
679
+ # Output only. For a deleted resource, the time after which it will be
680
+ # permamently deleted.
681
+ # Corresponds to the JSON property `expireTime`
682
+ # @return [String]
683
+ attr_accessor :expire_time
684
+
685
+ # Output only. A number that monotonically increases every time the user
686
+ # modifies the desired state.
687
+ # Corresponds to the JSON property `generation`
688
+ # @return [Fixnum]
689
+ attr_accessor :generation
690
+
691
+ # KRM-style labels for the resource. User-provided labels are shared with Google'
692
+ # s billing system, so they can be used to filter, or break down billing charges
693
+ # by team, component, environment, state, etc. For more information, visit https:
694
+ # //cloud.google.com/resource-manager/docs/creating-managing-labels or https://
695
+ # cloud.google.com/run/docs/configuring/labels Cloud Run will populate some
696
+ # labels with 'run.googleapis.com' or 'serving.knative.dev' namespaces. Those
697
+ # labels are read-only, and user changes will not be preserved.
698
+ # Corresponds to the JSON property `labels`
699
+ # @return [Hash<String,String>]
700
+ attr_accessor :labels
701
+
702
+ # Output only. Email address of the last authenticated modifier.
703
+ # Corresponds to the JSON property `lastModifier`
704
+ # @return [String]
705
+ attr_accessor :last_modifier
706
+
707
+ # Reference to an Execution. Use /Executions.GetExecution with the given name to
708
+ # get full execution including the latest status.
709
+ # Corresponds to the JSON property `latestCreatedExecution`
710
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2ExecutionReference]
711
+ attr_accessor :latest_created_execution
712
+
713
+ # The launch stage as defined by [Google Cloud Platform Launch Stages](https://
714
+ # cloud.google.com/terms/launch-stages). Cloud Run supports `ALPHA`, `BETA`, and
715
+ # `GA`. If no value is specified, GA is assumed.
716
+ # Corresponds to the JSON property `launchStage`
717
+ # @return [String]
718
+ attr_accessor :launch_stage
719
+
720
+ # The fully qualified name of this Job. Format: projects/`project`/locations/`
721
+ # location`/jobs/`job`
722
+ # Corresponds to the JSON property `name`
723
+ # @return [String]
724
+ attr_accessor :name
725
+
726
+ # Output only. The generation of this Job. See comments in `reconciling` for
727
+ # additional information on reconciliation process in Cloud Run.
728
+ # Corresponds to the JSON property `observedGeneration`
729
+ # @return [Fixnum]
730
+ attr_accessor :observed_generation
731
+
732
+ # Output only. Returns true if the Job is currently being acted upon by the
733
+ # system to bring it into the desired state. When a new Job is created, or an
734
+ # existing one is updated, Cloud Run will asynchronously perform all necessary
735
+ # steps to bring the Job to the desired state. This process is called
736
+ # reconciliation. While reconciliation is in process, `observed_generation` and `
737
+ # latest_succeeded_execution`, will have transient values that might mismatch
738
+ # the intended state: Once reconciliation is over (and this field is false),
739
+ # there are two possible outcomes: reconciliation succeeded and the state
740
+ # matches the Job, or there was an error, and reconciliation failed. This state
741
+ # can be found in `terminal_condition.state`. If reconciliation succeeded, the
742
+ # following fields will match: `observed_generation` and `generation`, `
743
+ # latest_succeeded_execution` and `latest_created_execution`. If reconciliation
744
+ # failed, `observed_generation` and `latest_succeeded_execution` will have the
745
+ # state of the last succeeded execution or empty for newly created Job.
746
+ # Additional information on the failure can be found in `terminal_condition` and
747
+ # `conditions`.
748
+ # Corresponds to the JSON property `reconciling`
749
+ # @return [Boolean]
750
+ attr_accessor :reconciling
751
+ alias_method :reconciling?, :reconciling
752
+
753
+ # ExecutionTemplate describes the data an execution should have when created
754
+ # from a template.
755
+ # Corresponds to the JSON property `template`
756
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2ExecutionTemplate]
757
+ attr_accessor :template
758
+
759
+ # Defines a status condition for a resource.
760
+ # Corresponds to the JSON property `terminalCondition`
761
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2Condition]
762
+ attr_accessor :terminal_condition
763
+
764
+ # Output only. Server assigned unique identifier for the Execution. The value is
765
+ # a UUID4 string and guaranteed to remain unchanged until the resource is
766
+ # deleted.
767
+ # Corresponds to the JSON property `uid`
768
+ # @return [String]
769
+ attr_accessor :uid
770
+
771
+ # Output only. The last-modified time.
772
+ # Corresponds to the JSON property `updateTime`
773
+ # @return [String]
774
+ attr_accessor :update_time
775
+
776
+ def initialize(**args)
777
+ update!(**args)
778
+ end
779
+
780
+ # Update properties of this object
781
+ def update!(**args)
782
+ @annotations = args[:annotations] if args.key?(:annotations)
783
+ @binary_authorization = args[:binary_authorization] if args.key?(:binary_authorization)
784
+ @client = args[:client] if args.key?(:client)
785
+ @client_version = args[:client_version] if args.key?(:client_version)
786
+ @conditions = args[:conditions] if args.key?(:conditions)
787
+ @container_statuses = args[:container_statuses] if args.key?(:container_statuses)
788
+ @create_time = args[:create_time] if args.key?(:create_time)
789
+ @creator = args[:creator] if args.key?(:creator)
790
+ @delete_time = args[:delete_time] if args.key?(:delete_time)
791
+ @etag = args[:etag] if args.key?(:etag)
792
+ @execution_count = args[:execution_count] if args.key?(:execution_count)
793
+ @expire_time = args[:expire_time] if args.key?(:expire_time)
794
+ @generation = args[:generation] if args.key?(:generation)
795
+ @labels = args[:labels] if args.key?(:labels)
796
+ @last_modifier = args[:last_modifier] if args.key?(:last_modifier)
797
+ @latest_created_execution = args[:latest_created_execution] if args.key?(:latest_created_execution)
798
+ @launch_stage = args[:launch_stage] if args.key?(:launch_stage)
799
+ @name = args[:name] if args.key?(:name)
800
+ @observed_generation = args[:observed_generation] if args.key?(:observed_generation)
801
+ @reconciling = args[:reconciling] if args.key?(:reconciling)
802
+ @template = args[:template] if args.key?(:template)
803
+ @terminal_condition = args[:terminal_condition] if args.key?(:terminal_condition)
804
+ @uid = args[:uid] if args.key?(:uid)
805
+ @update_time = args[:update_time] if args.key?(:update_time)
806
+ end
807
+ end
808
+
809
+ # Response message containing a list of Executions.
810
+ class GoogleCloudRunV2ListExecutionsResponse
811
+ include Google::Apis::Core::Hashable
812
+
813
+ # The resulting list of Executions.
814
+ # Corresponds to the JSON property `executions`
815
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Execution>]
816
+ attr_accessor :executions
817
+
818
+ # A token indicating there are more items than page_size. Use it in the next
819
+ # ListExecutions request to continue.
820
+ # Corresponds to the JSON property `nextPageToken`
821
+ # @return [String]
822
+ attr_accessor :next_page_token
823
+
824
+ def initialize(**args)
825
+ update!(**args)
826
+ end
827
+
828
+ # Update properties of this object
829
+ def update!(**args)
830
+ @executions = args[:executions] if args.key?(:executions)
831
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
832
+ end
833
+ end
834
+
835
+ # Response message containing a list of Jobs.
836
+ class GoogleCloudRunV2ListJobsResponse
837
+ include Google::Apis::Core::Hashable
838
+
839
+ # The resulting list of Jobs.
840
+ # Corresponds to the JSON property `jobs`
841
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Job>]
842
+ attr_accessor :jobs
843
+
844
+ # A token indicating there are more items than page_size. Use it in the next
845
+ # ListJobs request to continue.
846
+ # Corresponds to the JSON property `nextPageToken`
847
+ # @return [String]
848
+ attr_accessor :next_page_token
849
+
850
+ def initialize(**args)
851
+ update!(**args)
852
+ end
853
+
854
+ # Update properties of this object
855
+ def update!(**args)
856
+ @jobs = args[:jobs] if args.key?(:jobs)
857
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
858
+ end
859
+ end
860
+
861
+ # Response message containing a list of Revisions.
862
+ class GoogleCloudRunV2ListRevisionsResponse
863
+ include Google::Apis::Core::Hashable
864
+
865
+ # A token indicating there are more items than page_size. Use it in the next
866
+ # ListRevisions request to continue.
867
+ # Corresponds to the JSON property `nextPageToken`
868
+ # @return [String]
869
+ attr_accessor :next_page_token
870
+
871
+ # The resulting list of Revisions.
872
+ # Corresponds to the JSON property `revisions`
873
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Revision>]
874
+ attr_accessor :revisions
875
+
876
+ def initialize(**args)
877
+ update!(**args)
878
+ end
879
+
880
+ # Update properties of this object
881
+ def update!(**args)
882
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
883
+ @revisions = args[:revisions] if args.key?(:revisions)
884
+ end
885
+ end
886
+
887
+ # Response message containing a list of Services.
888
+ class GoogleCloudRunV2ListServicesResponse
889
+ include Google::Apis::Core::Hashable
890
+
891
+ # A token indicating there are more items than page_size. Use it in the next
892
+ # ListServices request to continue.
893
+ # Corresponds to the JSON property `nextPageToken`
894
+ # @return [String]
895
+ attr_accessor :next_page_token
896
+
897
+ # The resulting list of Services.
898
+ # Corresponds to the JSON property `services`
899
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Service>]
900
+ attr_accessor :services
901
+
902
+ def initialize(**args)
903
+ update!(**args)
904
+ end
905
+
906
+ # Update properties of this object
907
+ def update!(**args)
908
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
909
+ @services = args[:services] if args.key?(:services)
910
+ end
911
+ end
912
+
913
+ # Response message containing a list of Tasks.
914
+ class GoogleCloudRunV2ListTasksResponse
915
+ include Google::Apis::Core::Hashable
916
+
917
+ # A token indicating there are more items than page_size. Use it in the next
918
+ # ListTasks request to continue.
919
+ # Corresponds to the JSON property `nextPageToken`
920
+ # @return [String]
921
+ attr_accessor :next_page_token
922
+
923
+ # The resulting list of Tasks.
924
+ # Corresponds to the JSON property `tasks`
925
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Task>]
926
+ attr_accessor :tasks
927
+
928
+ def initialize(**args)
929
+ update!(**args)
930
+ end
931
+
932
+ # Update properties of this object
933
+ def update!(**args)
934
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
935
+ @tasks = args[:tasks] if args.key?(:tasks)
936
+ end
937
+ end
938
+
939
+ # ResourceRequirements describes the compute resource requirements.
940
+ class GoogleCloudRunV2ResourceRequirements
941
+ include Google::Apis::Core::Hashable
942
+
943
+ # Determines whether CPU should be throttled or not outside of requests.
944
+ # Corresponds to the JSON property `cpuIdle`
945
+ # @return [Boolean]
946
+ attr_accessor :cpu_idle
947
+ alias_method :cpu_idle?, :cpu_idle
948
+
949
+ # Only memory and CPU are supported. Note: The only supported values for CPU are
950
+ # '1', '2', and '4'. Setting 4 CPU requires at least 2Gi of memory. The values
951
+ # of the map is string form of the 'quantity' k8s type: https://github.com/
952
+ # kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/
953
+ # resource/quantity.go
954
+ # Corresponds to the JSON property `limits`
955
+ # @return [Hash<String,String>]
956
+ attr_accessor :limits
957
+
958
+ def initialize(**args)
959
+ update!(**args)
960
+ end
961
+
962
+ # Update properties of this object
963
+ def update!(**args)
964
+ @cpu_idle = args[:cpu_idle] if args.key?(:cpu_idle)
965
+ @limits = args[:limits] if args.key?(:limits)
966
+ end
967
+ end
968
+
969
+ # A Revision is an immutable snapshot of code and configuration. A Revision
970
+ # references a container image. Revisions are only created by updates to its
971
+ # parent Service.
972
+ class GoogleCloudRunV2Revision
973
+ include Google::Apis::Core::Hashable
974
+
975
+ # KRM-style annotations for the resource.
976
+ # Corresponds to the JSON property `annotations`
977
+ # @return [Hash<String,String>]
978
+ attr_accessor :annotations
979
+
980
+ # Output only. The Condition of this Revision, containing its readiness status,
981
+ # and detailed error information in case it did not reach a serving state.
982
+ # Corresponds to the JSON property `conditions`
983
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Condition>]
984
+ attr_accessor :conditions
985
+
986
+ # Indicates whether Confidential Cloud Run is enabled in this Revision.
987
+ # Corresponds to the JSON property `confidential`
988
+ # @return [Boolean]
989
+ attr_accessor :confidential
990
+ alias_method :confidential?, :confidential
991
+
992
+ # Sets the maximum number of requests that each serving instance can receive.
993
+ # Corresponds to the JSON property `containerConcurrency`
994
+ # @return [Fixnum]
995
+ attr_accessor :container_concurrency
996
+
997
+ # Holds the single container that defines the unit of execution for this
998
+ # Revision.
999
+ # Corresponds to the JSON property `containers`
1000
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Container>]
1001
+ attr_accessor :containers
1002
+
1003
+ # Output only. The creation time.
1004
+ # Corresponds to the JSON property `createTime`
1005
+ # @return [String]
1006
+ attr_accessor :create_time
1007
+
1008
+ # Output only. For a deleted resource, the deletion time. It is only populated
1009
+ # as a response to a Delete request.
1010
+ # Corresponds to the JSON property `deleteTime`
1011
+ # @return [String]
1012
+ attr_accessor :delete_time
1013
+
1014
+ # A reference to a customer managed encryption key (CMEK) to use to encrypt this
1015
+ # container image. For more information, go to https://cloud.google.com/run/docs/
1016
+ # securing/using-cmek
1017
+ # Corresponds to the JSON property `encryptionKey`
1018
+ # @return [String]
1019
+ attr_accessor :encryption_key
1020
+
1021
+ # Output only. A system-generated fingerprint for this version of the resource.
1022
+ # May be used to detect modification conflict during updates.
1023
+ # Corresponds to the JSON property `etag`
1024
+ # @return [String]
1025
+ attr_accessor :etag
1026
+
1027
+ # The execution environment being used to host this Revision.
1028
+ # Corresponds to the JSON property `executionEnvironment`
1029
+ # @return [String]
1030
+ attr_accessor :execution_environment
1031
+
1032
+ # Output only. For a deleted resource, the time after which it will be
1033
+ # permamently deleted. It is only populated as a response to a Delete request.
1034
+ # Corresponds to the JSON property `expireTime`
1035
+ # @return [String]
1036
+ attr_accessor :expire_time
1037
+
1038
+ # Output only. A number that monotonically increases every time the user
1039
+ # modifies the desired state.
1040
+ # Corresponds to the JSON property `generation`
1041
+ # @return [Fixnum]
1042
+ attr_accessor :generation
1043
+
1044
+ # KRM-style labels for the resource. User-provided labels are shared with Google'
1045
+ # s billing system, so they can be used to filter, or break down billing charges
1046
+ # by team, component, environment, state, etc. For more information, visit https:
1047
+ # //cloud.google.com/resource-manager/docs/creating-managing-labels or https://
1048
+ # cloud.google.com/run/docs/configuring/labels Cloud Run will populate some
1049
+ # labels with 'run.googleapis.com' or 'serving.knative.dev' namespaces. Those
1050
+ # labels are read-only, and user changes will not be preserved.
1051
+ # Corresponds to the JSON property `labels`
1052
+ # @return [Hash<String,String>]
1053
+ attr_accessor :labels
1054
+
1055
+ # Set the launch stage to a preview stage on write to allow use of preview
1056
+ # features in that stage. On read, describes whether the resource uses preview
1057
+ # features. Launch Stages are defined at [Google Cloud Platform Launch Stages](
1058
+ # https://cloud.google.com/terms/launch-stages).
1059
+ # Corresponds to the JSON property `launchStage`
1060
+ # @return [String]
1061
+ attr_accessor :launch_stage
1062
+
1063
+ # Output only. The Google Console URI to obtain logs for the Revision.
1064
+ # Corresponds to the JSON property `logUri`
1065
+ # @return [String]
1066
+ attr_accessor :log_uri
1067
+
1068
+ # Output only. The unique name of this Revision.
1069
+ # Corresponds to the JSON property `name`
1070
+ # @return [String]
1071
+ attr_accessor :name
1072
+
1073
+ # Output only. The generation of this Revision currently serving traffic. See
1074
+ # comments in `reconciling` for additional information on reconciliation process
1075
+ # in Cloud Run.
1076
+ # Corresponds to the JSON property `observedGeneration`
1077
+ # @return [Fixnum]
1078
+ attr_accessor :observed_generation
1079
+
1080
+ # Output only. Indicates whether the resource's reconciliation is still in
1081
+ # progress. See comments in `Service.reconciling` for additional information on
1082
+ # reconciliation process in Cloud Run.
1083
+ # Corresponds to the JSON property `reconciling`
1084
+ # @return [Boolean]
1085
+ attr_accessor :reconciling
1086
+ alias_method :reconciling?, :reconciling
1087
+
1088
+ # Settings for revision-level scaling settings.
1089
+ # Corresponds to the JSON property `scaling`
1090
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2RevisionScaling]
1091
+ attr_accessor :scaling
1092
+
1093
+ # Output only. The name of the parent service.
1094
+ # Corresponds to the JSON property `service`
1095
+ # @return [String]
1096
+ attr_accessor :service
1097
+
1098
+ # Email address of the IAM service account associated with the revision of the
1099
+ # service. The service account represents the identity of the running revision,
1100
+ # and determines what permissions the revision has.
1101
+ # Corresponds to the JSON property `serviceAccount`
1102
+ # @return [String]
1103
+ attr_accessor :service_account
1104
+
1105
+ # Max allowed time for an instance to respond to a request.
1106
+ # Corresponds to the JSON property `timeout`
1107
+ # @return [String]
1108
+ attr_accessor :timeout
1109
+
1110
+ # Output only. Server assigned unique identifier for the Revision. The value is
1111
+ # a UUID4 string and guaranteed to remain unchanged until the resource is
1112
+ # deleted.
1113
+ # Corresponds to the JSON property `uid`
1114
+ # @return [String]
1115
+ attr_accessor :uid
1116
+
1117
+ # Output only. The last-modified time.
1118
+ # Corresponds to the JSON property `updateTime`
1119
+ # @return [String]
1120
+ attr_accessor :update_time
1121
+
1122
+ # A list of Volumes to make available to containers.
1123
+ # Corresponds to the JSON property `volumes`
1124
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Volume>]
1125
+ attr_accessor :volumes
1126
+
1127
+ # VPC Access settings. For more information on creating a VPC Connector, visit
1128
+ # https://cloud.google.com/vpc/docs/configure-serverless-vpc-access For
1129
+ # information on how to configure Cloud Run with an existing VPC Connector,
1130
+ # visit https://cloud.google.com/run/docs/configuring/connecting-vpc
1131
+ # Corresponds to the JSON property `vpcAccess`
1132
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2VpcAccess]
1133
+ attr_accessor :vpc_access
1134
+
1135
+ def initialize(**args)
1136
+ update!(**args)
1137
+ end
1138
+
1139
+ # Update properties of this object
1140
+ def update!(**args)
1141
+ @annotations = args[:annotations] if args.key?(:annotations)
1142
+ @conditions = args[:conditions] if args.key?(:conditions)
1143
+ @confidential = args[:confidential] if args.key?(:confidential)
1144
+ @container_concurrency = args[:container_concurrency] if args.key?(:container_concurrency)
1145
+ @containers = args[:containers] if args.key?(:containers)
1146
+ @create_time = args[:create_time] if args.key?(:create_time)
1147
+ @delete_time = args[:delete_time] if args.key?(:delete_time)
1148
+ @encryption_key = args[:encryption_key] if args.key?(:encryption_key)
1149
+ @etag = args[:etag] if args.key?(:etag)
1150
+ @execution_environment = args[:execution_environment] if args.key?(:execution_environment)
1151
+ @expire_time = args[:expire_time] if args.key?(:expire_time)
1152
+ @generation = args[:generation] if args.key?(:generation)
1153
+ @labels = args[:labels] if args.key?(:labels)
1154
+ @launch_stage = args[:launch_stage] if args.key?(:launch_stage)
1155
+ @log_uri = args[:log_uri] if args.key?(:log_uri)
1156
+ @name = args[:name] if args.key?(:name)
1157
+ @observed_generation = args[:observed_generation] if args.key?(:observed_generation)
1158
+ @reconciling = args[:reconciling] if args.key?(:reconciling)
1159
+ @scaling = args[:scaling] if args.key?(:scaling)
1160
+ @service = args[:service] if args.key?(:service)
1161
+ @service_account = args[:service_account] if args.key?(:service_account)
1162
+ @timeout = args[:timeout] if args.key?(:timeout)
1163
+ @uid = args[:uid] if args.key?(:uid)
1164
+ @update_time = args[:update_time] if args.key?(:update_time)
1165
+ @volumes = args[:volumes] if args.key?(:volumes)
1166
+ @vpc_access = args[:vpc_access] if args.key?(:vpc_access)
1167
+ end
1168
+ end
1169
+
1170
+ # Settings for revision-level scaling settings.
1171
+ class GoogleCloudRunV2RevisionScaling
1172
+ include Google::Apis::Core::Hashable
1173
+
1174
+ # Maximum number of serving instances that this resource should have.
1175
+ # Corresponds to the JSON property `maxInstanceCount`
1176
+ # @return [Fixnum]
1177
+ attr_accessor :max_instance_count
1178
+
1179
+ # Minimum number of serving instances that this resource should have.
1180
+ # Corresponds to the JSON property `minInstanceCount`
1181
+ # @return [Fixnum]
1182
+ attr_accessor :min_instance_count
1183
+
1184
+ def initialize(**args)
1185
+ update!(**args)
1186
+ end
1187
+
1188
+ # Update properties of this object
1189
+ def update!(**args)
1190
+ @max_instance_count = args[:max_instance_count] if args.key?(:max_instance_count)
1191
+ @min_instance_count = args[:min_instance_count] if args.key?(:min_instance_count)
1192
+ end
1193
+ end
1194
+
1195
+ # RevisionTemplate describes the data a revision should have when created from a
1196
+ # template.
1197
+ class GoogleCloudRunV2RevisionTemplate
1198
+ include Google::Apis::Core::Hashable
1199
+
1200
+ # KRM-style annotations for the resource.
1201
+ # Corresponds to the JSON property `annotations`
1202
+ # @return [Hash<String,String>]
1203
+ attr_accessor :annotations
1204
+
1205
+ # Enables Confidential Cloud Run in Revisions created using this template.
1206
+ # Corresponds to the JSON property `confidential`
1207
+ # @return [Boolean]
1208
+ attr_accessor :confidential
1209
+ alias_method :confidential?, :confidential
1210
+
1211
+ # Sets the maximum number of requests that each serving instance can receive.
1212
+ # Corresponds to the JSON property `containerConcurrency`
1213
+ # @return [Fixnum]
1214
+ attr_accessor :container_concurrency
1215
+
1216
+ # Holds the single container that defines the unit of execution for this
1217
+ # Revision.
1218
+ # Corresponds to the JSON property `containers`
1219
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Container>]
1220
+ attr_accessor :containers
1221
+
1222
+ # A reference to a customer managed encryption key (CMEK) to use to encrypt this
1223
+ # container image. For more information, go to https://cloud.google.com/run/docs/
1224
+ # securing/using-cmek
1225
+ # Corresponds to the JSON property `encryptionKey`
665
1226
  # @return [String]
666
1227
  attr_accessor :encryption_key
667
1228
 
@@ -718,19 +1279,47 @@ module Google
718
1279
 
719
1280
  # Update properties of this object
720
1281
  def update!(**args)
721
- @annotations = args[:annotations] if args.key?(:annotations)
722
- @confidential = args[:confidential] if args.key?(:confidential)
723
- @container_concurrency = args[:container_concurrency] if args.key?(:container_concurrency)
724
- @containers = args[:containers] if args.key?(:containers)
725
- @encryption_key = args[:encryption_key] if args.key?(:encryption_key)
726
- @execution_environment = args[:execution_environment] if args.key?(:execution_environment)
727
- @labels = args[:labels] if args.key?(:labels)
728
- @revision = args[:revision] if args.key?(:revision)
729
- @scaling = args[:scaling] if args.key?(:scaling)
730
- @service_account = args[:service_account] if args.key?(:service_account)
731
- @timeout = args[:timeout] if args.key?(:timeout)
732
- @volumes = args[:volumes] if args.key?(:volumes)
733
- @vpc_access = args[:vpc_access] if args.key?(:vpc_access)
1282
+ @annotations = args[:annotations] if args.key?(:annotations)
1283
+ @confidential = args[:confidential] if args.key?(:confidential)
1284
+ @container_concurrency = args[:container_concurrency] if args.key?(:container_concurrency)
1285
+ @containers = args[:containers] if args.key?(:containers)
1286
+ @encryption_key = args[:encryption_key] if args.key?(:encryption_key)
1287
+ @execution_environment = args[:execution_environment] if args.key?(:execution_environment)
1288
+ @labels = args[:labels] if args.key?(:labels)
1289
+ @revision = args[:revision] if args.key?(:revision)
1290
+ @scaling = args[:scaling] if args.key?(:scaling)
1291
+ @service_account = args[:service_account] if args.key?(:service_account)
1292
+ @timeout = args[:timeout] if args.key?(:timeout)
1293
+ @volumes = args[:volumes] if args.key?(:volumes)
1294
+ @vpc_access = args[:vpc_access] if args.key?(:vpc_access)
1295
+ end
1296
+ end
1297
+
1298
+ # Request message to create a new Execution of a Job.
1299
+ class GoogleCloudRunV2RunJobRequest
1300
+ include Google::Apis::Core::Hashable
1301
+
1302
+ # A system-generated fingerprint for this version of the resource. May be used
1303
+ # to detect modification conflict during updates.
1304
+ # Corresponds to the JSON property `etag`
1305
+ # @return [String]
1306
+ attr_accessor :etag
1307
+
1308
+ # Indicates that the request should be validated without actually deleting any
1309
+ # resources.
1310
+ # Corresponds to the JSON property `validateOnly`
1311
+ # @return [Boolean]
1312
+ attr_accessor :validate_only
1313
+ alias_method :validate_only?, :validate_only
1314
+
1315
+ def initialize(**args)
1316
+ update!(**args)
1317
+ end
1318
+
1319
+ # Update properties of this object
1320
+ def update!(**args)
1321
+ @etag = args[:etag] if args.key?(:etag)
1322
+ @validate_only = args[:validate_only] if args.key?(:validate_only)
734
1323
  end
735
1324
  end
736
1325
 
@@ -1051,6 +1640,331 @@ module Google
1051
1640
  end
1052
1641
  end
1053
1642
 
1643
+ # Task represents a single run of a container to completion.
1644
+ class GoogleCloudRunV2Task
1645
+ include Google::Apis::Core::Hashable
1646
+
1647
+ # KRM-style annotations for the resource.
1648
+ # Corresponds to the JSON property `annotations`
1649
+ # @return [Hash<String,String>]
1650
+ attr_accessor :annotations
1651
+
1652
+ # Output only. Represents time when the Task was completed. It is not guaranteed
1653
+ # to be set in happens-before order across separate operations.
1654
+ # Corresponds to the JSON property `completionTime`
1655
+ # @return [String]
1656
+ attr_accessor :completion_time
1657
+
1658
+ # Output only. The Condition of this Task, containing its readiness status, and
1659
+ # detailed error information in case it did not reach the desired state.
1660
+ # Corresponds to the JSON property `conditions`
1661
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Condition>]
1662
+ attr_accessor :conditions
1663
+
1664
+ # Holds the single container that defines the unit of execution for this task.
1665
+ # Corresponds to the JSON property `containers`
1666
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Container>]
1667
+ attr_accessor :containers
1668
+
1669
+ # Output only. Represents time when the task was created by the job controller.
1670
+ # It is not guaranteed to be set in happens-before order across separate
1671
+ # operations.
1672
+ # Corresponds to the JSON property `createTime`
1673
+ # @return [String]
1674
+ attr_accessor :create_time
1675
+
1676
+ # Output only. For a deleted resource, the deletion time. It is only populated
1677
+ # as a response to a Delete request.
1678
+ # Corresponds to the JSON property `deleteTime`
1679
+ # @return [String]
1680
+ attr_accessor :delete_time
1681
+
1682
+ # Output only. A reference to a customer managed encryption key (CMEK) to use to
1683
+ # encrypt this container image. For more information, go to https://cloud.google.
1684
+ # com/run/docs/securing/using-cmek
1685
+ # Corresponds to the JSON property `encryptionKey`
1686
+ # @return [String]
1687
+ attr_accessor :encryption_key
1688
+
1689
+ # Output only. A system-generated fingerprint for this version of the resource.
1690
+ # May be used to detect modification conflict during updates.
1691
+ # Corresponds to the JSON property `etag`
1692
+ # @return [String]
1693
+ attr_accessor :etag
1694
+
1695
+ # Output only. The name of the parent Execution.
1696
+ # Corresponds to the JSON property `execution`
1697
+ # @return [String]
1698
+ attr_accessor :execution
1699
+
1700
+ # The execution environment being used to host this Task.
1701
+ # Corresponds to the JSON property `executionEnvironment`
1702
+ # @return [String]
1703
+ attr_accessor :execution_environment
1704
+
1705
+ # Output only. For a deleted resource, the time after which it will be
1706
+ # permamently deleted. It is only populated as a response to a Delete request.
1707
+ # Corresponds to the JSON property `expireTime`
1708
+ # @return [String]
1709
+ attr_accessor :expire_time
1710
+
1711
+ # Output only. A number that monotonically increases every time the user
1712
+ # modifies the desired state.
1713
+ # Corresponds to the JSON property `generation`
1714
+ # @return [Fixnum]
1715
+ attr_accessor :generation
1716
+
1717
+ # Output only. Index of the Task, unique per execution, and beginning at 0.
1718
+ # Corresponds to the JSON property `index`
1719
+ # @return [Fixnum]
1720
+ attr_accessor :index
1721
+
1722
+ # Output only. The name of the parent Job.
1723
+ # Corresponds to the JSON property `job`
1724
+ # @return [String]
1725
+ attr_accessor :job
1726
+
1727
+ # KRM-style labels for the resource. User-provided labels are shared with Google'
1728
+ # s billing system, so they can be used to filter, or break down billing charges
1729
+ # by team, component, environment, state, etc. For more information, visit https:
1730
+ # //cloud.google.com/resource-manager/docs/creating-managing-labels or https://
1731
+ # cloud.google.com/run/docs/configuring/labels Cloud Run will populate some
1732
+ # labels with 'run.googleapis.com' or 'serving.knative.dev' namespaces. Those
1733
+ # labels are read-only, and user changes will not be preserved.
1734
+ # Corresponds to the JSON property `labels`
1735
+ # @return [Hash<String,String>]
1736
+ attr_accessor :labels
1737
+
1738
+ # Result of a task attempt.
1739
+ # Corresponds to the JSON property `lastAttemptResult`
1740
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2TaskAttemptResult]
1741
+ attr_accessor :last_attempt_result
1742
+
1743
+ # Set the launch stage to a preview stage on write to allow use of preview
1744
+ # features in that stage. On read, describes whether the resource uses preview
1745
+ # features. Launch Stages are defined at [Google Cloud Platform Launch Stages](
1746
+ # https://cloud.google.com/terms/launch-stages).
1747
+ # Corresponds to the JSON property `launchStage`
1748
+ # @return [String]
1749
+ attr_accessor :launch_stage
1750
+
1751
+ # Number of retries allowed per Task, before marking this Task failed.
1752
+ # Corresponds to the JSON property `maxRetries`
1753
+ # @return [Fixnum]
1754
+ attr_accessor :max_retries
1755
+
1756
+ # Output only. The unique name of this Task.
1757
+ # Corresponds to the JSON property `name`
1758
+ # @return [String]
1759
+ attr_accessor :name
1760
+
1761
+ # Output only. The generation of this Task. See comments in `Job.reconciling`
1762
+ # for additional information on reconciliation process in Cloud Run.
1763
+ # Corresponds to the JSON property `observedGeneration`
1764
+ # @return [Fixnum]
1765
+ attr_accessor :observed_generation
1766
+
1767
+ # Output only. Indicates whether the resource's reconciliation is still in
1768
+ # progress. See comments in `Job.reconciling` for additional information on
1769
+ # reconciliation process in Cloud Run.
1770
+ # Corresponds to the JSON property `reconciling`
1771
+ # @return [Boolean]
1772
+ attr_accessor :reconciling
1773
+ alias_method :reconciling?, :reconciling
1774
+
1775
+ # Output only. The number of times this Task was retried. Tasks are retried when
1776
+ # they fail up to the maxRetries limit.
1777
+ # Corresponds to the JSON property `retried`
1778
+ # @return [Fixnum]
1779
+ attr_accessor :retried
1780
+
1781
+ # Email address of the IAM service account associated with the Task of a Job.
1782
+ # The service account represents the identity of the running task, and
1783
+ # determines what permissions the task has. If not provided, the task will use
1784
+ # the project's default service account.
1785
+ # Corresponds to the JSON property `serviceAccount`
1786
+ # @return [String]
1787
+ attr_accessor :service_account
1788
+
1789
+ # Output only. Represents time when the task started to run. It is not
1790
+ # guaranteed to be set in happens-before order across separate operations.
1791
+ # Corresponds to the JSON property `startTime`
1792
+ # @return [String]
1793
+ attr_accessor :start_time
1794
+
1795
+ # Max allowed time duration the Task may be active before the system will
1796
+ # actively try to mark it failed and kill associated containers. This applies
1797
+ # per attempt of a task, meaning each retry can run for the full timeout.
1798
+ # Corresponds to the JSON property `timeout`
1799
+ # @return [String]
1800
+ attr_accessor :timeout
1801
+
1802
+ # Output only. Server assigned unique identifier for the Task. The value is a
1803
+ # UUID4 string and guaranteed to remain unchanged until the resource is deleted.
1804
+ # Corresponds to the JSON property `uid`
1805
+ # @return [String]
1806
+ attr_accessor :uid
1807
+
1808
+ # Output only. The last-modified time.
1809
+ # Corresponds to the JSON property `updateTime`
1810
+ # @return [String]
1811
+ attr_accessor :update_time
1812
+
1813
+ # A list of Volumes to make available to containers.
1814
+ # Corresponds to the JSON property `volumes`
1815
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Volume>]
1816
+ attr_accessor :volumes
1817
+
1818
+ # VPC Access settings. For more information on creating a VPC Connector, visit
1819
+ # https://cloud.google.com/vpc/docs/configure-serverless-vpc-access For
1820
+ # information on how to configure Cloud Run with an existing VPC Connector,
1821
+ # visit https://cloud.google.com/run/docs/configuring/connecting-vpc
1822
+ # Corresponds to the JSON property `vpcAccess`
1823
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2VpcAccess]
1824
+ attr_accessor :vpc_access
1825
+
1826
+ def initialize(**args)
1827
+ update!(**args)
1828
+ end
1829
+
1830
+ # Update properties of this object
1831
+ def update!(**args)
1832
+ @annotations = args[:annotations] if args.key?(:annotations)
1833
+ @completion_time = args[:completion_time] if args.key?(:completion_time)
1834
+ @conditions = args[:conditions] if args.key?(:conditions)
1835
+ @containers = args[:containers] if args.key?(:containers)
1836
+ @create_time = args[:create_time] if args.key?(:create_time)
1837
+ @delete_time = args[:delete_time] if args.key?(:delete_time)
1838
+ @encryption_key = args[:encryption_key] if args.key?(:encryption_key)
1839
+ @etag = args[:etag] if args.key?(:etag)
1840
+ @execution = args[:execution] if args.key?(:execution)
1841
+ @execution_environment = args[:execution_environment] if args.key?(:execution_environment)
1842
+ @expire_time = args[:expire_time] if args.key?(:expire_time)
1843
+ @generation = args[:generation] if args.key?(:generation)
1844
+ @index = args[:index] if args.key?(:index)
1845
+ @job = args[:job] if args.key?(:job)
1846
+ @labels = args[:labels] if args.key?(:labels)
1847
+ @last_attempt_result = args[:last_attempt_result] if args.key?(:last_attempt_result)
1848
+ @launch_stage = args[:launch_stage] if args.key?(:launch_stage)
1849
+ @max_retries = args[:max_retries] if args.key?(:max_retries)
1850
+ @name = args[:name] if args.key?(:name)
1851
+ @observed_generation = args[:observed_generation] if args.key?(:observed_generation)
1852
+ @reconciling = args[:reconciling] if args.key?(:reconciling)
1853
+ @retried = args[:retried] if args.key?(:retried)
1854
+ @service_account = args[:service_account] if args.key?(:service_account)
1855
+ @start_time = args[:start_time] if args.key?(:start_time)
1856
+ @timeout = args[:timeout] if args.key?(:timeout)
1857
+ @uid = args[:uid] if args.key?(:uid)
1858
+ @update_time = args[:update_time] if args.key?(:update_time)
1859
+ @volumes = args[:volumes] if args.key?(:volumes)
1860
+ @vpc_access = args[:vpc_access] if args.key?(:vpc_access)
1861
+ end
1862
+ end
1863
+
1864
+ # Result of a task attempt.
1865
+ class GoogleCloudRunV2TaskAttemptResult
1866
+ include Google::Apis::Core::Hashable
1867
+
1868
+ # Output only. The exit code of this attempt. This may be unset if the container
1869
+ # was unable to exit cleanly with a code due to some other failure. See status
1870
+ # field for possible failure details.
1871
+ # Corresponds to the JSON property `exitCode`
1872
+ # @return [Fixnum]
1873
+ attr_accessor :exit_code
1874
+
1875
+ # The `Status` type defines a logical error model that is suitable for different
1876
+ # programming environments, including REST APIs and RPC APIs. It is used by [
1877
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
1878
+ # data: error code, error message, and error details. You can find out more
1879
+ # about this error model and how to work with it in the [API Design Guide](https:
1880
+ # //cloud.google.com/apis/design/errors).
1881
+ # Corresponds to the JSON property `status`
1882
+ # @return [Google::Apis::RunV2::GoogleRpcStatus]
1883
+ attr_accessor :status
1884
+
1885
+ def initialize(**args)
1886
+ update!(**args)
1887
+ end
1888
+
1889
+ # Update properties of this object
1890
+ def update!(**args)
1891
+ @exit_code = args[:exit_code] if args.key?(:exit_code)
1892
+ @status = args[:status] if args.key?(:status)
1893
+ end
1894
+ end
1895
+
1896
+ # TaskTemplate describes the data a task should have when created from a
1897
+ # template.
1898
+ class GoogleCloudRunV2TaskTemplate
1899
+ include Google::Apis::Core::Hashable
1900
+
1901
+ # Holds the single container that defines the unit of execution for this task.
1902
+ # Corresponds to the JSON property `containers`
1903
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Container>]
1904
+ attr_accessor :containers
1905
+
1906
+ # A reference to a customer managed encryption key (CMEK) to use to encrypt this
1907
+ # container image. For more information, go to https://cloud.google.com/run/docs/
1908
+ # securing/using-cmek
1909
+ # Corresponds to the JSON property `encryptionKey`
1910
+ # @return [String]
1911
+ attr_accessor :encryption_key
1912
+
1913
+ # The execution environment being used to host this Task.
1914
+ # Corresponds to the JSON property `executionEnvironment`
1915
+ # @return [String]
1916
+ attr_accessor :execution_environment
1917
+
1918
+ # Number of retries allowed per Task, before marking this Task failed.
1919
+ # Corresponds to the JSON property `maxRetries`
1920
+ # @return [Fixnum]
1921
+ attr_accessor :max_retries
1922
+
1923
+ # Email address of the IAM service account associated with the Task of a Job.
1924
+ # The service account represents the identity of the running task, and
1925
+ # determines what permissions the task has. If not provided, the task will use
1926
+ # the project's default service account.
1927
+ # Corresponds to the JSON property `serviceAccount`
1928
+ # @return [String]
1929
+ attr_accessor :service_account
1930
+
1931
+ # Max allowed time duration the Task may be active before the system will
1932
+ # actively try to mark it failed and kill associated containers. This applies
1933
+ # per attempt of a task, meaning each retry can run for the full timeout.
1934
+ # Corresponds to the JSON property `timeout`
1935
+ # @return [String]
1936
+ attr_accessor :timeout
1937
+
1938
+ # A list of Volumes to make available to containers.
1939
+ # Corresponds to the JSON property `volumes`
1940
+ # @return [Array<Google::Apis::RunV2::GoogleCloudRunV2Volume>]
1941
+ attr_accessor :volumes
1942
+
1943
+ # VPC Access settings. For more information on creating a VPC Connector, visit
1944
+ # https://cloud.google.com/vpc/docs/configure-serverless-vpc-access For
1945
+ # information on how to configure Cloud Run with an existing VPC Connector,
1946
+ # visit https://cloud.google.com/run/docs/configuring/connecting-vpc
1947
+ # Corresponds to the JSON property `vpcAccess`
1948
+ # @return [Google::Apis::RunV2::GoogleCloudRunV2VpcAccess]
1949
+ attr_accessor :vpc_access
1950
+
1951
+ def initialize(**args)
1952
+ update!(**args)
1953
+ end
1954
+
1955
+ # Update properties of this object
1956
+ def update!(**args)
1957
+ @containers = args[:containers] if args.key?(:containers)
1958
+ @encryption_key = args[:encryption_key] if args.key?(:encryption_key)
1959
+ @execution_environment = args[:execution_environment] if args.key?(:execution_environment)
1960
+ @max_retries = args[:max_retries] if args.key?(:max_retries)
1961
+ @service_account = args[:service_account] if args.key?(:service_account)
1962
+ @timeout = args[:timeout] if args.key?(:timeout)
1963
+ @volumes = args[:volumes] if args.key?(:volumes)
1964
+ @vpc_access = args[:vpc_access] if args.key?(:vpc_access)
1965
+ end
1966
+ end
1967
+
1054
1968
  # Holds a single traffic routing entry for the Service. Allocations can be done
1055
1969
  # to a specific Revision name, or pointing to the latest Ready Revision.
1056
1970
  class GoogleCloudRunV2TrafficTarget
@@ -1361,7 +2275,7 @@ module Google
1361
2275
  # @return [Google::Apis::RunV2::GoogleTypeExpr]
1362
2276
  attr_accessor :condition
1363
2277
 
1364
- # Specifies the principals requesting access for a Cloud Platform resource. `
2278
+ # Specifies the principals requesting access for a Google Cloud resource. `
1365
2279
  # members` can have the following values: * `allUsers`: A special identifier
1366
2280
  # that represents anyone who is on the internet; with or without a Google
1367
2281
  # account. * `allAuthenticatedUsers`: A special identifier that represents
@@ -1562,7 +2476,7 @@ module Google
1562
2476
  include Google::Apis::Core::Hashable
1563
2477
 
1564
2478
  # The set of permissions to check for the `resource`. Permissions with wildcards
1565
- # (such as '*' or 'storage.*') are not allowed. For more information see [IAM
2479
+ # (such as `*` or `storage.*`) are not allowed. For more information see [IAM
1566
2480
  # Overview](https://cloud.google.com/iam/docs/overview#permissions).
1567
2481
  # Corresponds to the JSON property `permissions`
1568
2482
  # @return [Array<String>]