From 3dd983b5616c058887d38e9423388d236acc27dc Mon Sep 17 00:00:00 2001 From: Yoshi Automation Date: Tue, 20 Dec 2022 07:07:57 +0000 Subject: [PATCH] feat(batch): update the api #### batch:v1 The following keys were added: - schemas.AgentMetadata.properties.instancePreemptionNoticeReceived.type (Total Keys: 1) - schemas.Environment.properties.encryptedVariables.$ref (Total Keys: 1) - schemas.Environment.properties.secretVariables (Total Keys: 2) - schemas.KMSEnvMap (Total Keys: 4) - schemas.ReportAgentStateResponse.properties.defaultReportInterval (Total Keys: 2) --- .../dyn/batch_v1.projects.locations.jobs.html | 84 +++++++++++++++++++ .../batch_v1.projects.locations.state.html | 18 +++- .../discovery_cache/documents/batch.v1.json | 38 ++++++++- 3 files changed, 137 insertions(+), 3 deletions(-) diff --git a/docs/dyn/batch_v1.projects.locations.jobs.html b/docs/dyn/batch_v1.projects.locations.jobs.html index 0333a32407f..3a3b04988f1 100644 --- a/docs/dyn/batch_v1.projects.locations.jobs.html +++ b/docs/dyn/batch_v1.projects.locations.jobs.html @@ -233,6 +233,13 @@

Method Details

"taskCountPerNode": "A String", # Max number of tasks that can be run on a VM at the same time. If not specified, the system will decide a value based on available compute resources on a VM and task requirements. "taskEnvironments": [ # An array of environment variable mappings, which are passed to Tasks with matching indices. If task_environments is used then task_count should not be specified in the request (and will be ignored). Task count will be the length of task_environments. Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in addition to any environment variables set in task_environments, specifying the number of Tasks in the Task's parent TaskGroup, and the specific Task's index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). task_environments supports up to 200 entries. { # An Environment describes a collection of environment variables to set when executing Tasks. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -245,6 +252,13 @@

Method Details

"memoryMib": "A String", # Memory in MiB. }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables to set before running the Task. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -286,6 +300,13 @@

Method Details

], }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup). + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -443,6 +464,13 @@

Method Details

"taskCountPerNode": "A String", # Max number of tasks that can be run on a VM at the same time. If not specified, the system will decide a value based on available compute resources on a VM and task requirements. "taskEnvironments": [ # An array of environment variable mappings, which are passed to Tasks with matching indices. If task_environments is used then task_count should not be specified in the request (and will be ignored). Task count will be the length of task_environments. Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in addition to any environment variables set in task_environments, specifying the number of Tasks in the Task's parent TaskGroup, and the specific Task's index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). task_environments supports up to 200 entries. { # An Environment describes a collection of environment variables to set when executing Tasks. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -455,6 +483,13 @@

Method Details

"memoryMib": "A String", # Memory in MiB. }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables to set before running the Task. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -496,6 +531,13 @@

Method Details

], }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup). + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -695,6 +737,13 @@

Method Details

"taskCountPerNode": "A String", # Max number of tasks that can be run on a VM at the same time. If not specified, the system will decide a value based on available compute resources on a VM and task requirements. "taskEnvironments": [ # An array of environment variable mappings, which are passed to Tasks with matching indices. If task_environments is used then task_count should not be specified in the request (and will be ignored). Task count will be the length of task_environments. Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in addition to any environment variables set in task_environments, specifying the number of Tasks in the Task's parent TaskGroup, and the specific Task's index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). task_environments supports up to 200 entries. { # An Environment describes a collection of environment variables to set when executing Tasks. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -707,6 +756,13 @@

Method Details

"memoryMib": "A String", # Memory in MiB. }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables to set before running the Task. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -748,6 +804,13 @@

Method Details

], }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup). + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -963,6 +1026,13 @@

Method Details

"taskCountPerNode": "A String", # Max number of tasks that can be run on a VM at the same time. If not specified, the system will decide a value based on available compute resources on a VM and task requirements. "taskEnvironments": [ # An array of environment variable mappings, which are passed to Tasks with matching indices. If task_environments is used then task_count should not be specified in the request (and will be ignored). Task count will be the length of task_environments. Tasks get a BATCH_TASK_INDEX and BATCH_TASK_COUNT environment variable, in addition to any environment variables set in task_environments, specifying the number of Tasks in the Task's parent TaskGroup, and the specific Task's index in the TaskGroup (0 through BATCH_TASK_COUNT - 1). task_environments supports up to 200 entries. { # An Environment describes a collection of environment variables to set when executing Tasks. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -975,6 +1045,13 @@

Method Details

"memoryMib": "A String", # Memory in MiB. }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables to set before running the Task. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -1016,6 +1093,13 @@

