Skip to content

Commit

Permalink
feat(run): update the API
Browse files Browse the repository at this point in the history
#### run:v1

The following keys were changed:
- schemas.Container.properties.readinessProbe.description
- schemas.GoogleDevtoolsCloudbuildV1BuildOptions.properties.defaultLogsBucketBehavior.enum
- schemas.GoogleDevtoolsCloudbuildV1BuildOptions.properties.defaultLogsBucketBehavior.enumDescriptions
- schemas.ObjectMeta.properties.annotations.description

#### run:v2

The following keys were added:
- schemas.GoogleCloudRunV2Service.properties.invokerIamDisabled.description
- schemas.GoogleCloudRunV2Service.properties.invokerIamDisabled.type
- schemas.GoogleCloudRunV2ServiceScaling.properties.scalingMode.description
- schemas.GoogleCloudRunV2ServiceScaling.properties.scalingMode.enum
- schemas.GoogleCloudRunV2ServiceScaling.properties.scalingMode.enumDescriptions
- schemas.GoogleCloudRunV2ServiceScaling.properties.scalingMode.type
- schemas.GoogleCloudRunV2SubmitBuildResponse.properties.baseImageWarning.description
- schemas.GoogleCloudRunV2SubmitBuildResponse.properties.baseImageWarning.type

The following keys were changed:
- schemas.GoogleCloudRunV2RevisionScaling.properties.maxInstanceCount.description
- schemas.GoogleCloudRunV2ServiceScaling.properties.minInstanceCount.description
- schemas.GoogleDevtoolsCloudbuildV1BuildOptions.properties.defaultLogsBucketBehavior.enum
- schemas.GoogleDevtoolsCloudbuildV1BuildOptions.properties.defaultLogsBucketBehavior.enumDescriptions
  • Loading branch information
