Skip to content

Commit

Permalink
feat: added federation API (#3681)
Browse files Browse the repository at this point in the history
* feat: added federation API
feat: added EncryptionConfig field
feat: added NetworkConfig field
feat: added DatabaseType field
feat: added TelemetryConfiguration field

PiperOrigin-RevId: 490636886

Source-Link: googleapis/googleapis@791374c

Source-Link: googleapis/googleapis-gen@7a72bd9
Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLW1ldGFzdG9yZS8uT3dsQm90LnlhbWwiLCJoIjoiN2E3MmJkOWNjYTA3ZmJlMDQyYWMwMjNmZmI1ZmQ1OTQxNDJkNzk1ZCJ9

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: sofisl <[email protected]>
  • Loading branch information
3 people authored Nov 30, 2022
1 parent c8bc63b commit 6b2c4d1
Show file tree
Hide file tree
Showing 77 changed files with 64,272 additions and 24,322 deletions.
15 changes: 15 additions & 0 deletions packages/google-cloud-metastore/README.md

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2021 Google LLC
// Copyright 2022 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -30,10 +30,15 @@ option go_package = "google.golang.org/genproto/googleapis/cloud/metastore/v1;me
option java_multiple_files = true;
option java_outer_classname = "MetastoreProto";
option java_package = "com.google.cloud.metastore.v1";
option php_namespace = "Google\\Cloud\\Metastore\\V1";
option (google.api.resource_definition) = {
type: "compute.googleapis.com/Network"
pattern: "projects/{project}/global/networks/{network}"
};
option (google.api.resource_definition) = {
type: "compute.googleapis.com/Subnetwork"
pattern: "projects/{project}/regions/{region}/subnetworks/{subnetwork}"
};

// Configures and manages metastore services.
// Metastore services are fully managed, highly available, autoscaled,
Expand Down Expand Up @@ -81,7 +86,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "parent,service,service_id";
option (google.longrunning.operation_info) = {
response_type: "Service"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand All @@ -94,7 +99,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "service,update_mask";
option (google.longrunning.operation_info) = {
response_type: "Service"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand All @@ -106,7 +111,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "name";
option (google.longrunning.operation_info) = {
response_type: "google.protobuf.Empty"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand Down Expand Up @@ -135,7 +140,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "parent,metadata_import,metadata_import_id";
option (google.longrunning.operation_info) = {
response_type: "MetadataImport"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand All @@ -149,7 +154,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "metadata_import,update_mask";
option (google.longrunning.operation_info) = {
response_type: "MetadataImport"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand All @@ -161,7 +166,7 @@ service DataprocMetastore {
};
option (google.longrunning.operation_info) = {
response_type: "MetadataExport"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand All @@ -174,7 +179,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "service,backup";
option (google.longrunning.operation_info) = {
response_type: "Restore"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand Down Expand Up @@ -203,7 +208,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "parent,backup,backup_id";
option (google.longrunning.operation_info) = {
response_type: "Backup"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}

Expand All @@ -215,7 +220,7 @@ service DataprocMetastore {
option (google.api.method_signature) = "name";
option (google.longrunning.operation_info) = {
response_type: "google.protobuf.Empty"
metadata_type: "OperationMetadata"
metadata_type: "google.cloud.metastore.v1.OperationMetadata"
};
}
}
Expand Down Expand Up @@ -288,6 +293,18 @@ message Service {
STABLE = 2;
}

// The backend database type for the metastore service.
enum DatabaseType {
// The DATABASE_TYPE is not set.
DATABASE_TYPE_UNSPECIFIED = 0;

// MySQL is used to persist the metastore data.
MYSQL = 1;

// Spanner is used to persist the metastore data.
SPANNER = 2;
}

// Configuration properties specific to the underlying metastore service
// technology (the software that serves metastore queries).
oneof metastore_config {
Expand All @@ -296,7 +313,8 @@ message Service {
HiveMetastoreConfig hive_metastore_config = 5;
}

// Immutable. The relative resource name of the metastore service, of the form:
// Immutable. The relative resource name of the metastore service, in the following
// format:
//
// `projects/{project_number}/locations/{location_id}/services/{service_id}`.
string name = 1 [(google.api.field_behavior) = IMMUTABLE];
Expand Down Expand Up @@ -343,6 +361,8 @@ message Service {

// The one hour maintenance window of the metastore service. This specifies
// when the service can be restarted for maintenance purposes in UTC time.
// Maintenance window is not needed for services with the SPANNER
// database type.
MaintenanceWindow maintenance_window = 15;

// Output only. The globally unique resource identifier of the metastore service.
Expand All @@ -354,6 +374,21 @@ message Service {
// Immutable. The release channel of the service.
// If unspecified, defaults to `STABLE`.
ReleaseChannel release_channel = 19 [(google.api.field_behavior) = IMMUTABLE];

// Immutable. Information used to configure the Dataproc Metastore service to encrypt
// customer data at rest. Cannot be updated.
EncryptionConfig encryption_config = 20 [(google.api.field_behavior) = IMMUTABLE];

// The configuration specifying the network settings for the
// Dataproc Metastore service.
NetworkConfig network_config = 21;

// Immutable. The database type that the Metastore service stores its data.
DatabaseType database_type = 22 [(google.api.field_behavior) = IMMUTABLE];

// The configuration specifying telemetry settings for the Dataproc Metastore
// service. If unspecified defaults to `JSON`.
TelemetryConfig telemetry_config = 23;
}

// Maintenance window. This specifies when Dataproc Metastore
Expand All @@ -374,7 +409,9 @@ message HiveMetastoreConfig {

// A mapping of Hive metastore configuration key-value pairs to apply to the
// Hive metastore (configured in `hive-site.xml`). The mappings
// override system defaults (some keys cannot be overridden).
// override system defaults (some keys cannot be overridden). These
// overrides are also applied to auxiliary versions and can be further
// customized in the auxiliary version's `AuxiliaryVersionConfig`.
map<string, string> config_overrides = 2;

// Information used to configure the Hive metastore service as a service
Expand Down Expand Up @@ -413,6 +450,62 @@ message Secret {
}
}

// Encryption settings for the service.
message EncryptionConfig {
// The fully qualified customer provided Cloud KMS key name to use for
// customer data encryption, in the following form:
//
// `projects/{project_number}/locations/{location_id}/keyRings/{key_ring_id}/cryptoKeys/{crypto_key_id}`.
string kms_key = 1;
}

// Network configuration for the Dataproc Metastore service.
message NetworkConfig {
// Contains information of the customer's network configurations.
message Consumer {
oneof vpc_resource {
// Immutable. The subnetwork of the customer project from which an IP address is
// reserved and used as the Dataproc Metastore service's
// endpoint. It is accessible to hosts in the subnet and to all
// hosts in a subnet in the same region and same network. There must
// be at least one IP address available in the subnet's primary range. The
// subnet is specified in the following form:
//
// `projects/{project_number}/regions/{region_id}/subnetworks/{subnetwork_id}
string subnetwork = 1 [
(google.api.field_behavior) = IMMUTABLE,
(google.api.resource_reference) = {
type: "compute.googleapis.com/Subnetwork"
}
];
}

// Output only. The URI of the endpoint used to access the metastore service.
string endpoint_uri = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
}

// Immutable. The consumer-side network configuration for the Dataproc Metastore
// instance.
repeated Consumer consumers = 1 [(google.api.field_behavior) = IMMUTABLE];
}

// Telemetry Configuration for the Dataproc Metastore service.
message TelemetryConfig {
enum LogFormat {
// The LOG_FORMAT is not set.
LOG_FORMAT_UNSPECIFIED = 0;

// Logging output uses the legacy `textPayload` format.
LEGACY = 1;

// Logging output uses the `jsonPayload` format.
JSON = 2;
}

// The output format of the Dataproc Metastore service's logs.
LogFormat log_format = 1;
}

// The metadata management activities of the metastore service.
message MetadataManagementActivity {
// Output only. The latest metadata exports of the metastore service.
Expand All @@ -432,6 +525,7 @@ message MetadataImport {
// A specification of the location of and metadata about a database dump from
// a relational database management system.
message DatabaseDump {

// The type of the database.
enum DatabaseType {
// The type of the source database is unknown.
Expand Down Expand Up @@ -659,7 +753,7 @@ message ListServicesRequest {
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "locations.googleapis.com/Location"
child_type: "metastore.googleapis.com/Service"
}
];

Expand Down Expand Up @@ -723,7 +817,7 @@ message CreateServiceRequest {
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "locations.googleapis.com/Location"
child_type: "metastore.googleapis.com/Service"
}
];

Expand Down Expand Up @@ -822,7 +916,7 @@ message ListMetadataImportsRequest {
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "metastore.googleapis.com/Service"
child_type: "metastore.googleapis.com/MetadataImport"
}
];

Expand Down Expand Up @@ -886,7 +980,7 @@ message CreateMetadataImportRequest {
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "metastore.googleapis.com/Service"
child_type: "metastore.googleapis.com/MetadataImport"
}
];

Expand Down Expand Up @@ -957,7 +1051,7 @@ message ListBackupsRequest {
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "metastore.googleapis.com/Service"
child_type: "metastore.googleapis.com/Backup"
}
];

Expand Down Expand Up @@ -1021,7 +1115,7 @@ message CreateBackupRequest {
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "metastore.googleapis.com/Service"
child_type: "metastore.googleapis.com/Backup"
}
];

Expand Down Expand Up @@ -1219,6 +1313,4 @@ message DatabaseDumpSpec {
// Database dump contains Avro files.
AVRO = 2;
}


}
Loading

0 comments on commit 6b2c4d1

Please sign in to comment.