From 7d46b4d9f1654a792272ad67647c598ee46f4a77 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Mon, 20 May 2024 00:24:19 -0700 Subject: [PATCH] feat(all): auto-regenerate discovery clients (#2597) --- clouddeploy/v1/clouddeploy-api.json | 12 +- clouddeploy/v1/clouddeploy-gen.go | 13 +- eventarc/v1/eventarc-api.json | 6 +- eventarc/v1/eventarc-gen.go | 5 +- file/v1/file-api.json | 86 ++++- file/v1/file-gen.go | 77 ++++ file/v1beta1/file-api.json | 83 ++++- file/v1beta1/file-gen.go | 77 ++++ gkehub/v1/gkehub-api.json | 15 +- gkehub/v1/gkehub-gen.go | 5 + gkehub/v1alpha/gkehub-api.json | 22 +- gkehub/v1alpha/gkehub-gen.go | 8 + gkehub/v1beta/gkehub-api.json | 22 +- gkehub/v1beta/gkehub-gen.go | 8 + metastore/v1/metastore-api.json | 168 ++++++++- metastore/v1/metastore-gen.go | 528 ++++++++++++++++++++++++++- metastore/v1alpha/metastore-api.json | 40 +- metastore/v1alpha/metastore-gen.go | 40 +- metastore/v1beta/metastore-api.json | 40 +- metastore/v1beta/metastore-gen.go | 40 +- workflows/v1/workflows-api.json | 23 +- workflows/v1/workflows-gen.go | 15 +- 22 files changed, 1289 insertions(+), 44 deletions(-) diff --git a/clouddeploy/v1/clouddeploy-api.json b/clouddeploy/v1/clouddeploy-api.json index bbef59b9a78..816046cf377 100644 --- a/clouddeploy/v1/clouddeploy-api.json +++ b/clouddeploy/v1/clouddeploy-api.json @@ -2065,7 +2065,7 @@ } } }, - "revision": "20240505", + "revision": "20240511", "rootUrl": "https://clouddeploy.googleapis.com/", "schemas": { "AbandonReleaseRequest": { @@ -2397,7 +2397,7 @@ "id": "AutomationRolloutMetadata", "properties": { "advanceAutomationRuns": { - "description": "Output only. The IDs of the AutomationRuns initiated by an advance rollout rule.", + "description": "Output only. The names of the AutomationRuns initiated by an advance rollout rule.", "items": { "type": "string" }, @@ -2410,12 +2410,12 @@ "type": "string" }, "promoteAutomationRun": { - "description": "Output only. The ID of the AutomationRun initiated by a promote release rule.", + "description": "Output only. The name of the AutomationRun initiated by a promote release rule.", "readOnly": true, "type": "string" }, "repairAutomationRuns": { - "description": "Output only. The IDs of the AutomationRuns initiated by a repair rollout rule.", + "description": "Output only. The names of the AutomationRuns initiated by a repair rollout rule.", "items": { "type": "string" }, @@ -3387,6 +3387,10 @@ }, "type": "array" }, + "verbose": { + "description": "Optional. If true, additional logging will be enabled when running builds in this execution environment.", + "type": "boolean" + }, "workerPool": { "description": "Optional. The resource name of the `WorkerPool`, with the format `projects/{project}/locations/{location}/workerPools/{worker_pool}`. If this optional field is unspecified, the default Cloud Build pool will be used.", "type": "string" diff --git a/clouddeploy/v1/clouddeploy-gen.go b/clouddeploy/v1/clouddeploy-gen.go index 17a2dda32fa..4a03ef23736 100644 --- a/clouddeploy/v1/clouddeploy-gen.go +++ b/clouddeploy/v1/clouddeploy-gen.go @@ -698,16 +698,16 @@ func (s *AutomationResourceSelector) MarshalJSON() ([]byte, error) { // AutomationRolloutMetadata: AutomationRolloutMetadata contains // Automation-related actions that were performed on a rollout. type AutomationRolloutMetadata struct { - // AdvanceAutomationRuns: Output only. The IDs of the AutomationRuns initiated - // by an advance rollout rule. + // AdvanceAutomationRuns: Output only. The names of the AutomationRuns + // initiated by an advance rollout rule. AdvanceAutomationRuns []string `json:"advanceAutomationRuns,omitempty"` // CurrentRepairAutomationRun: Output only. The current AutomationRun repairing // the rollout. CurrentRepairAutomationRun string `json:"currentRepairAutomationRun,omitempty"` - // PromoteAutomationRun: Output only. The ID of the AutomationRun initiated by - // a promote release rule. + // PromoteAutomationRun: Output only. The name of the AutomationRun initiated + // by a promote release rule. PromoteAutomationRun string `json:"promoteAutomationRun,omitempty"` - // RepairAutomationRuns: Output only. The IDs of the AutomationRuns initiated + // RepairAutomationRuns: Output only. The names of the AutomationRuns initiated // by a repair rollout rule. RepairAutomationRuns []string `json:"repairAutomationRuns,omitempty"` // ForceSendFields is a list of field names (e.g. "AdvanceAutomationRuns") to @@ -1907,6 +1907,9 @@ type ExecutionConfig struct { // "PREDEPLOY" - Use for predeploy job execution. // "POSTDEPLOY" - Use for postdeploy job execution. Usages []string `json:"usages,omitempty"` + // Verbose: Optional. If true, additional logging will be enabled when running + // builds in this execution environment. + Verbose bool `json:"verbose,omitempty"` // WorkerPool: Optional. The resource name of the `WorkerPool`, with the format // `projects/{project}/locations/{location}/workerPools/{worker_pool}`. If this // optional field is unspecified, the default Cloud Build pool will be used. diff --git a/eventarc/v1/eventarc-api.json b/eventarc/v1/eventarc-api.json index fc22c1ade9d..010179db5b5 100644 --- a/eventarc/v1/eventarc-api.json +++ b/eventarc/v1/eventarc-api.json @@ -1197,7 +1197,7 @@ } } }, - "revision": "20240417", + "revision": "20240510", "rootUrl": "https://eventarc.googleapis.com/", "schemas": { "AuditConfig": { @@ -1827,11 +1827,11 @@ "type": "object" }, "NetworkConfig": { - "description": "Represents a network config to be used for destination resolution and connectivity.", + "description": "Network Configuration that can be inherited by other protos.", "id": "NetworkConfig", "properties": { "networkAttachment": { - "description": "Required. Name of the NetworkAttachment that allows access to the destination VPC. Format: `projects/{PROJECT_ID}/regions/{REGION}/networkAttachments/{NETWORK_ATTACHMENT_NAME}`", + "description": "Required. Name of the NetworkAttachment that allows access to the customer's VPC. Format: `projects/{PROJECT_ID}/regions/{REGION}/networkAttachments/{NETWORK_ATTACHMENT_NAME}`", "type": "string" } }, diff --git a/eventarc/v1/eventarc-gen.go b/eventarc/v1/eventarc-gen.go index 0559a8a745e..7fecdc39e20 100644 --- a/eventarc/v1/eventarc-gen.go +++ b/eventarc/v1/eventarc-gen.go @@ -1168,11 +1168,10 @@ func (s *Location) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// NetworkConfig: Represents a network config to be used for destination -// resolution and connectivity. +// NetworkConfig: Network Configuration that can be inherited by other protos. type NetworkConfig struct { // NetworkAttachment: Required. Name of the NetworkAttachment that allows - // access to the destination VPC. Format: + // access to the customer's VPC. Format: // `projects/{PROJECT_ID}/regions/{REGION}/networkAttachments/{NETWORK_ATTACHMEN // T_NAME}` NetworkAttachment string `json:"networkAttachment,omitempty"` diff --git a/file/v1/file-api.json b/file/v1/file-api.json index ca58cba1996..e3004c7b550 100644 --- a/file/v1/file-api.json +++ b/file/v1/file-api.json @@ -874,7 +874,7 @@ } } }, - "revision": "20240307", + "revision": "20240511", "rootUrl": "https://file.googleapis.com/", "schemas": { "Backup": { @@ -1413,6 +1413,10 @@ }, "type": "array" }, + "replication": { + "$ref": "Replication", + "description": "Optional. Replicaition configuration." + }, "satisfiesPzi": { "description": "Output only. Reserved for future use.", "readOnly": true, @@ -1890,6 +1894,86 @@ }, "type": "object" }, + "ReplicaConfig": { + "description": "Replica configuration for the instance.", + "id": "ReplicaConfig", + "properties": { + "lastActiveSyncTime": { + "description": "Output only. The timestamp of the latest replication snapshot taken on the active instance and is already replicated safely.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "peerInstance": { + "description": "Optional. The peer instance.", + "type": "string" + }, + "state": { + "description": "Output only. The replica state.", + "enum": [ + "STATE_UNSPECIFIED", + "CREATING", + "READY", + "REMOVING", + "FAILED" + ], + "enumDescriptions": [ + "State not set.", + "The replica is being created.", + "The replica is ready.", + "The replica is being removed.", + "The replica is experiencing an issue and might be unusable. You can get further details from the `stateReasons` field of the `ReplicaConfig` object." + ], + "readOnly": true, + "type": "string" + }, + "stateReasons": { + "description": "Output only. Additional information about the replication state, if available.", + "items": { + "enum": [ + "STATE_REASON_UNSPECIFIED", + "PEER_INSTANCE_UNREACHABLE" + ], + "enumDescriptions": [ + "Reason not specified.", + "The peer instance is unreachable." + ], + "type": "string" + }, + "readOnly": true, + "type": "array" + } + }, + "type": "object" + }, + "Replication": { + "description": "Replication specifications.", + "id": "Replication", + "properties": { + "replicas": { + "description": "Optional. Replicas configuration on the instance. For now, only a single replica config is supported.", + "items": { + "$ref": "ReplicaConfig" + }, + "type": "array" + }, + "role": { + "description": "Optional. The replication role.", + "enum": [ + "ROLE_UNSPECIFIED", + "ACTIVE", + "STANDBY" + ], + "enumDescriptions": [ + "Role not set.", + "The instance is a Active replication member, functions as the replication source instance.", + "The instance is a Standby replication member, functions as the replication destination instance." + ], + "type": "string" + } + }, + "type": "object" + }, "RestoreInstanceRequest": { "description": "RestoreInstanceRequest restores an existing instance's file share from a backup.", "id": "RestoreInstanceRequest", diff --git a/file/v1/file-gen.go b/file/v1/file-gen.go index d4e05f70b49..72bf8834e92 100644 --- a/file/v1/file-gen.go +++ b/file/v1/file-gen.go @@ -861,6 +861,8 @@ type Instance struct { // Networks: VPC networks to which the instance is connected. For this version, // only a single network is supported. Networks []*NetworkConfig `json:"networks,omitempty"` + // Replication: Optional. Replicaition configuration. + Replication *Replication `json:"replication,omitempty"` // SatisfiesPzi: Output only. Reserved for future use. SatisfiesPzi bool `json:"satisfiesPzi,omitempty"` // SatisfiesPzs: Output only. Reserved for future use. @@ -1403,6 +1405,81 @@ func (s *OperationMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// ReplicaConfig: Replica configuration for the instance. +type ReplicaConfig struct { + // LastActiveSyncTime: Output only. The timestamp of the latest replication + // snapshot taken on the active instance and is already replicated safely. + LastActiveSyncTime string `json:"lastActiveSyncTime,omitempty"` + // PeerInstance: Optional. The peer instance. + PeerInstance string `json:"peerInstance,omitempty"` + // State: Output only. The replica state. + // + // Possible values: + // "STATE_UNSPECIFIED" - State not set. + // "CREATING" - The replica is being created. + // "READY" - The replica is ready. + // "REMOVING" - The replica is being removed. + // "FAILED" - The replica is experiencing an issue and might be unusable. You + // can get further details from the `stateReasons` field of the `ReplicaConfig` + // object. + State string `json:"state,omitempty"` + // StateReasons: Output only. Additional information about the replication + // state, if available. + // + // Possible values: + // "STATE_REASON_UNSPECIFIED" - Reason not specified. + // "PEER_INSTANCE_UNREACHABLE" - The peer instance is unreachable. + StateReasons []string `json:"stateReasons,omitempty"` + // ForceSendFields is a list of field names (e.g. "LastActiveSyncTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "LastActiveSyncTime") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ReplicaConfig) MarshalJSON() ([]byte, error) { + type NoMethod ReplicaConfig + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Replication: Replication specifications. +type Replication struct { + // Replicas: Optional. Replicas configuration on the instance. For now, only a + // single replica config is supported. + Replicas []*ReplicaConfig `json:"replicas,omitempty"` + // Role: Optional. The replication role. + // + // Possible values: + // "ROLE_UNSPECIFIED" - Role not set. + // "ACTIVE" - The instance is a Active replication member, functions as the + // replication source instance. + // "STANDBY" - The instance is a Standby replication member, functions as the + // replication destination instance. + Role string `json:"role,omitempty"` + // ForceSendFields is a list of field names (e.g. "Replicas") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Replicas") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Replication) MarshalJSON() ([]byte, error) { + type NoMethod Replication + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // RestoreInstanceRequest: RestoreInstanceRequest restores an existing // instance's file share from a backup. type RestoreInstanceRequest struct { diff --git a/file/v1beta1/file-api.json b/file/v1beta1/file-api.json index 5a2372ed644..e55e2883888 100644 --- a/file/v1beta1/file-api.json +++ b/file/v1beta1/file-api.json @@ -1069,7 +1069,7 @@ } } }, - "revision": "20240307", + "revision": "20240511", "rootUrl": "https://file.googleapis.com/", "schemas": { "Backup": { @@ -1663,6 +1663,10 @@ ], "type": "string" }, + "replication": { + "$ref": "Replication", + "description": "Optional. Replicaition configuration." + }, "satisfiesPzi": { "description": "Output only. Reserved for future use.", "readOnly": true, @@ -2209,6 +2213,83 @@ "properties": {}, "type": "object" }, + "ReplicaConfig": { + "description": "Replica configuration for the instance.", + "id": "ReplicaConfig", + "properties": { + "lastActiveSyncTime": { + "description": "Output only. The timestamp of the latest replication snapshot taken on the active instance and is already replicated safely.", + "format": "google-datetime", + "type": "string" + }, + "peerInstance": { + "description": "The peer instance.", + "type": "string" + }, + "state": { + "description": "Output only. The replica state.", + "enum": [ + "STATE_UNSPECIFIED", + "CREATING", + "READY", + "REMOVING", + "FAILED" + ], + "enumDescriptions": [ + "State not set.", + "The replica is being created.", + "The replica is ready.", + "The replica is being removed.", + "The replica is experiencing an issue and might be unusable. You can get further details from the `stateReasons` field of the `ReplicaConfig` object." + ], + "type": "string" + }, + "stateReasons": { + "description": "Output only. Additional information about the replication state, if available.", + "items": { + "enum": [ + "STATE_REASON_UNSPECIFIED", + "PEER_INSTANCE_UNREACHABLE" + ], + "enumDescriptions": [ + "Reason not specified.", + "The peer instance is unreachable." + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "Replication": { + "description": "Replication specifications.", + "id": "Replication", + "properties": { + "replicas": { + "description": "Replicas configuration on the instance. For now, only a single replica config is supported.", + "items": { + "$ref": "ReplicaConfig" + }, + "type": "array" + }, + "role": { + "description": "Output only. The replication role.", + "enum": [ + "ROLE_UNSPECIFIED", + "ACTIVE", + "STANDBY" + ], + "enumDescriptions": [ + "Role not set.", + "The instance is a Active replication member, functions as the replication source instance.", + "The instance is a Standby replication member, functions as the replication destination instance." + ], + "type": "string" + } + }, + "type": "object" + }, "RestoreInstanceRequest": { "description": "RestoreInstanceRequest restores an existing instance's file share from a backup.", "id": "RestoreInstanceRequest", diff --git a/file/v1beta1/file-gen.go b/file/v1beta1/file-gen.go index 02229ed52f4..d1443716343 100644 --- a/file/v1beta1/file-gen.go +++ b/file/v1beta1/file-gen.go @@ -924,6 +924,8 @@ type Instance struct { // "NFS_V3" - NFS 3.0. // "NFS_V4_1" - NFS 4.1. Protocol string `json:"protocol,omitempty"` + // Replication: Optional. Replicaition configuration. + Replication *Replication `json:"replication,omitempty"` // SatisfiesPzi: Output only. Reserved for future use. SatisfiesPzi bool `json:"satisfiesPzi,omitempty"` // SatisfiesPzs: Output only. Reserved for future use. @@ -1543,6 +1545,81 @@ func (s *OperationMetadata) MarshalJSON() ([]byte, error) { type PromoteReplicaRequest struct { } +// ReplicaConfig: Replica configuration for the instance. +type ReplicaConfig struct { + // LastActiveSyncTime: Output only. The timestamp of the latest replication + // snapshot taken on the active instance and is already replicated safely. + LastActiveSyncTime string `json:"lastActiveSyncTime,omitempty"` + // PeerInstance: The peer instance. + PeerInstance string `json:"peerInstance,omitempty"` + // State: Output only. The replica state. + // + // Possible values: + // "STATE_UNSPECIFIED" - State not set. + // "CREATING" - The replica is being created. + // "READY" - The replica is ready. + // "REMOVING" - The replica is being removed. + // "FAILED" - The replica is experiencing an issue and might be unusable. You + // can get further details from the `stateReasons` field of the `ReplicaConfig` + // object. + State string `json:"state,omitempty"` + // StateReasons: Output only. Additional information about the replication + // state, if available. + // + // Possible values: + // "STATE_REASON_UNSPECIFIED" - Reason not specified. + // "PEER_INSTANCE_UNREACHABLE" - The peer instance is unreachable. + StateReasons []string `json:"stateReasons,omitempty"` + // ForceSendFields is a list of field names (e.g. "LastActiveSyncTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "LastActiveSyncTime") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ReplicaConfig) MarshalJSON() ([]byte, error) { + type NoMethod ReplicaConfig + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Replication: Replication specifications. +type Replication struct { + // Replicas: Replicas configuration on the instance. For now, only a single + // replica config is supported. + Replicas []*ReplicaConfig `json:"replicas,omitempty"` + // Role: Output only. The replication role. + // + // Possible values: + // "ROLE_UNSPECIFIED" - Role not set. + // "ACTIVE" - The instance is a Active replication member, functions as the + // replication source instance. + // "STANDBY" - The instance is a Standby replication member, functions as the + // replication destination instance. + Role string `json:"role,omitempty"` + // ForceSendFields is a list of field names (e.g. "Replicas") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Replicas") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Replication) MarshalJSON() ([]byte, error) { + type NoMethod Replication + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // RestoreInstanceRequest: RestoreInstanceRequest restores an existing // instance's file share from a backup. type RestoreInstanceRequest struct { diff --git a/gkehub/v1/gkehub-api.json b/gkehub/v1/gkehub-api.json index 08716ba0d4e..17f3fa9a9ad 100644 --- a/gkehub/v1/gkehub-api.json +++ b/gkehub/v1/gkehub-api.json @@ -1911,7 +1911,7 @@ } } }, - "revision": "20240428", + "revision": "20240511", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AppDevExperienceFeatureSpec": { @@ -4325,6 +4325,13 @@ "nextPageToken": { "description": "A token to request the next page of resources from the `ListMembershipBindings` method. The value of an empty string means that there are no more resources to return.", "type": "string" + }, + "unreachable": { + "description": "List of locations that could not be reached while fetching this list.", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -5698,12 +5705,14 @@ "enum": [ "MODE_UNSPECIFIED", "DISABLED", - "BASIC" + "BASIC", + "ENTERPRISE" ], "enumDescriptions": [ "Default value not specified.", "Disables Security Posture features on the cluster.", - "Applies Security Posture features on the cluster." + "Applies Security Posture features on the cluster.", + "Applies the Security Posture off cluster Enterprise level features." ], "type": "string" }, diff --git a/gkehub/v1/gkehub-gen.go b/gkehub/v1/gkehub-gen.go index bab061b1202..74ba38f585e 100644 --- a/gkehub/v1/gkehub-gen.go +++ b/gkehub/v1/gkehub-gen.go @@ -3371,6 +3371,9 @@ type ListMembershipBindingsResponse struct { // `ListMembershipBindings` method. The value of an empty string means that // there are no more resources to return. NextPageToken string `json:"nextPageToken,omitempty"` + // Unreachable: List of locations that could not be reached while fetching this + // list. + Unreachable []string `json:"unreachable,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -5122,6 +5125,8 @@ type SecurityPostureConfig struct { // "MODE_UNSPECIFIED" - Default value not specified. // "DISABLED" - Disables Security Posture features on the cluster. // "BASIC" - Applies Security Posture features on the cluster. + // "ENTERPRISE" - Applies the Security Posture off cluster Enterprise level + // features. Mode string `json:"mode,omitempty"` // VulnerabilityMode: Sets which mode to use for vulnerability scanning. // diff --git a/gkehub/v1alpha/gkehub-api.json b/gkehub/v1alpha/gkehub-api.json index 462a9b65533..0a03ea6a6db 100644 --- a/gkehub/v1alpha/gkehub-api.json +++ b/gkehub/v1alpha/gkehub-api.json @@ -2175,7 +2175,7 @@ } } }, - "revision": "20240428", + "revision": "20240511", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AnthosObservabilityFeatureSpec": { @@ -4864,6 +4864,13 @@ "nextPageToken": { "description": "A token to request the next page of resources from the `ListMembershipBindings` method. The value of an empty string means that there are no more resources to return.", "type": "string" + }, + "unreachable": { + "description": "List of locations that could not be reached while fetching this list.", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -4882,6 +4889,13 @@ "$ref": "RBACRoleBinding" }, "type": "array" + }, + "unreachable": { + "description": "List of locations that could not be reached while fetching this list.", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -6380,12 +6394,14 @@ "enum": [ "MODE_UNSPECIFIED", "DISABLED", - "BASIC" + "BASIC", + "ENTERPRISE" ], "enumDescriptions": [ "Default value not specified.", "Disables Security Posture features on the cluster.", - "Applies Security Posture features on the cluster." + "Applies Security Posture features on the cluster.", + "Applies the Security Posture off cluster Enterprise level features." ], "type": "string" }, diff --git a/gkehub/v1alpha/gkehub-gen.go b/gkehub/v1alpha/gkehub-gen.go index 68e2020b57b..08c71056865 100644 --- a/gkehub/v1alpha/gkehub-gen.go +++ b/gkehub/v1alpha/gkehub-gen.go @@ -3751,6 +3751,9 @@ type ListMembershipBindingsResponse struct { // `ListMembershipBindings` method. The value of an empty string means that // there are no more resources to return. NextPageToken string `json:"nextPageToken,omitempty"` + // Unreachable: List of locations that could not be reached while fetching this + // list. + Unreachable []string `json:"unreachable,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -3780,6 +3783,9 @@ type ListMembershipRBACRoleBindingsResponse struct { NextPageToken string `json:"nextPageToken,omitempty"` // Rbacrolebindings: The list of Membership RBACRoleBindings. Rbacrolebindings []*RBACRoleBinding `json:"rbacrolebindings,omitempty"` + // Unreachable: List of locations that could not be reached while fetching this + // list. + Unreachable []string `json:"unreachable,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -5689,6 +5695,8 @@ type SecurityPostureConfig struct { // "MODE_UNSPECIFIED" - Default value not specified. // "DISABLED" - Disables Security Posture features on the cluster. // "BASIC" - Applies Security Posture features on the cluster. + // "ENTERPRISE" - Applies the Security Posture off cluster Enterprise level + // features. Mode string `json:"mode,omitempty"` // VulnerabilityMode: Sets which mode to use for vulnerability scanning. // diff --git a/gkehub/v1beta/gkehub-api.json b/gkehub/v1beta/gkehub-api.json index babcda1df17..e7b68efea10 100644 --- a/gkehub/v1beta/gkehub-api.json +++ b/gkehub/v1beta/gkehub-api.json @@ -2101,7 +2101,7 @@ } } }, - "revision": "20240428", + "revision": "20240511", "rootUrl": "https://gkehub.googleapis.com/", "schemas": { "AnthosObservabilityFeatureSpec": { @@ -4620,6 +4620,13 @@ "nextPageToken": { "description": "A token to request the next page of resources from the `ListMembershipBindings` method. The value of an empty string means that there are no more resources to return.", "type": "string" + }, + "unreachable": { + "description": "List of locations that could not be reached while fetching this list.", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -4638,6 +4645,13 @@ "$ref": "RBACRoleBinding" }, "type": "array" + }, + "unreachable": { + "description": "List of locations that could not be reached while fetching this list.", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -6080,12 +6094,14 @@ "enum": [ "MODE_UNSPECIFIED", "DISABLED", - "BASIC" + "BASIC", + "ENTERPRISE" ], "enumDescriptions": [ "Default value not specified.", "Disables Security Posture features on the cluster.", - "Applies Security Posture features on the cluster." + "Applies Security Posture features on the cluster.", + "Applies the Security Posture off cluster Enterprise level features." ], "type": "string" }, diff --git a/gkehub/v1beta/gkehub-gen.go b/gkehub/v1beta/gkehub-gen.go index fe9f817c54e..46567121995 100644 --- a/gkehub/v1beta/gkehub-gen.go +++ b/gkehub/v1beta/gkehub-gen.go @@ -3542,6 +3542,9 @@ type ListMembershipBindingsResponse struct { // `ListMembershipBindings` method. The value of an empty string means that // there are no more resources to return. NextPageToken string `json:"nextPageToken,omitempty"` + // Unreachable: List of locations that could not be reached while fetching this + // list. + Unreachable []string `json:"unreachable,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -3571,6 +3574,9 @@ type ListMembershipRBACRoleBindingsResponse struct { NextPageToken string `json:"nextPageToken,omitempty"` // Rbacrolebindings: The list of Membership RBACRoleBindings. Rbacrolebindings []*RBACRoleBinding `json:"rbacrolebindings,omitempty"` + // Unreachable: List of locations that could not be reached while fetching this + // list. + Unreachable []string `json:"unreachable,omitempty"` // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` @@ -5407,6 +5413,8 @@ type SecurityPostureConfig struct { // "MODE_UNSPECIFIED" - Default value not specified. // "DISABLED" - Disables Security Posture features on the cluster. // "BASIC" - Applies Security Posture features on the cluster. + // "ENTERPRISE" - Applies the Security Posture off cluster Enterprise level + // features. Mode string `json:"mode,omitempty"` // VulnerabilityMode: Sets which mode to use for vulnerability scanning. // diff --git a/metastore/v1/metastore-api.json b/metastore/v1/metastore-api.json index a61b65d397b..d1975cf3d43 100644 --- a/metastore/v1/metastore-api.json +++ b/metastore/v1/metastore-api.json @@ -1208,6 +1208,134 @@ } } }, + "databases": { + "methods": { + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/databases/{databasesId}:getIamPolicy", + "httpMethod": "GET", + "id": "metastore.projects.locations.services.databases.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy.Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected.Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset.The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/databases/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:getIamPolicy", + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/databases/{databasesId}:setIamPolicy", + "httpMethod": "POST", + "id": "metastore.projects.locations.services.databases.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/databases/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:setIamPolicy", + "request": { + "$ref": "SetIamPolicyRequest" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "tables": { + "methods": { + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/databases/{databasesId}/tables/{tablesId}:getIamPolicy", + "httpMethod": "GET", + "id": "metastore.projects.locations.services.databases.tables.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy.Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected.Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset.The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/databases/[^/]+/tables/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:getIamPolicy", + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/databases/{databasesId}/tables/{tablesId}:setIamPolicy", + "httpMethod": "POST", + "id": "metastore.projects.locations.services.databases.tables.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/databases/[^/]+/tables/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+resource}:setIamPolicy", + "request": { + "$ref": "SetIamPolicyRequest" + }, + "response": { + "$ref": "Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, "metadataImports": { "methods": { "create": { @@ -1367,7 +1495,7 @@ } } }, - "revision": "20240411", + "revision": "20240510", "rootUrl": "https://metastore.googleapis.com/", "schemas": { "AlterMetadataResourceLocationRequest": { @@ -1620,6 +1748,31 @@ }, "type": "object" }, + "CustomRegionMetadata": { + "description": "Metadata about a custom region. This is only populated if the region is a custom region. For single/multi regions, it will be empty.", + "id": "CustomRegionMetadata", + "properties": { + "optionalReadOnlyRegions": { + "description": "The read-only regions for this custom region.", + "items": { + "type": "string" + }, + "type": "array" + }, + "requiredReadWriteRegions": { + "description": "The read-write regions for this custom region.", + "items": { + "type": "string" + }, + "type": "array" + }, + "witnessRegion": { + "description": "The Spanner witness region for this custom region.", + "type": "string" + } + }, + "type": "object" + }, "DataCatalogConfig": { "description": "Specifies how metastore metadata should be integrated with the Data Catalog service.", "id": "DataCatalogConfig", @@ -2126,6 +2279,13 @@ "description": "Metadata about the service in a location.", "id": "LocationMetadata", "properties": { + "customRegionMetadata": { + "description": "Possible configurations supported if the current region is a custom region.", + "items": { + "$ref": "CustomRegionMetadata" + }, + "type": "array" + }, "multiRegionMetadata": { "$ref": "MultiRegionMetadata", "description": "The multi-region metadata if the current region is a multi-region." @@ -2350,7 +2510,7 @@ "type": "object" }, "MultiRegionMetadata": { - "description": "The metadata for the multi-region that includes the constituent regions. The metadata is only populated if the region is multi-region. For single region, it will be empty.", + "description": "The metadata for the multi-region that includes the constituent regions. The metadata is only populated if the region is multi-region. For single region or custom dual region, it will be empty.", "id": "MultiRegionMetadata", "properties": { "constituentRegions": { @@ -2715,6 +2875,10 @@ ], "type": "string" }, + "deletionProtection": { + "description": "Optional. Indicates if the dataproc metastore should be protected against accidental deletions.", + "type": "boolean" + }, "encryptionConfig": { "$ref": "EncryptionConfig", "description": "Immutable. Information used to configure the Dataproc Metastore service to encrypt customer data at rest. Cannot be updated." diff --git a/metastore/v1/metastore-gen.go b/metastore/v1/metastore-gen.go index d7f47fadb56..d7623eeb93f 100644 --- a/metastore/v1/metastore-gen.go +++ b/metastore/v1/metastore-gen.go @@ -205,6 +205,7 @@ type ProjectsLocationsOperationsService struct { func NewProjectsLocationsServicesService(s *APIService) *ProjectsLocationsServicesService { rs := &ProjectsLocationsServicesService{s: s} rs.Backups = NewProjectsLocationsServicesBackupsService(s) + rs.Databases = NewProjectsLocationsServicesDatabasesService(s) rs.MetadataImports = NewProjectsLocationsServicesMetadataImportsService(s) return rs } @@ -214,6 +215,8 @@ type ProjectsLocationsServicesService struct { Backups *ProjectsLocationsServicesBackupsService + Databases *ProjectsLocationsServicesDatabasesService + MetadataImports *ProjectsLocationsServicesMetadataImportsService } @@ -226,6 +229,27 @@ type ProjectsLocationsServicesBackupsService struct { s *APIService } +func NewProjectsLocationsServicesDatabasesService(s *APIService) *ProjectsLocationsServicesDatabasesService { + rs := &ProjectsLocationsServicesDatabasesService{s: s} + rs.Tables = NewProjectsLocationsServicesDatabasesTablesService(s) + return rs +} + +type ProjectsLocationsServicesDatabasesService struct { + s *APIService + + Tables *ProjectsLocationsServicesDatabasesTablesService +} + +func NewProjectsLocationsServicesDatabasesTablesService(s *APIService) *ProjectsLocationsServicesDatabasesTablesService { + rs := &ProjectsLocationsServicesDatabasesTablesService{s: s} + return rs +} + +type ProjectsLocationsServicesDatabasesTablesService struct { + s *APIService +} + func NewProjectsLocationsServicesMetadataImportsService(s *APIService) *ProjectsLocationsServicesMetadataImportsService { rs := &ProjectsLocationsServicesMetadataImportsService{s: s} return rs @@ -628,6 +652,34 @@ func (s *Consumer) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// CustomRegionMetadata: Metadata about a custom region. This is only populated +// if the region is a custom region. For single/multi regions, it will be +// empty. +type CustomRegionMetadata struct { + // OptionalReadOnlyRegions: The read-only regions for this custom region. + OptionalReadOnlyRegions []string `json:"optionalReadOnlyRegions,omitempty"` + // RequiredReadWriteRegions: The read-write regions for this custom region. + RequiredReadWriteRegions []string `json:"requiredReadWriteRegions,omitempty"` + // WitnessRegion: The Spanner witness region for this custom region. + WitnessRegion string `json:"witnessRegion,omitempty"` + // ForceSendFields is a list of field names (e.g. "OptionalReadOnlyRegions") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "OptionalReadOnlyRegions") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *CustomRegionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod CustomRegionMetadata + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // DataCatalogConfig: Specifies how metastore metadata should be integrated // with the Data Catalog service. type DataCatalogConfig struct { @@ -1267,6 +1319,9 @@ func (s *Location) MarshalJSON() ([]byte, error) { // LocationMetadata: Metadata about the service in a location. type LocationMetadata struct { + // CustomRegionMetadata: Possible configurations supported if the current + // region is a custom region. + CustomRegionMetadata []*CustomRegionMetadata `json:"customRegionMetadata,omitempty"` // MultiRegionMetadata: The multi-region metadata if the current region is a // multi-region. MultiRegionMetadata *MultiRegionMetadata `json:"multiRegionMetadata,omitempty"` @@ -1275,13 +1330,13 @@ type LocationMetadata struct { // guarantees that exactly one HiveMetastoreVersion in the list will set // is_default. SupportedHiveMetastoreVersions []*HiveMetastoreVersion `json:"supportedHiveMetastoreVersions,omitempty"` - // ForceSendFields is a list of field names (e.g. "MultiRegionMetadata") to + // ForceSendFields is a list of field names (e.g. "CustomRegionMetadata") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MultiRegionMetadata") to include + // NullFields is a list of field names (e.g. "CustomRegionMetadata") to include // in API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. @@ -1505,7 +1560,7 @@ type MoveTableToDatabaseResponse struct { // MultiRegionMetadata: The metadata for the multi-region that includes the // constituent regions. The metadata is only populated if the region is -// multi-region. For single region, it will be empty. +// multi-region. For single region or custom dual region, it will be empty. type MultiRegionMetadata struct { // ConstituentRegions: The regions constituting the multi-region. ConstituentRegions []string `json:"constituentRegions,omitempty"` @@ -2003,6 +2058,9 @@ type Service struct { // "MYSQL" - MySQL is used to persist the metastore data. // "SPANNER" - Spanner is used to persist the metastore data. DatabaseType string `json:"databaseType,omitempty"` + // DeletionProtection: Optional. Indicates if the dataproc metastore should be + // protected against accidental deletions. + DeletionProtection bool `json:"deletionProtection,omitempty"` // EncryptionConfig: Immutable. Information used to configure the Dataproc // Metastore service to encrypt customer data at rest. Cannot be updated. EncryptionConfig *EncryptionConfig `json:"encryptionConfig,omitempty"` @@ -6320,6 +6378,470 @@ func (c *ProjectsLocationsServicesBackupsSetIamPolicyCall) Do(opts ...googleapi. return ret, nil } +type ProjectsLocationsServicesDatabasesGetIamPolicyCall struct { + s *APIService + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns an +// empty policy if the resource exists and does not have a policy set. +// +// - resource: REQUIRED: The resource for which the policy is being requested. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsServicesDatabasesService) GetIamPolicy(resource string) *ProjectsLocationsServicesDatabasesGetIamPolicyCall { + c := &ProjectsLocationsServicesDatabasesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that will be +// used to format the policy.Valid values are 0, 1, and 3. Requests specifying +// an invalid value will be rejected.Requests for policies with any conditional +// role bindings must specify version 3. Policies with no conditional role +// bindings may specify any valid value or leave the field unset.The policy in +// the response might use the policy version that you specified, or it might +// use a lower policy version. For example, if you specify version 3, but the +// policy has no conditional role bindings, the response uses version 1.To +// learn which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsServicesDatabasesGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesDatabasesGetIamPolicyCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesGetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "metastore.projects.locations.services.databases.getIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsServicesDatabasesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsServicesDatabasesSetIamPolicyCall struct { + s *APIService + resource string + setiampolicyrequest *SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified resource. +// Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and +// PERMISSION_DENIED errors. +// +// - resource: REQUIRED: The resource for which the policy is being specified. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsServicesDatabasesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsServicesDatabasesSetIamPolicyCall { + c := &ProjectsLocationsServicesDatabasesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.setiampolicyrequest = setiampolicyrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesSetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "metastore.projects.locations.services.databases.setIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsServicesDatabasesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall struct { + s *APIService + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns an +// empty policy if the resource exists and does not have a policy set. +// +// - resource: REQUIRED: The resource for which the policy is being requested. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsServicesDatabasesTablesService) GetIamPolicy(resource string) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall { + c := &ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that will be +// used to format the policy.Valid values are 0, 1, and 3. Requests specifying +// an invalid value will be rejected.Requests for policies with any conditional +// role bindings must specify version 3. Policies with no conditional role +// bindings may specify any valid value or leave the field unset.The policy in +// the response might use the policy version that you specified, or it might +// use a lower policy version. For example, if you specify version 3, but the +// policy has no conditional role bindings, the response uses version 1.To +// learn which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "metastore.projects.locations.services.databases.tables.getIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsServicesDatabasesTablesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall struct { + s *APIService + resource string + setiampolicyrequest *SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified resource. +// Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and +// PERMISSION_DENIED errors. +// +// - resource: REQUIRED: The resource for which the policy is being specified. +// See Resource names (https://cloud.google.com/apis/design/resource_names) +// for the appropriate value for this field. +func (r *ProjectsLocationsServicesDatabasesTablesService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall { + c := &ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.setiampolicyrequest = setiampolicyrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "metastore.projects.locations.services.databases.tables.setIamPolicy" call. +// Any non-2xx status code is an error. Response headers are in either +// *Policy.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsServicesDatabasesTablesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + type ProjectsLocationsServicesMetadataImportsCreateCall struct { s *APIService parent string diff --git a/metastore/v1alpha/metastore-api.json b/metastore/v1alpha/metastore-api.json index 6ecef6ecda1..ba1a5112a98 100644 --- a/metastore/v1alpha/metastore-api.json +++ b/metastore/v1alpha/metastore-api.json @@ -1796,7 +1796,7 @@ } } }, - "revision": "20240411", + "revision": "20240510", "rootUrl": "https://metastore.googleapis.com/", "schemas": { "AlterMetadataResourceLocationRequest": { @@ -2196,6 +2196,31 @@ }, "type": "object" }, + "CustomRegionMetadata": { + "description": "Metadata about a custom region. This is only populated if the region is a custom region. For single/multi regions, it will be empty.", + "id": "CustomRegionMetadata", + "properties": { + "optionalReadOnlyRegions": { + "description": "The read-only regions for this custom region.", + "items": { + "type": "string" + }, + "type": "array" + }, + "requiredReadWriteRegions": { + "description": "The read-write regions for this custom region.", + "items": { + "type": "string" + }, + "type": "array" + }, + "witnessRegion": { + "description": "The Spanner witness region for this custom region.", + "type": "string" + } + }, + "type": "object" + }, "DataCatalogConfig": { "description": "Specifies how metastore metadata should be integrated with the Data Catalog service.", "id": "DataCatalogConfig", @@ -2769,6 +2794,13 @@ "description": "Metadata about the service in a location.", "id": "LocationMetadata", "properties": { + "customRegionMetadata": { + "description": "Possible configurations supported if the current region is a custom region.", + "items": { + "$ref": "CustomRegionMetadata" + }, + "type": "array" + }, "multiRegionMetadata": { "$ref": "MultiRegionMetadata", "description": "The multi-region metadata if the current region is a multi-region." @@ -3072,7 +3104,7 @@ "type": "object" }, "MultiRegionMetadata": { - "description": "The metadata for the multi-region that includes the constituent regions. The metadata is only populated if the region is multi-region. For single region, it will be empty.", + "description": "The metadata for the multi-region that includes the constituent regions. The metadata is only populated if the region is multi-region. For single region or custom dual region, it will be empty.", "id": "MultiRegionMetadata", "properties": { "constituentRegions": { @@ -3467,6 +3499,10 @@ ], "type": "string" }, + "deletionProtection": { + "description": "Optional. Indicates if the dataproc metastore should be protected against accidental deletions.", + "type": "boolean" + }, "encryptionConfig": { "$ref": "EncryptionConfig", "description": "Immutable. Information used to configure the Dataproc Metastore service to encrypt customer data at rest. Cannot be updated." diff --git a/metastore/v1alpha/metastore-gen.go b/metastore/v1alpha/metastore-gen.go index cdf3853b38b..00f4f9b0912 100644 --- a/metastore/v1alpha/metastore-gen.go +++ b/metastore/v1alpha/metastore-gen.go @@ -907,6 +907,34 @@ func (s *Consumer) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// CustomRegionMetadata: Metadata about a custom region. This is only populated +// if the region is a custom region. For single/multi regions, it will be +// empty. +type CustomRegionMetadata struct { + // OptionalReadOnlyRegions: The read-only regions for this custom region. + OptionalReadOnlyRegions []string `json:"optionalReadOnlyRegions,omitempty"` + // RequiredReadWriteRegions: The read-write regions for this custom region. + RequiredReadWriteRegions []string `json:"requiredReadWriteRegions,omitempty"` + // WitnessRegion: The Spanner witness region for this custom region. + WitnessRegion string `json:"witnessRegion,omitempty"` + // ForceSendFields is a list of field names (e.g. "OptionalReadOnlyRegions") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "OptionalReadOnlyRegions") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *CustomRegionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod CustomRegionMetadata + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // DataCatalogConfig: Specifies how metastore metadata should be integrated // with the Data Catalog service. type DataCatalogConfig struct { @@ -1668,6 +1696,9 @@ func (s *Location) MarshalJSON() ([]byte, error) { // LocationMetadata: Metadata about the service in a location. type LocationMetadata struct { + // CustomRegionMetadata: Possible configurations supported if the current + // region is a custom region. + CustomRegionMetadata []*CustomRegionMetadata `json:"customRegionMetadata,omitempty"` // MultiRegionMetadata: The multi-region metadata if the current region is a // multi-region. MultiRegionMetadata *MultiRegionMetadata `json:"multiRegionMetadata,omitempty"` @@ -1676,13 +1707,13 @@ type LocationMetadata struct { // guarantees that exactly one HiveMetastoreVersion in the list will set // is_default. SupportedHiveMetastoreVersions []*HiveMetastoreVersion `json:"supportedHiveMetastoreVersions,omitempty"` - // ForceSendFields is a list of field names (e.g. "MultiRegionMetadata") to + // ForceSendFields is a list of field names (e.g. "CustomRegionMetadata") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MultiRegionMetadata") to include + // NullFields is a list of field names (e.g. "CustomRegionMetadata") to include // in API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. @@ -1974,7 +2005,7 @@ type MoveTableToDatabaseResponse struct { // MultiRegionMetadata: The metadata for the multi-region that includes the // constituent regions. The metadata is only populated if the region is -// multi-region. For single region, it will be empty. +// multi-region. For single region or custom dual region, it will be empty. type MultiRegionMetadata struct { // ConstituentRegions: The regions constituting the multi-region. ConstituentRegions []string `json:"constituentRegions,omitempty"` @@ -2527,6 +2558,9 @@ type Service struct { // "MYSQL" - MySQL is used to persist the metastore data. // "SPANNER" - Spanner is used to persist the metastore data. DatabaseType string `json:"databaseType,omitempty"` + // DeletionProtection: Optional. Indicates if the dataproc metastore should be + // protected against accidental deletions. + DeletionProtection bool `json:"deletionProtection,omitempty"` // EncryptionConfig: Immutable. Information used to configure the Dataproc // Metastore service to encrypt customer data at rest. Cannot be updated. EncryptionConfig *EncryptionConfig `json:"encryptionConfig,omitempty"` diff --git a/metastore/v1beta/metastore-api.json b/metastore/v1beta/metastore-api.json index cc99027938a..9f1a71d2c7c 100644 --- a/metastore/v1beta/metastore-api.json +++ b/metastore/v1beta/metastore-api.json @@ -1796,7 +1796,7 @@ } } }, - "revision": "20240411", + "revision": "20240510", "rootUrl": "https://metastore.googleapis.com/", "schemas": { "AlterMetadataResourceLocationRequest": { @@ -2196,6 +2196,31 @@ }, "type": "object" }, + "CustomRegionMetadata": { + "description": "Metadata about a custom region. This is only populated if the region is a custom region. For single/multi regions, it will be empty.", + "id": "CustomRegionMetadata", + "properties": { + "optionalReadOnlyRegions": { + "description": "The read-only regions for this custom region.", + "items": { + "type": "string" + }, + "type": "array" + }, + "requiredReadWriteRegions": { + "description": "The read-write regions for this custom region.", + "items": { + "type": "string" + }, + "type": "array" + }, + "witnessRegion": { + "description": "The Spanner witness region for this custom region.", + "type": "string" + } + }, + "type": "object" + }, "DataCatalogConfig": { "description": "Specifies how metastore metadata should be integrated with the Data Catalog service.", "id": "DataCatalogConfig", @@ -2769,6 +2794,13 @@ "description": "Metadata about the service in a location.", "id": "LocationMetadata", "properties": { + "customRegionMetadata": { + "description": "Possible configurations supported if the current region is a custom region.", + "items": { + "$ref": "CustomRegionMetadata" + }, + "type": "array" + }, "multiRegionMetadata": { "$ref": "MultiRegionMetadata", "description": "The multi-region metadata if the current region is a multi-region." @@ -3072,7 +3104,7 @@ "type": "object" }, "MultiRegionMetadata": { - "description": "The metadata for the multi-region that includes the constituent regions. The metadata is only populated if the region is multi-region. For single region, it will be empty.", + "description": "The metadata for the multi-region that includes the constituent regions. The metadata is only populated if the region is multi-region. For single region or custom dual region, it will be empty.", "id": "MultiRegionMetadata", "properties": { "constituentRegions": { @@ -3467,6 +3499,10 @@ ], "type": "string" }, + "deletionProtection": { + "description": "Optional. Indicates if the dataproc metastore should be protected against accidental deletions.", + "type": "boolean" + }, "encryptionConfig": { "$ref": "EncryptionConfig", "description": "Immutable. Information used to configure the Dataproc Metastore service to encrypt customer data at rest. Cannot be updated." diff --git a/metastore/v1beta/metastore-gen.go b/metastore/v1beta/metastore-gen.go index b9d9f946d74..2fb45db2513 100644 --- a/metastore/v1beta/metastore-gen.go +++ b/metastore/v1beta/metastore-gen.go @@ -907,6 +907,34 @@ func (s *Consumer) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// CustomRegionMetadata: Metadata about a custom region. This is only populated +// if the region is a custom region. For single/multi regions, it will be +// empty. +type CustomRegionMetadata struct { + // OptionalReadOnlyRegions: The read-only regions for this custom region. + OptionalReadOnlyRegions []string `json:"optionalReadOnlyRegions,omitempty"` + // RequiredReadWriteRegions: The read-write regions for this custom region. + RequiredReadWriteRegions []string `json:"requiredReadWriteRegions,omitempty"` + // WitnessRegion: The Spanner witness region for this custom region. + WitnessRegion string `json:"witnessRegion,omitempty"` + // ForceSendFields is a list of field names (e.g. "OptionalReadOnlyRegions") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "OptionalReadOnlyRegions") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *CustomRegionMetadata) MarshalJSON() ([]byte, error) { + type NoMethod CustomRegionMetadata + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // DataCatalogConfig: Specifies how metastore metadata should be integrated // with the Data Catalog service. type DataCatalogConfig struct { @@ -1668,6 +1696,9 @@ func (s *Location) MarshalJSON() ([]byte, error) { // LocationMetadata: Metadata about the service in a location. type LocationMetadata struct { + // CustomRegionMetadata: Possible configurations supported if the current + // region is a custom region. + CustomRegionMetadata []*CustomRegionMetadata `json:"customRegionMetadata,omitempty"` // MultiRegionMetadata: The multi-region metadata if the current region is a // multi-region. MultiRegionMetadata *MultiRegionMetadata `json:"multiRegionMetadata,omitempty"` @@ -1676,13 +1707,13 @@ type LocationMetadata struct { // guarantees that exactly one HiveMetastoreVersion in the list will set // is_default. SupportedHiveMetastoreVersions []*HiveMetastoreVersion `json:"supportedHiveMetastoreVersions,omitempty"` - // ForceSendFields is a list of field names (e.g. "MultiRegionMetadata") to + // ForceSendFields is a list of field names (e.g. "CustomRegionMetadata") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MultiRegionMetadata") to include + // NullFields is a list of field names (e.g. "CustomRegionMetadata") to include // in API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. @@ -1974,7 +2005,7 @@ type MoveTableToDatabaseResponse struct { // MultiRegionMetadata: The metadata for the multi-region that includes the // constituent regions. The metadata is only populated if the region is -// multi-region. For single region, it will be empty. +// multi-region. For single region or custom dual region, it will be empty. type MultiRegionMetadata struct { // ConstituentRegions: The regions constituting the multi-region. ConstituentRegions []string `json:"constituentRegions,omitempty"` @@ -2527,6 +2558,9 @@ type Service struct { // "MYSQL" - MySQL is used to persist the metastore data. // "SPANNER" - Spanner is used to persist the metastore data. DatabaseType string `json:"databaseType,omitempty"` + // DeletionProtection: Optional. Indicates if the dataproc metastore should be + // protected against accidental deletions. + DeletionProtection bool `json:"deletionProtection,omitempty"` // EncryptionConfig: Immutable. Information used to configure the Dataproc // Metastore service to encrypt customer data at rest. Cannot be updated. EncryptionConfig *EncryptionConfig `json:"encryptionConfig,omitempty"` diff --git a/workflows/v1/workflows-api.json b/workflows/v1/workflows-api.json index 119d107e739..624996227e3 100644 --- a/workflows/v1/workflows-api.json +++ b/workflows/v1/workflows-api.json @@ -485,7 +485,7 @@ } } }, - "revision": "20240110", + "revision": "20240508", "rootUrl": "https://workflows.googleapis.com/", "schemas": { "Empty": { @@ -725,6 +725,22 @@ "description": "Workflow program to be executed by Workflows.", "id": "Workflow", "properties": { + "allKmsKeys": { + "description": "Output only. A list of all KMS crypto keys used to encrypt or decrpt the data associated with the workflow.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "allKmsKeysVersions": { + "description": "Output only. A list of all KMS crypto keys versions used to encrypt or decrpt the data associated with the workflow.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, "callLogLevel": { "description": "Optional. Describes the level of platform logging to apply to calls and call responses during executions of this workflow. If both the workflow and the execution specify a logging level, the execution level takes precedence.", "enum": [ @@ -751,6 +767,11 @@ "description": "Optional. The resource name of a KMS crypto key used to encrypt or decrypt the data associated with the workflow. Format: projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey} Using `-` as a wildcard for the `{project}` or not providing one at all will infer the project from the account. If not provided, data associated with the workflow will not be CMEK-encrypted.", "type": "string" }, + "cryptoKeyVersion": { + "description": "Output only. The resource name of a KMS crypto key version used to encrypt or decrypt the data associated with the workflow. Format: projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{cryptoKey}/cryptoKeyVersions/{cryptoKeyVersion}", + "readOnly": true, + "type": "string" + }, "description": { "description": "Description of the workflow provided by the user. Must be at most 1000 Unicode characters long. This is a workflow-wide field and is not tied to a specific revision.", "type": "string" diff --git a/workflows/v1/workflows-gen.go b/workflows/v1/workflows-gen.go index c861a0e7bd3..17a208b562d 100644 --- a/workflows/v1/workflows-gen.go +++ b/workflows/v1/workflows-gen.go @@ -503,6 +503,12 @@ func (s *Status) MarshalJSON() ([]byte, error) { // Workflow: Workflow program to be executed by Workflows. type Workflow struct { + // AllKmsKeys: Output only. A list of all KMS crypto keys used to encrypt or + // decrpt the data associated with the workflow. + AllKmsKeys []string `json:"allKmsKeys,omitempty"` + // AllKmsKeysVersions: Output only. A list of all KMS crypto keys versions used + // to encrypt or decrpt the data associated with the workflow. + AllKmsKeysVersions []string `json:"allKmsKeysVersions,omitempty"` // CallLogLevel: Optional. Describes the level of platform logging to apply to // calls and call responses during executions of this workflow. If both the // workflow and the execution specify a logging level, the execution level @@ -526,6 +532,11 @@ type Workflow struct { // will infer the project from the account. If not provided, data associated // with the workflow will not be CMEK-encrypted. CryptoKeyName string `json:"cryptoKeyName,omitempty"` + // CryptoKeyVersion: Output only. The resource name of a KMS crypto key version + // used to encrypt or decrypt the data associated with the workflow. Format: + // projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{crypto + // Key}/cryptoKeyVersions/{cryptoKeyVersion} + CryptoKeyVersion string `json:"cryptoKeyVersion,omitempty"` // Description: Description of the workflow provided by the user. Must be at // most 1000 Unicode characters long. This is a workflow-wide field and is not // tied to a specific revision. @@ -585,13 +596,13 @@ type Workflow struct { // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CallLogLevel") to + // ForceSendFields is a list of field names (e.g. "AllKmsKeys") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CallLogLevel") to include in API + // NullFields is a list of field names (e.g. "AllKmsKeys") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.