Method Details

], }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup). + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, diff --git a/docs/dyn/batch_v1.projects.locations.state.html b/docs/dyn/batch_v1.projects.locations.state.html index 9ef5bdd3d43..e1d676d0ed5 100644 --- a/docs/dyn/batch_v1.projects.locations.state.html +++ b/docs/dyn/batch_v1.projects.locations.state.html @@ -126,12 +126,13 @@

Method Details

"bootTime": "A String", # Boot timestamp of the VM OS "scriptStartupTime": "A String", # Startup time of the Batch VM script. }, - "metadata": { # AgentMetadata never changes for a single instance of VM agent. # Agent metadata. + "metadata": { # VM Agent Metadata. # Agent metadata. "creationTime": "A String", # When the VM agent started. Use agent_startup_time instead. "creator": "A String", # Full name of the entity that created this vm. For MIG, this path is: projects/{project}/regions/{region}/InstanceGroupManagers/{igm} The value is retrieved from the vm metadata key of "created-by". "imageVersion": "A String", # image version for the VM that this agent is installed on. "instance": "A String", # GCP instance name (go/instance-name). "instanceId": "A String", # GCP instance ID (go/instance-id). + "instancePreemptionNoticeReceived": True or False, # If the GCP instance has received preemption notice. "osRelease": { # parsed contents of /etc/os-release "a_key": "A String", }, @@ -149,6 +150,7 @@

Method Details

An object of the form: { # Response to ReportAgentStateRequest. + "defaultReportInterval": "A String", # Default report interval override "minReportInterval": "A String", # Minimum report interval override "tasks": [ # Tasks assigned to the agent { # TODO(b/182501497) The message needs to be redefined when the Agent API server updates data in storage per the backend design. @@ -161,6 +163,13 @@

Method Details

"memoryMib": "A String", # Memory in MiB. }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables to set before running the Task. + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, @@ -202,6 +211,13 @@

Method Details

], }, "environment": { # An Environment describes a collection of environment variables to set when executing Tasks. # Environment variables for this Runnable (overrides variables set for the whole Task or TaskGroup). + "encryptedVariables": { # An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values. + "cipherText": "A String", # The value of the cipherText response from the `encrypt` method. + "keyName": "A String", # The name of the KMS key that will be used to decrypt the cipher text. + }, + "secretVariables": { # A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable. + "a_key": "A String", + }, "variables": { # A map of environment variable names to values. "a_key": "A String", }, diff --git a/googleapiclient/discovery_cache/documents/batch.v1.json b/googleapiclient/discovery_cache/documents/batch.v1.json index 0a15a1b161f..188b9656e1e 100644 --- a/googleapiclient/discovery_cache/documents/batch.v1.json +++ b/googleapiclient/discovery_cache/documents/batch.v1.json @@ -643,7 +643,7 @@ } } }, - "revision": "20221201", + "revision": "20221212", "rootUrl": "https://batch.googleapis.com/", "schemas": { "Accelerator": { @@ -725,7 +725,7 @@ "type": "object" }, "AgentMetadata": { - "description": "AgentMetadata never changes for a single instance of VM agent.", + "description": "VM Agent Metadata.", "id": "AgentMetadata", "properties": { "creationTime": { @@ -750,6 +750,10 @@ "format": "uint64", "type": "string" }, + "instancePreemptionNoticeReceived": { + "description": "If the GCP instance has received preemption notice.", + "type": "boolean" + }, "osRelease": { "additionalProperties": { "type": "string" @@ -1093,6 +1097,17 @@ "description": "An Environment describes a collection of environment variables to set when executing Tasks.", "id": "Environment", "properties": { + "encryptedVariables": { + "$ref": "KMSEnvMap", + "description": "An encrypted JSON dictionary where the key/value pairs correspond to environment variable names and their values." + }, + "secretVariables": { + "additionalProperties": { + "type": "string" + }, + "description": "A map of environment variable names to Secret Manager secret names. The VM will access the named secrets to set the value of each environment variable.", + "type": "object" + }, "variables": { "additionalProperties": { "type": "string" @@ -1364,6 +1379,20 @@ }, "type": "object" }, + "KMSEnvMap": { + "id": "KMSEnvMap", + "properties": { + "cipherText": { + "description": "The value of the cipherText response from the `encrypt` method.", + "type": "string" + }, + "keyName": { + "description": "The name of the KMS key that will be used to decrypt the cipher text.", + "type": "string" + } + }, + "type": "object" + }, "LifecyclePolicy": { "description": "LifecyclePolicy describes how to deal with task failures based on different conditions.", "id": "LifecyclePolicy", @@ -1791,6 +1820,11 @@ "description": "Response to ReportAgentStateRequest.", "id": "ReportAgentStateResponse", "properties": { + "defaultReportInterval": { + "description": "Default report interval override", + "format": "google-duration", + "type": "string" + }, "minReportInterval": { "description": "Minimum report interval override", "format": "google-duration",