yoshi-automation authored and sofisl committed Oct 10, 2024
1 parent ee326f7 commit a68919f
Show file tree
Hide file tree
Showing 4 changed files with 52 additions and 14 deletions.
12 changes: 7 additions & 5 deletions discovery/run-v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -2614,7 +2614,7 @@
}
}
},
"revision": "20240802",
"revision": "20240927",
"rootUrl": "https://run.googleapis.com/",
"schemas": {
"Addressable": {
Expand Down Expand Up @@ -2934,7 +2934,7 @@
},
"readinessProbe": {
"$ref": "Probe",
"description": "Not supported by Cloud Run."
"description": "Readiness probe to be used for health checks. Not supported by Cloud Run."
},
"resources": {
"$ref": "ResourceRequirements",
Expand Down Expand Up @@ -3801,11 +3801,13 @@
"description": "Optional. Option to specify how default logs buckets are setup.",
"enum": [
"DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED",
"REGIONAL_USER_OWNED_BUCKET"
"REGIONAL_USER_OWNED_BUCKET",
"LEGACY_BUCKET"
],
"enumDescriptions": [
"Unspecified.",
"Bucket is located in user-owned project in the same region as the build. The builder service account must have access to create and write to Cloud Storage buckets in the build project."
"Bucket is located in user-owned project in the same region as the build. The builder service account must have access to create and write to Cloud Storage buckets in the build project.",
"Bucket is located in a Google-owned project and is not regionalized."
],
"type": "string"
},
Expand Down Expand Up @@ -5381,7 +5383,7 @@
"additionalProperties": {
"type": "string"
},
"description": "Unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. * `autoscaling.knative.dev/maxScale`: Revision. * `autoscaling.knative.dev/minScale`: Revision. * `run.googleapis.com/base-images`: Service, Revision. * `run.googleapis.com/binary-authorization-breakglass`: Service, Job, * `run.googleapis.com/binary-authorization`: Service, Job, Execution. * `run.googleapis.com/build-base-image`: Service. * `run.googleapis.com/build-environment-variables`: Service. * `run.googleapis.com/build-id`: Service. * `run.googleapis.com/build-name`: Service. * `run.googleapis.com/build-service-account`: Service. * `run.googleapis.com/build-worker-pool`: Service. * `run.googleapis.com/client-name`: All resources. * `run.googleapis.com/cloudsql-instances`: Revision, Execution. * `run.googleapis.com/container-dependencies`: Revision . * `run.googleapis.com/cpu-throttling`: Revision. * `run.googleapis.com/custom-audiences`: Service. * `run.googleapis.com/default-url-disabled`: Service. * `run.googleapis.com/description`: Service. * `run.googleapis.com/enable-automatic-updates`: Service. * `run.googleapis.com/encryption-key-shutdown-hours`: Revision * `run.googleapis.com/encryption-key`: Revision, Execution. * `run.googleapis.com/execution-environment`: Revision, Execution. * `run.googleapis.com/function-target`: Service. * `run.googleapis.com/gc-traffic-tags`: Service. * `run.googleapis.com/image-uri`: Service. * `run.googleapis.com/ingress`: Service. * `run.googleapis.com/launch-stage`: Service, Job. * `run.googleapis.com/minScale`: Service (ALPHA) * `run.googleapis.com/network-interfaces`: Revision, Execution. * `run.googleapis.com/post-key-revocation-action-type`: Revision. * `run.googleapis.com/secrets`: Revision, Execution. * `run.googleapis.com/secure-session-agent`: Revision. * `run.googleapis.com/sessionAffinity`: Revision. * `run.googleapis.com/source-location`: Service. * `run.googleapis.com/startup-cpu-boost`: Revision. * `run.googleapis.com/vpc-access-connector`: Revision, Execution. * `run.googleapis.com/vpc-access-egress`: Revision, Execution.",
"description": "Unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. * `autoscaling.knative.dev/maxScale`: Revision. * `autoscaling.knative.dev/minScale`: Revision. * `run.googleapis.com/base-images`: Service, Revision. * `run.googleapis.com/binary-authorization-breakglass`: Service, Job, * `run.googleapis.com/binary-authorization`: Service, Job, Execution. * `run.googleapis.com/build-base-image`: Service. * `run.googleapis.com/build-enable-automatic-updates`: Service. * `run.googleapis.com/build-environment-variables`: Service. * `run.googleapis.com/build-function-target`: Service. * `run.googleapis.com/build-id`: Service. * `run.googleapis.com/build-image-uri`: Service. * `run.googleapis.com/build-name`: Service. * `run.googleapis.com/build-service-account`: Service. * `run.googleapis.com/build-source-location`: Service. * `run.googleapis.com/build-worker-pool`: Service. * `run.googleapis.com/client-name`: All resources. * `run.googleapis.com/cloudsql-instances`: Revision, Execution. * `run.googleapis.com/container-dependencies`: Revision . * `run.googleapis.com/cpu-throttling`: Revision. * `run.googleapis.com/custom-audiences`: Service. * `run.googleapis.com/default-url-disabled`: Service. * `run.googleapis.com/description`: Service. * `run.googleapis.com/encryption-key-shutdown-hours`: Revision * `run.googleapis.com/encryption-key`: Revision, Execution. * `run.googleapis.com/execution-environment`: Revision, Execution. * `run.googleapis.com/gc-traffic-tags`: Service. * `run.googleapis.com/ingress`: Service. * `run.googleapis.com/launch-stage`: Service, Job. * `run.googleapis.com/minScale`: Service * `run.googleapis.com/network-interfaces`: Revision, Execution. * `run.googleapis.com/post-key-revocation-action-type`: Revision. * `run.googleapis.com/secrets`: Revision, Execution. * `run.googleapis.com/secure-session-agent`: Revision. * `run.googleapis.com/sessionAffinity`: Revision. * `run.googleapis.com/startup-cpu-boost`: Revision. * `run.googleapis.com/vpc-access-connector`: Revision, Execution. * `run.googleapis.com/vpc-access-egress`: Revision, Execution.",
"type": "object"
},
"clusterName": {
Expand Down
34 changes: 29 additions & 5 deletions discovery/run-v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -1526,7 +1526,7 @@
}
}
},
"revision": "20240823",
"revision": "20240927",
"rootUrl": "https://run.googleapis.com/",
"schemas": {
"GoogleCloudRunV2BinaryAuthorization": {
Expand Down Expand Up @@ -2984,7 +2984,7 @@
"id": "GoogleCloudRunV2RevisionScaling",
"properties": {
"maxInstanceCount": {
"description": "Optional. Maximum number of serving instances that this resource should have.",
"description": "Optional. Maximum number of serving instances that this resource should have. When unspecified, the field is set to the server default value of 100. For more information see https://cloud.google.com/run/docs/configuring/max-instances",
"format": "int32",
"type": "integer"
},
Expand Down Expand Up @@ -3258,6 +3258,10 @@
],
"type": "string"
},
"invokerIamDisabled": {
"description": "Optional. Disables IAM permission check for run.routes.invoke for callers of this service. This setting should not be used with external ingress.",
"type": "boolean"
},
"labels": {
"additionalProperties": {
"type": "string"
Expand Down Expand Up @@ -3395,9 +3399,23 @@
"id": "GoogleCloudRunV2ServiceScaling",
"properties": {
"minInstanceCount": {
"description": "Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving. (BETA)",
"description": "Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving.",
"format": "int32",
"type": "integer"
},
"scalingMode": {
"description": "Optional. The scaling mode for the service.",
"enum": [
"SCALING_MODE_UNSPECIFIED",
"AUTOMATIC",
"MANUAL"
],
"enumDescriptions": [
"Unspecified.",
"Scale based on traffic between min and max instances.",
"Scale to exactly min instances and ignore max instances."
],
"type": "string"
}
},
"type": "object"
Expand Down Expand Up @@ -3468,6 +3486,10 @@
"description": "URI of the base builder image in Artifact Registry being used in the build. Used to opt into automatic base image updates.",
"type": "string"
},
"baseImageWarning": {
"description": "Warning message for the base image.",
"type": "string"
},
"buildOperation": {
"$ref": "GoogleLongrunningOperation",
"description": "Cloud Build operation to be polled via CloudBuild API."
Expand Down Expand Up @@ -4291,11 +4313,13 @@
"description": "Optional. Option to specify how default logs buckets are setup.",
"enum": [
"DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED",
"REGIONAL_USER_OWNED_BUCKET"
"REGIONAL_USER_OWNED_BUCKET",
"LEGACY_BUCKET"
],
"enumDescriptions": [
"Unspecified.",
"Bucket is located in user-owned project in the same region as the build. The builder service account must have access to create and write to Cloud Storage buckets in the build project."
"Bucket is located in user-owned project in the same region as the build. The builder service account must have access to create and write to Cloud Storage buckets in the build project.",
"Bucket is located in a Google-owned project and is not regionalized."
],
"type": "string"
},
Expand Down
4 changes: 2 additions & 2 deletions src/apis/run/v1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ export namespace run_v1 {
*/
ports?: Schema$ContainerPort[];
/**
* Not supported by Cloud Run.
* Readiness probe to be used for health checks. Not supported by Cloud Run.
*/
readinessProbe?: Schema$Probe;
/**
Expand Down Expand Up @@ -2111,7 +2111,7 @@ export namespace run_v1 {
*/
export interface Schema$ObjectMeta {
/**
* Unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. * `autoscaling.knative.dev/maxScale`: Revision. * `autoscaling.knative.dev/minScale`: Revision. * `run.googleapis.com/base-images`: Service, Revision. * `run.googleapis.com/binary-authorization-breakglass`: Service, Job, * `run.googleapis.com/binary-authorization`: Service, Job, Execution. * `run.googleapis.com/build-base-image`: Service. * `run.googleapis.com/build-environment-variables`: Service. * `run.googleapis.com/build-id`: Service. * `run.googleapis.com/build-name`: Service. * `run.googleapis.com/build-service-account`: Service. * `run.googleapis.com/build-worker-pool`: Service. * `run.googleapis.com/client-name`: All resources. * `run.googleapis.com/cloudsql-instances`: Revision, Execution. * `run.googleapis.com/container-dependencies`: Revision . * `run.googleapis.com/cpu-throttling`: Revision. * `run.googleapis.com/custom-audiences`: Service. * `run.googleapis.com/default-url-disabled`: Service. * `run.googleapis.com/description`: Service. * `run.googleapis.com/enable-automatic-updates`: Service. * `run.googleapis.com/encryption-key-shutdown-hours`: Revision * `run.googleapis.com/encryption-key`: Revision, Execution. * `run.googleapis.com/execution-environment`: Revision, Execution. * `run.googleapis.com/function-target`: Service. * `run.googleapis.com/gc-traffic-tags`: Service. * `run.googleapis.com/image-uri`: Service. * `run.googleapis.com/ingress`: Service. * `run.googleapis.com/launch-stage`: Service, Job. * `run.googleapis.com/minScale`: Service (ALPHA) * `run.googleapis.com/network-interfaces`: Revision, Execution. * `run.googleapis.com/post-key-revocation-action-type`: Revision. * `run.googleapis.com/secrets`: Revision, Execution. * `run.googleapis.com/secure-session-agent`: Revision. * `run.googleapis.com/sessionAffinity`: Revision. * `run.googleapis.com/source-location`: Service. * `run.googleapis.com/startup-cpu-boost`: Revision. * `run.googleapis.com/vpc-access-connector`: Revision, Execution. * `run.googleapis.com/vpc-access-egress`: Revision, Execution.
* Unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. * `autoscaling.knative.dev/maxScale`: Revision. * `autoscaling.knative.dev/minScale`: Revision. * `run.googleapis.com/base-images`: Service, Revision. * `run.googleapis.com/binary-authorization-breakglass`: Service, Job, * `run.googleapis.com/binary-authorization`: Service, Job, Execution. * `run.googleapis.com/build-base-image`: Service. * `run.googleapis.com/build-enable-automatic-updates`: Service. * `run.googleapis.com/build-environment-variables`: Service. * `run.googleapis.com/build-function-target`: Service. * `run.googleapis.com/build-id`: Service. * `run.googleapis.com/build-image-uri`: Service. * `run.googleapis.com/build-name`: Service. * `run.googleapis.com/build-service-account`: Service. * `run.googleapis.com/build-source-location`: Service. * `run.googleapis.com/build-worker-pool`: Service. * `run.googleapis.com/client-name`: All resources. * `run.googleapis.com/cloudsql-instances`: Revision, Execution. * `run.googleapis.com/container-dependencies`: Revision . * `run.googleapis.com/cpu-throttling`: Revision. * `run.googleapis.com/custom-audiences`: Service. * `run.googleapis.com/default-url-disabled`: Service. * `run.googleapis.com/description`: Service. * `run.googleapis.com/encryption-key-shutdown-hours`: Revision * `run.googleapis.com/encryption-key`: Revision, Execution. * `run.googleapis.com/execution-environment`: Revision, Execution. * `run.googleapis.com/gc-traffic-tags`: Service. * `run.googleapis.com/ingress`: Service. * `run.googleapis.com/launch-stage`: Service, Job. * `run.googleapis.com/minScale`: Service * `run.googleapis.com/network-interfaces`: Revision, Execution. * `run.googleapis.com/post-key-revocation-action-type`: Revision. * `run.googleapis.com/secrets`: Revision, Execution. * `run.googleapis.com/secure-session-agent`: Revision. * `run.googleapis.com/sessionAffinity`: Revision. * `run.googleapis.com/startup-cpu-boost`: Revision. * `run.googleapis.com/vpc-access-connector`: Revision, Execution. * `run.googleapis.com/vpc-access-egress`: Revision, Execution.
*/
annotations?: {[key: string]: string} | null;
/**
Expand Down
16 changes: 14 additions & 2 deletions src/apis/run/v2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1065,7 +1065,7 @@ export namespace run_v2 {
*/
export interface Schema$GoogleCloudRunV2RevisionScaling {
/**
* Optional. Maximum number of serving instances that this resource should have.
* Optional. Maximum number of serving instances that this resource should have. When unspecified, the field is set to the server default value of 100. For more information see https://cloud.google.com/run/docs/configuring/max-instances
*/
maxInstanceCount?: number | null;
/**
Expand Down Expand Up @@ -1262,6 +1262,10 @@ export namespace run_v2 {
* Optional. Provides the ingress settings for this Service. On output, returns the currently observed ingress settings, or INGRESS_TRAFFIC_UNSPECIFIED if no revision is active.
*/
ingress?: string | null;
/**
* Optional. Disables IAM permission check for run.routes.invoke for callers of this service. This setting should not be used with external ingress.
*/
invokerIamDisabled?: boolean | null;
/**
* Optional. Unstructured key value map that can be used to organize and categorize objects. User-provided labels are shared with Google's billing system, so they can be used to filter, or break down billing charges by team, component, environment, state, etc. For more information, visit https://cloud.google.com/resource-manager/docs/creating-managing-labels or https://cloud.google.com/run/docs/configuring/labels. Cloud Run API v2 does not support labels with `run.googleapis.com`, `cloud.googleapis.com`, `serving.knative.dev`, or `autoscaling.knative.dev` namespaces, and they will be rejected. All system labels in v1 now have a corresponding field in v2 Service.
*/
Expand Down Expand Up @@ -1349,9 +1353,13 @@ export namespace run_v2 {
*/
export interface Schema$GoogleCloudRunV2ServiceScaling {
/**
* Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving. (BETA)
* Optional. total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving.
*/
minInstanceCount?: number | null;
/**
* Optional. The scaling mode for the service.
*/
scalingMode?: string | null;
}
/**
* Location of the source in an archive file in Google Cloud Storage.
Expand Down Expand Up @@ -1411,6 +1419,10 @@ export namespace run_v2 {
* URI of the base builder image in Artifact Registry being used in the build. Used to opt into automatic base image updates.
*/
baseImageUri?: string | null;
/**
* Warning message for the base image.
*/
baseImageWarning?: string | null;
/**
* Cloud Build operation to be polled via CloudBuild API.
*/
Expand Down

0 comments on commit a68919f

Please sign in to comment.