Synchronize new proto/yaml changes.
PiperOrigin-RevId: 252106627
This commit is contained in:
parent
9bf6151830
commit
0264cd17c8
|
|
@ -8,16 +8,33 @@ apis:
|
|||
|
||||
documentation:
|
||||
summary: |-
|
||||
Google Cloud Data Catalog API provides features to attach metadata to
|
||||
Google Cloud Platform resources like BigQuery Tables.<br> Key critical
|
||||
resources include:
|
||||
<ul>
|
||||
<li>Entries (Data Catalog representation of a cloud resource)</li>
|
||||
A fully managed and highly scalable data discovery and metadata management
|
||||
service.
|
||||
overview: |-
|
||||
DataCatalog is a centralized and unified data catalog service for all your
|
||||
Cloud resources, where users and systems can discover data, explore and
|
||||
curate its semantics, understand how to act on it, and help govern its
|
||||
usage.
|
||||
rules:
|
||||
- selector: google.iam.v1.IAMPolicy.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.
|
||||
|
||||
- selector: google.iam.v1.IAMPolicy.SetIamPolicy
|
||||
description: |-
|
||||
Sets the access control policy on the specified resource. Replaces
|
||||
any existing policy.
|
||||
|
||||
- selector: google.iam.v1.IAMPolicy.TestIamPermissions
|
||||
description: |-
|
||||
Returns permissions that a caller has on the specified resource. If the
|
||||
resource does not exist, this will return an empty set of
|
||||
permissions, not a NOT_FOUND error.
|
||||
|
||||
Note: This operation is designed to be used for building
|
||||
permission-aware UIs and command-line tools, not for authorization
|
||||
checking. This operation may "fail open" without warning.
|
||||
|
||||
authentication:
|
||||
rules:
|
||||
|
|
@ -25,3 +42,7 @@ authentication:
|
|||
oauth:
|
||||
canonical_scopes: |-
|
||||
https://www.googleapis.com/auth/cloud-platform
|
||||
- selector: 'google.iam.v1.IAMPolicy.*'
|
||||
oauth:
|
||||
canonical_scopes: |-
|
||||
https://www.googleapis.com/auth/cloud-platform
|
||||
|
|
|
|||
|
|
@ -19,32 +19,331 @@ package google.cloud.datacatalog.v1beta1;
|
|||
|
||||
import "google/api/annotations.proto";
|
||||
import "google/cloud/datacatalog/v1beta1/schema.proto";
|
||||
import "google/cloud/datacatalog/v1beta1/search.proto";
|
||||
import "google/cloud/datacatalog/v1beta1/table_spec.proto";
|
||||
import "google/cloud/datacatalog/v1beta1/tags.proto";
|
||||
import "google/cloud/datacatalog/v1beta1/timestamps.proto";
|
||||
import "google/iam/v1/iam_policy.proto";
|
||||
import "google/iam/v1/policy.proto";
|
||||
import "google/protobuf/empty.proto";
|
||||
import "google/protobuf/field_mask.proto";
|
||||
import "google/api/client.proto";
|
||||
|
||||
option cc_enable_arenas = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/cloud/datacatalog/v1beta1;datacatalog";
|
||||
option java_multiple_files = true;
|
||||
option java_package = "com.google.cloud.datacatalog";
|
||||
|
||||
// Cloud Data Catalog is a service that allows clients to discover,
|
||||
// manage, and understand their Google Cloud data resources.
|
||||
// Data Catalog API service allows clients to discover, understand, and manage
|
||||
// their data.
|
||||
service DataCatalog {
|
||||
option (google.api.default_host) = "datacatalog.googleapis.com";
|
||||
option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform";
|
||||
|
||||
// Searches Data Catalog for multiple resources like entries, tags that
|
||||
// match a query.
|
||||
//
|
||||
// This is a custom method
|
||||
// (https://cloud.google.com/apis/design/custom_methods) and does not return
|
||||
// the complete resource, only the resource identifier and high level
|
||||
// fields. Clients can subsequentally call Get methods.
|
||||
//
|
||||
// See [Data Catalog Search
|
||||
// Syntax](/data-catalog/docs/how-to/search-reference)
|
||||
rpc SearchCatalog(SearchCatalogRequest) returns (SearchCatalogResponse) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/catalog:search"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
// Updates an existing entry.
|
||||
rpc UpdateEntry(UpdateEntryRequest) returns (Entry) {
|
||||
option (google.api.http) = {
|
||||
patch: "/v1beta1/{entry.name=projects/*/locations/*/entryGroups/*/entries/*}"
|
||||
body: "entry"
|
||||
};
|
||||
}
|
||||
|
||||
// Gets an entry.
|
||||
rpc GetEntry(GetEntryRequest) returns (Entry) {
|
||||
option (google.api.http) = {
|
||||
get: "/v1beta1/{name=projects/*/locations/*/entryGroups/*/entries/*}"
|
||||
};
|
||||
}
|
||||
|
||||
// Get an entry by target resource name. This method allows clients to use
|
||||
// the resource name from the source Google Cloud Platform service to get the
|
||||
// Cloud Data Catalog Entry.
|
||||
// Data Catalog Entry.
|
||||
rpc LookupEntry(LookupEntryRequest) returns (Entry) {
|
||||
option (google.api.http) = {
|
||||
get: "/v1beta1/entries:lookup"
|
||||
};
|
||||
}
|
||||
|
||||
// Creates a tag template.
|
||||
rpc CreateTagTemplate(CreateTagTemplateRequest) returns (TagTemplate) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/{parent=projects/*/locations/*}/tagTemplates"
|
||||
body: "tag_template"
|
||||
};
|
||||
}
|
||||
|
||||
// Gets a tag template.
|
||||
rpc GetTagTemplate(GetTagTemplateRequest) returns (TagTemplate) {
|
||||
option (google.api.http) = {
|
||||
get: "/v1beta1/{name=projects/*/locations/*/tagTemplates/*}"
|
||||
};
|
||||
}
|
||||
|
||||
// Updates a tag template. This method cannot be used to update the fields of
|
||||
// a template. The tag template fields are represented as separate resources
|
||||
// and should be updated using their own create/update/delete methods.
|
||||
rpc UpdateTagTemplate(UpdateTagTemplateRequest) returns (TagTemplate) {
|
||||
option (google.api.http) = {
|
||||
patch: "/v1beta1/{tag_template.name=projects/*/locations/*/tagTemplates/*}"
|
||||
body: "tag_template"
|
||||
};
|
||||
}
|
||||
|
||||
// Deletes a tag template and all tags using the template.
|
||||
rpc DeleteTagTemplate(DeleteTagTemplateRequest) returns (google.protobuf.Empty) {
|
||||
option (google.api.http) = {
|
||||
delete: "/v1beta1/{name=projects/*/locations/*/tagTemplates/*}"
|
||||
};
|
||||
}
|
||||
|
||||
// Creates a field in a tag template.
|
||||
rpc CreateTagTemplateField(CreateTagTemplateFieldRequest) returns (TagTemplateField) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/{parent=projects/*/locations/*/tagTemplates/*}/fields"
|
||||
body: "tag_template_field"
|
||||
};
|
||||
}
|
||||
|
||||
// Updates a field in a tag template. This method cannot be used to update the
|
||||
// field type.
|
||||
rpc UpdateTagTemplateField(UpdateTagTemplateFieldRequest) returns (TagTemplateField) {
|
||||
option (google.api.http) = {
|
||||
patch: "/v1beta1/{name=projects/*/locations/*/tagTemplates/*/fields/*}"
|
||||
body: "tag_template_field"
|
||||
};
|
||||
}
|
||||
|
||||
// Renames a field in a tag template.
|
||||
rpc RenameTagTemplateField(RenameTagTemplateFieldRequest) returns (TagTemplateField) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/{name=projects/*/locations/*/tagTemplates/*/fields/*}:rename"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
// Deletes a field in a tag template and all uses of that field.
|
||||
rpc DeleteTagTemplateField(DeleteTagTemplateFieldRequest) returns (google.protobuf.Empty) {
|
||||
option (google.api.http) = {
|
||||
delete: "/v1beta1/{name=projects/*/locations/*/tagTemplates/*/fields/*}"
|
||||
};
|
||||
}
|
||||
|
||||
// Creates a tag on an [Entry][google.cloud.datacatalog.v1beta1.Entry].
|
||||
rpc CreateTag(CreateTagRequest) returns (Tag) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/{parent=projects/*/locations/*/entryGroups/*/entries/*}/tags"
|
||||
body: "tag"
|
||||
};
|
||||
}
|
||||
|
||||
// Updates an existing tag.
|
||||
rpc UpdateTag(UpdateTagRequest) returns (Tag) {
|
||||
option (google.api.http) = {
|
||||
patch: "/v1beta1/{tag.name=projects/*/locations/*/entryGroups/*/entries/*/tags/*}"
|
||||
body: "tag"
|
||||
};
|
||||
}
|
||||
|
||||
// Deletes a tag.
|
||||
rpc DeleteTag(DeleteTagRequest) returns (google.protobuf.Empty) {
|
||||
option (google.api.http) = {
|
||||
delete: "/v1beta1/{name=projects/*/locations/*/entryGroups/*/entries/*/tags/*}"
|
||||
};
|
||||
}
|
||||
|
||||
// Lists the tags on an [Entry][google.cloud.datacatalog.v1beta1.Entry].
|
||||
rpc ListTags(ListTagsRequest) returns (ListTagsResponse) {
|
||||
option (google.api.http) = {
|
||||
get: "/v1beta1/{parent=projects/*/locations/*/entryGroups/*/entries/*}/tags"
|
||||
};
|
||||
}
|
||||
|
||||
// Sets the access control policy for a resource. Replaces any existing
|
||||
// policy.
|
||||
// Supported resources are:
|
||||
// - Tag templates.
|
||||
// Note, this method cannot be used to manage policies for BigQuery, Cloud
|
||||
// Pub/Sub and any external Google Cloud Platform resources synced to Cloud
|
||||
// Data Catalog.
|
||||
//
|
||||
// Callers must have following Google IAM permission
|
||||
// `datacatalog.tagTemplates.setIamPolicy` to set policies on tag templates.
|
||||
rpc SetIamPolicy(google.iam.v1.SetIamPolicyRequest) returns (google.iam.v1.Policy) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/{resource=projects/*/locations/*/tagTemplates/*}:setIamPolicy"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
// Gets the access control policy for a resource. A `NOT_FOUND` error
|
||||
// is returned if the resource does not exist. An empty policy is returned
|
||||
// if the resource exists but does not have a policy set on it.
|
||||
//
|
||||
// Supported resources are:
|
||||
// - Tag templates.
|
||||
// Note, this method cannot be used to manage policies for BigQuery, Cloud
|
||||
// Pub/Sub and any external Google Cloud Platform resources synced to Cloud
|
||||
// Data Catalog.
|
||||
//
|
||||
// Callers must have following Google IAM permission
|
||||
// `datacatalog.tagTemplates.getIamPolicy` to get policies on tag templates.
|
||||
rpc GetIamPolicy(google.iam.v1.GetIamPolicyRequest) returns (google.iam.v1.Policy) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/{resource=projects/*/locations/*/tagTemplates/*}:getIamPolicy"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
// Returns the caller's permissions on a resource.
|
||||
// If the resource does not exist, an empty set of permissions is returned
|
||||
// (We don't return a `NOT_FOUND` error).
|
||||
//
|
||||
// Supported resource are:
|
||||
// - tag templates.
|
||||
// Note, this method cannot be used to manage policies for BigQuery, Cloud
|
||||
// Pub/Sub and any external Google Cloud Platform resources synced to Cloud
|
||||
// Data Catalog.
|
||||
//
|
||||
// A caller is not required to have Google IAM permission to make this
|
||||
// request.
|
||||
rpc TestIamPermissions(google.iam.v1.TestIamPermissionsRequest) returns (google.iam.v1.TestIamPermissionsResponse) {
|
||||
option (google.api.http) = {
|
||||
post: "/v1beta1/{resource=projects/*/locations/*/tagTemplates/*}:testIamPermissions"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [SearchCatalog][google.cloud.datacatalog.v1beta1.DataCatalog.SearchCatalog].
|
||||
message SearchCatalogRequest {
|
||||
message Scope {
|
||||
// Data Catalog tries to automatically choose the right corpus of data to
|
||||
// search through. You can ensure an organization is included by adding it
|
||||
// to "include_org_ids". You can ensure a project's org is included with
|
||||
// "include_project_ids". You must specify at least one organization
|
||||
// using "include_org_ids" or "include_project_ids" in all search requests.
|
||||
//
|
||||
// List of organization IDs to search within. To find your organization ID,
|
||||
// follow instructions in
|
||||
// https://cloud.google.com/resource-manager/docs/creating-managing-organization
|
||||
repeated string include_org_ids = 2;
|
||||
|
||||
// List of project IDs to search within. To learn more about the
|
||||
// distinction between project names/IDs/numbers, go to
|
||||
// https://cloud.google.com/docs/overview/#projects
|
||||
repeated string include_project_ids = 3;
|
||||
|
||||
// If true, include Google Cloud Platform (GCP) public datasets in the
|
||||
// search results. Info on GCP public datasets is available at
|
||||
// https://cloud.google.com/public-datasets/. By default, GCP public
|
||||
// datasets are excluded.
|
||||
bool include_gcp_public_datasets = 7;
|
||||
}
|
||||
|
||||
// Required. The scope of this search request.
|
||||
Scope scope = 6;
|
||||
|
||||
// Required. The query string in search query syntax. The query must be
|
||||
// non-empty.
|
||||
//
|
||||
// Query strings can be simple as "x" or more qualified as:
|
||||
//
|
||||
// * name:x
|
||||
// * column:x
|
||||
// * description:y
|
||||
//
|
||||
// Note: Query tokens need to have a minimum of 3 characters for substring
|
||||
// matching to work correctly. See [Data Catalog Search
|
||||
// Syntax](/data-catalog/docs/how-to/search-reference) for more information.
|
||||
string query = 1;
|
||||
|
||||
// Number of results in the search page. If <=0 then defaults to 10. Max limit
|
||||
// for page_size is 1000. Throws an invalid argument for page_size > 1000.
|
||||
int32 page_size = 2;
|
||||
|
||||
// Optional pagination token returned in an earlier
|
||||
// [SearchCatalogResponse.next_page_token][google.cloud.datacatalog.v1beta1.DataCatalog.SearchCatalogResponse.next_page_token];
|
||||
// indicates that this is a continuation of a prior
|
||||
// [SearchCatalog][google.cloud.datacatalog.v1beta1.DataCatalog.SearchCatalog]
|
||||
// call, and that the system should return the next page of data. If empty
|
||||
// then the first page is returned.
|
||||
string page_token = 3;
|
||||
|
||||
// Specifies the ordering of results, currently supported case-sensitive
|
||||
// choices are:
|
||||
// <ul>
|
||||
// <li> relevance </li>
|
||||
// <li> last_access_timestamp [asc|desc], defaults to descending if not
|
||||
// specified, </li>
|
||||
// <li> last_modified_timestamp [asc|desc], defaults to descending if not
|
||||
// specified, </li>
|
||||
// <li> title [asc|desc], defaults to ascending if not specified. </li>
|
||||
// </ul>
|
||||
string order_by = 5;
|
||||
}
|
||||
|
||||
// Response message for
|
||||
// [SearchCatalog][google.cloud.datacatalog.v1beta1.DataCatalog.SearchCatalog].
|
||||
message SearchCatalogResponse {
|
||||
// Search results in descending order of relevance.
|
||||
repeated SearchCatalogResult results = 1;
|
||||
|
||||
// The token that can be used to retrieve the next page of results.
|
||||
string next_page_token = 3;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [UpdateEntry][google.cloud.datacatalog.v1beta1.DataCatalog.UpdateEntry].
|
||||
message UpdateEntryRequest {
|
||||
// Required. The updated Entry.
|
||||
Entry entry = 1;
|
||||
|
||||
// Optional. The fields to update on the entry. If absent or empty, all
|
||||
// modifiable fields are updated.
|
||||
//
|
||||
// Modifiable fields in synced entries:
|
||||
//
|
||||
// 1. schema (Pub/Sub topics only)
|
||||
//
|
||||
// Modifiable fields in native entries:
|
||||
//
|
||||
// 1. display_name
|
||||
// 2. description
|
||||
// 3. schema
|
||||
google.protobuf.FieldMask update_mask = 2;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [GetEntry][google.cloud.datacatalog.v1beta1.DataCatalog.GetEntry].
|
||||
message GetEntryRequest {
|
||||
// Required. The name of the entry. For example,
|
||||
// "projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}/entries/{entry_id}".
|
||||
string name = 1;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [LookupEntry][google.cloud.datacatalog.v1beta1.DataCatalog.LookupEntry].
|
||||
message LookupEntryRequest {
|
||||
// Represents either the Google Cloud Platform resource or SQL name for a
|
||||
// Google Cloud Platform resource.
|
||||
// Required. Represents either the Google Cloud Platform resource or SQL name
|
||||
// for a Google Cloud Platform resource.
|
||||
oneof target_name {
|
||||
// The full name of the Google Cloud Platform resource the Data Catalog
|
||||
// entry represents. See:
|
||||
|
|
@ -59,9 +358,14 @@ message LookupEntryRequest {
|
|||
// The SQL name of the entry. SQL names are case-sensitive.
|
||||
//
|
||||
// Examples:
|
||||
// 1. cloud_pubsub.project_id.topic_id
|
||||
// 2. bigquery.project_id.dataset_id.table_id
|
||||
// 3. datacatalog.project_id.location_id.entry_group_id.entry_id
|
||||
// <ul>
|
||||
// <li>cloud_pubsub.project_id.topic_id</li>
|
||||
// <li>pubsub.project_id.`topic.id.with.dots`</li>
|
||||
// <li>bigquery.project_id.dataset_id.table_id</li>
|
||||
// <li>datacatalog.project_id.location_id.entry_group_id.entry_id</li>
|
||||
// </ul>
|
||||
// *_ids shoud satisfy the standard SQL rules for identifiers.
|
||||
// https://cloud.google.com/bigquery/docs/reference/standard-sql/lexical
|
||||
string sql_resource = 3;
|
||||
}
|
||||
}
|
||||
|
|
@ -72,14 +376,17 @@ message LookupEntryRequest {
|
|||
// use the `linked_resource` field in the Entry resource to refer to the
|
||||
// original resource id of the source system.
|
||||
//
|
||||
// An Entry resource contains resource details, such as its schema.
|
||||
// An Entry resource contains resource details, such as its schema. An Entry can
|
||||
// also be used to attach flexible metadata, such as a
|
||||
// [Tag][google.cloud.datacatalog.v1beta1.Tag].
|
||||
message Entry {
|
||||
// Output only. The Data Catalog resource name of the entry in URL format. For
|
||||
// example,
|
||||
// Required when used in
|
||||
// [UpdateEntryRequest][google.cloud.datacatalog.v1beta1.UpdateEntryRequest].
|
||||
// The Data Catalog resource name of the entry in URL format. For example,
|
||||
// "projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}/entries/{entry_id}".
|
||||
string name = 1;
|
||||
|
||||
// The full name of the cloud resource the entry belongs to. See:
|
||||
// Output only. The full name of the cloud resource the entry belongs to. See:
|
||||
// https://cloud.google.com/apis/design/resource_names#full_resource_name
|
||||
//
|
||||
// Data Catalog supports resources from select Google Cloud Platform systems.
|
||||
|
|
@ -89,41 +396,227 @@ message Entry {
|
|||
// "//bigquery.googleapis.com/projects/projectId/datasets/datasetId/tables/tableId".
|
||||
string linked_resource = 9;
|
||||
|
||||
// Type of entry.
|
||||
// Required. Type of entry.
|
||||
EntryType type = 2;
|
||||
|
||||
// Type specification information.
|
||||
// Optional. Type specification information.
|
||||
oneof type_spec {
|
||||
// Specification that applies to a BigQuery table. This is only valid on
|
||||
// entries of type TABLE.
|
||||
BigQueryTableSpec bigquery_table_spec = 12;
|
||||
|
||||
// Specification for a group of BigQuery tables with name pattern
|
||||
// [prefix]YYYYMMDD. Context:
|
||||
// https://cloud.google.com/bigquery/docs/partitioned-tables#partitioning_versus_sharding
|
||||
BigQueryDateShardedSpec bigquery_date_sharded_spec = 15;
|
||||
}
|
||||
|
||||
// Display information such as title and description.
|
||||
// A short name to identify the entry, for example,
|
||||
// "Analytics Data - Jan 2011".
|
||||
// Optional. Display information such as title and description. A short name
|
||||
// to identify the entry, for example, "Analytics Data - Jan 2011". Default
|
||||
// value is an empty string.
|
||||
string display_name = 3;
|
||||
|
||||
// Entry description, which can consist of several sentences or paragraphs
|
||||
// that describe entry contents.
|
||||
// Optional. Entry description, which can consist of several sentences or
|
||||
// paragraphs that describe entry contents. Default value is an empty string.
|
||||
string description = 4;
|
||||
|
||||
// Schema of the entry.
|
||||
// Optional. Schema of the entry. An entry might not have any schema attached
|
||||
// to it.
|
||||
Schema schema = 5;
|
||||
|
||||
// Timestamps about the underlying Google Cloud Platform resource -- not about
|
||||
// this Data Catalog Entry.
|
||||
// Output only. Timestamps about the underlying Google Cloud Platform resource
|
||||
// -- not about this Data Catalog Entry.
|
||||
SystemTimestamps source_system_timestamps = 7;
|
||||
}
|
||||
|
||||
// Entry resources in Cloud Data Catalog can be of different types e.g. BigQuery
|
||||
// Request message for
|
||||
// [CreateTagTemplate][google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagTemplate].
|
||||
message CreateTagTemplateRequest {
|
||||
// Required. The name of the project and the location this template is in.
|
||||
// Example: "projects/{project_id}/locations/{location}".
|
||||
string parent = 1;
|
||||
|
||||
// Required. The id of the tag template to create.
|
||||
string tag_template_id = 3;
|
||||
|
||||
// Required. The tag template to create.
|
||||
TagTemplate tag_template = 2;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [GetTagTemplate][google.cloud.datacatalog.v1beta1.DataCatalog.GetTagTemplate].
|
||||
message GetTagTemplateRequest {
|
||||
// Required. The name of the tag template. For example,
|
||||
// "projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}".
|
||||
string name = 1;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [UpdateTagTemplate][google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagTemplate].
|
||||
message UpdateTagTemplateRequest {
|
||||
// Required. The template to update.
|
||||
TagTemplate tag_template = 1;
|
||||
|
||||
// Optional. The field mask specifies the parts of the template to overwrite.
|
||||
//
|
||||
// Allowed fields:
|
||||
//
|
||||
// * display_name
|
||||
//
|
||||
// If update_mask is omitted, all of the allowed fields above will be updated.
|
||||
google.protobuf.FieldMask update_mask = 2;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [DeleteTagTemplate][google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagTemplate].
|
||||
message DeleteTagTemplateRequest {
|
||||
// Required. The name of the tag template to delete. For example,
|
||||
// "projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}".
|
||||
string name = 1;
|
||||
|
||||
// Required. Currently, this field must always be set to <code>true</code>.
|
||||
// This confirms the deletion of any possible tags using this template.
|
||||
// <code>force = false</code> will be supported in the future.
|
||||
bool force = 2;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [CreateTag][google.cloud.datacatalog.v1beta1.DataCatalog.CreateTag].
|
||||
message CreateTagRequest {
|
||||
// Required.
|
||||
// The name of the resource to attach this tag to. Tags can be attached to
|
||||
// Entries. (example:
|
||||
// "projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}/entries/{entry_id}").
|
||||
string parent = 1;
|
||||
|
||||
// Required. The tag to create.
|
||||
Tag tag = 2;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [UpdateTag][google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTag].
|
||||
message UpdateTagRequest {
|
||||
// Required. The updated tag.
|
||||
Tag tag = 1;
|
||||
|
||||
// Optional. The fields to update on the Tag. If absent or empty, all
|
||||
// modifiable fields are updated. Currently the only modifiable field is the
|
||||
// field `fields`.
|
||||
google.protobuf.FieldMask update_mask = 2;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [DeleteTag][google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTag].
|
||||
message DeleteTagRequest {
|
||||
// Required. The name of the tag to delete. For example,
|
||||
// "projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}/entries/{entry_id}/tags/{tag_id}".
|
||||
string name = 1;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [CreateTagTemplateField][google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagTemplateField].
|
||||
message CreateTagTemplateFieldRequest {
|
||||
// Required. The name of the project this template is in. Example:
|
||||
// "projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}".
|
||||
string parent = 1;
|
||||
|
||||
// Required. The id of the tag template field to create.
|
||||
// Field ids can contain letters (both uppercase and lowercase), numbers
|
||||
// (0-9), underscores (_) and dashes (-). Field ids must be at least 1
|
||||
// character long and at most 128 characters long. Field ids must also be
|
||||
// unique to their template.
|
||||
string tag_template_field_id = 2;
|
||||
|
||||
// Required. The tag template field to create.
|
||||
TagTemplateField tag_template_field = 3;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [UpdateTagTemplateField][google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagTemplateField].
|
||||
message UpdateTagTemplateFieldRequest {
|
||||
// Required. The name of the tag template field. For example,
|
||||
// "projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}/fields/{tag_template_field_id}".
|
||||
string name = 1;
|
||||
|
||||
// Required. The template to update.
|
||||
TagTemplateField tag_template_field = 2;
|
||||
|
||||
// Optional. The field mask specifies the parts of the template to overwrite.
|
||||
// Allowed fields:
|
||||
//
|
||||
// * display_name
|
||||
// * type.enum_type
|
||||
//
|
||||
// If update_mask is omitted, all of the allowed fields above will be updated.
|
||||
//
|
||||
// When updating an enum type, the provided values will be merged with the
|
||||
// existing values. Therefore, enum values can only be added, existing enum
|
||||
// values cannot be deleted nor renamed.
|
||||
google.protobuf.FieldMask update_mask = 3;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [RenameTagTemplateField][google.cloud.datacatalog.v1beta1.DataCatalog.RenameTagTemplateField].
|
||||
message RenameTagTemplateFieldRequest {
|
||||
// Required. The name of the tag template. For example,
|
||||
// "projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}/fields/{tag_template_field_id}".
|
||||
string name = 1;
|
||||
|
||||
// Required. The new ID of this tag template field. For example,
|
||||
// "my_new_field".
|
||||
string new_tag_template_field_id = 2;
|
||||
}
|
||||
|
||||
// Entry resources in Data Catalog can be of different types e.g. BigQuery
|
||||
// Table entry is of type 'TABLE'. This enum describes all the possible types
|
||||
// Cloud Data Catalog contains.
|
||||
// Data Catalog contains.
|
||||
enum EntryType {
|
||||
// Default unknown type
|
||||
ENTRY_TYPE_UNSPECIFIED = 0;
|
||||
|
||||
// The type of entry that has a GoogleSQL schema, including logical views.
|
||||
TABLE = 2;
|
||||
|
||||
// An entry type which is used for streaming entries. Example - Pub/Sub.
|
||||
DATA_STREAM = 3;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [DeleteTagTemplateField][google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagTemplateField].
|
||||
message DeleteTagTemplateFieldRequest {
|
||||
// Required. The name of the tag template field to delete. For example,
|
||||
// "projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}/fields/{tag_template_field_id}".
|
||||
string name = 1;
|
||||
|
||||
// Required. Currently, this field must always be set to <code>true</code>.
|
||||
// This confirms the deletion of this field from any tags using this field.
|
||||
// <code>force = false</code> will be supported in the future.
|
||||
bool force = 2;
|
||||
}
|
||||
|
||||
// Request message for
|
||||
// [ListTags][google.cloud.datacatalog.v1beta1.DataCatalog.ListTags].
|
||||
message ListTagsRequest {
|
||||
// Required. The name of the Data Catalog resource to list the tags of. The
|
||||
// resource could be an [Entry][google.cloud.datacatalog.v1beta1.Entry].
|
||||
string parent = 1;
|
||||
|
||||
// Optional. The maximum number of tags to return. Default is 10. Max limit is
|
||||
// 1000.
|
||||
int32 page_size = 2;
|
||||
|
||||
// Optional. Token that specifies which page is requested. If empty, the first
|
||||
// page is returned.
|
||||
string page_token = 3;
|
||||
}
|
||||
|
||||
// Response message for
|
||||
// [ListTags][google.cloud.datacatalog.v1beta1.DataCatalog.ListTags].
|
||||
message ListTagsResponse {
|
||||
// [Tag][google.cloud.datacatalog.v1beta1.Tag] details.
|
||||
repeated Tag tags = 1;
|
||||
|
||||
// Token to retrieve the next page of results. It is set to empty if no items
|
||||
// remain in results.
|
||||
string next_page_token = 2;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,6 +16,8 @@ language_settings:
|
|||
package_name: Google\Cloud\Datacatalog\V1beta1
|
||||
nodejs:
|
||||
package_name: datacatalog.v1beta1
|
||||
domain_layer_location: google-cloud
|
||||
|
||||
# A list of API interface configurations.
|
||||
interfaces:
|
||||
# The fully qualified name of the API interface.
|
||||
|
|
@ -35,6 +37,12 @@ interfaces:
|
|||
entity_name: location
|
||||
- name_pattern: projects/{project}/locations/{location}/entryGroups/{entry_group}/entries/{entry}
|
||||
entity_name: entry
|
||||
- name_pattern: projects/{project}/locations/{location}/entryGroups/{entry_group}/entries/{entry}/tags/{tag}
|
||||
entity_name: tag
|
||||
- name_pattern: projects/{project}/locations/{location}/tagTemplates/{tag_template}
|
||||
entity_name: tag_template
|
||||
- name_pattern: projects/{project}/locations/{location}/tagTemplates/{tag_template}/fields/{field}
|
||||
entity_name: field
|
||||
# Definition for retryable codes.
|
||||
retry_codes_def:
|
||||
- name: idempotent
|
||||
|
|
@ -99,7 +107,264 @@ interfaces:
|
|||
# timeout_millis - Specifies the default timeout for a non-retrying call. If
|
||||
# the call is retrying, refer to retry_params_name instead.
|
||||
methods:
|
||||
- name: SearchCatalog
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- scope
|
||||
- query
|
||||
- order_by
|
||||
required_fields:
|
||||
- scope
|
||||
- query
|
||||
page_streaming:
|
||||
request:
|
||||
page_size_field: page_size
|
||||
token_field: page_token
|
||||
response:
|
||||
token_field: next_page_token
|
||||
resources_field: results
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
timeout_millis: 60000
|
||||
- name: UpdateEntry
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- entry
|
||||
- update_mask
|
||||
required_fields:
|
||||
- entry
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
entry.name: entry
|
||||
timeout_millis: 60000
|
||||
- name: GetEntry
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- name
|
||||
required_fields:
|
||||
- name
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
name: entry
|
||||
timeout_millis: 60000
|
||||
- name: LookupEntry
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: default
|
||||
timeout_millis: 60000
|
||||
- name: CreateTagTemplate
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- parent
|
||||
- tag_template_id
|
||||
- tag_template
|
||||
required_fields:
|
||||
- parent
|
||||
- tag_template_id
|
||||
- tag_template
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
parent: location
|
||||
timeout_millis: 60000
|
||||
- name: GetTagTemplate
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- name
|
||||
required_fields:
|
||||
- name
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
name: tag_template
|
||||
timeout_millis: 60000
|
||||
- name: UpdateTagTemplate
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- tag_template
|
||||
- update_mask
|
||||
required_fields:
|
||||
- tag_template
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
tag_template.name: tag_template
|
||||
timeout_millis: 60000
|
||||
- name: DeleteTagTemplate
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- name
|
||||
- force
|
||||
required_fields:
|
||||
- name
|
||||
- force
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
name: tag_template
|
||||
timeout_millis: 60000
|
||||
- name: CreateTagTemplateField
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- parent
|
||||
- tag_template_field_id
|
||||
- tag_template_field
|
||||
required_fields:
|
||||
- parent
|
||||
- tag_template_field_id
|
||||
- tag_template_field
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
parent: tag_template
|
||||
timeout_millis: 60000
|
||||
- name: UpdateTagTemplateField
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- name
|
||||
- tag_template_field
|
||||
- update_mask
|
||||
required_fields:
|
||||
- name
|
||||
- tag_template_field
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
name: field
|
||||
timeout_millis: 60000
|
||||
- name: RenameTagTemplateField
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- name
|
||||
- new_tag_template_field_id
|
||||
required_fields:
|
||||
- name
|
||||
- new_tag_template_field_id
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
name: field
|
||||
timeout_millis: 60000
|
||||
- name: DeleteTagTemplateField
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- name
|
||||
- force
|
||||
required_fields:
|
||||
- name
|
||||
- force
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
name: field
|
||||
timeout_millis: 60000
|
||||
- name: CreateTag
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- parent
|
||||
- tag
|
||||
required_fields:
|
||||
- parent
|
||||
- tag
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
parent: entry
|
||||
timeout_millis: 60000
|
||||
- name: UpdateTag
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- tag
|
||||
- update_mask
|
||||
required_fields:
|
||||
- tag
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
tag.name: tag
|
||||
timeout_millis: 60000
|
||||
- name: DeleteTag
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- name
|
||||
required_fields:
|
||||
- name
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
name: tag
|
||||
timeout_millis: 60000
|
||||
- name: ListTags
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- parent
|
||||
required_fields:
|
||||
- parent
|
||||
page_streaming:
|
||||
request:
|
||||
page_size_field: page_size
|
||||
token_field: page_token
|
||||
response:
|
||||
token_field: next_page_token
|
||||
resources_field: tags
|
||||
retry_codes_name: idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
parent: entry
|
||||
timeout_millis: 60000
|
||||
- name: SetIamPolicy
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- resource
|
||||
- policy
|
||||
required_fields:
|
||||
- resource
|
||||
- policy
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
resource: tag_template
|
||||
timeout_millis: 60000
|
||||
- name: GetIamPolicy
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- resource
|
||||
required_fields:
|
||||
- resource
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
resource: tag_template
|
||||
timeout_millis: 60000
|
||||
- name: TestIamPermissions
|
||||
flattening:
|
||||
groups:
|
||||
- parameters:
|
||||
- resource
|
||||
- permissions
|
||||
required_fields:
|
||||
- resource
|
||||
- permissions
|
||||
retry_codes_name: non_idempotent
|
||||
retry_params_name: default
|
||||
field_name_patterns:
|
||||
resource: tag_template
|
||||
timeout_millis: 60000
|
||||
|
|
|
|||
|
|
@ -24,8 +24,8 @@ option java_package = "com.google.cloud.datacatalog";
|
|||
|
||||
// Represents a schema (e.g. BigQuery, GoogleSQL, Avro schema).
|
||||
message Schema {
|
||||
// Schema of columns. A maximum of 10,000 columns and sub-columns can be
|
||||
// specified.
|
||||
// Required. Schema of columns. A maximum of 10,000 columns and sub-columns
|
||||
// can be specified.
|
||||
repeated ColumnSchema columns = 2;
|
||||
}
|
||||
|
||||
|
|
@ -38,14 +38,15 @@ message ColumnSchema {
|
|||
// Required. Type of the column.
|
||||
string type = 1;
|
||||
|
||||
// Description of the column.
|
||||
// Optional. Description of the column. Default value is an empty string.
|
||||
string description = 2;
|
||||
|
||||
// A column's mode indicates whether the values in this column are
|
||||
// Optional. A column's mode indicates whether the values in this column are
|
||||
// required, nullable, etc. Only 'NULLABLE', 'REQUIRED' and 'REPEATED' are
|
||||
// supported, default mode is 'NULLABLE'.
|
||||
// supported. Default mode is 'NULLABLE'.
|
||||
string mode = 3;
|
||||
|
||||
// Schema of sub-columns.
|
||||
// Optional. Schema of sub-columns. A column can have zero or more
|
||||
// sub-columns.
|
||||
repeated ColumnSchema subcolumns = 7;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,67 @@
|
|||
// Copyright 2019 Google LLC.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package google.cloud.datacatalog.v1beta1;
|
||||
|
||||
import "google/api/annotations.proto";
|
||||
import "google/protobuf/timestamp.proto";
|
||||
|
||||
option cc_enable_arenas = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/cloud/datacatalog/v1beta1;datacatalog";
|
||||
option java_multiple_files = true;
|
||||
option java_package = "com.google.cloud.datacatalog";
|
||||
|
||||
// A result that appears in the response of a search request. Each result
|
||||
// captures details of one entry that matches the search.
|
||||
message SearchCatalogResult {
|
||||
// Type of the search result. This field can be used to determine which Get
|
||||
// method to call to fetch the full resource.
|
||||
SearchResultType search_result_type = 1;
|
||||
|
||||
// Sub-type of the search result. This is a dot-delimited description of the
|
||||
// resource's full type, and is the same as the value callers would provide in
|
||||
// the "type" search facet. Examples: "entry.table", "entry.dataStream",
|
||||
// "tagTemplate"
|
||||
string search_result_subtype = 2;
|
||||
|
||||
// The relative resource name of the resource in URL format.
|
||||
// Examples:
|
||||
// "projects/{project_id}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}".
|
||||
// "projects/{project_id}/tagTemplates/{tag_template_id}".
|
||||
string relative_resource_name = 3;
|
||||
|
||||
// The full name of the cloud resource the entry belongs to. See:
|
||||
// https://cloud.google.com/apis/design/resource_names#full_resource_name
|
||||
// Example:
|
||||
// "//bigquery.googleapis.com/projects/projectId/datasets/datasetId/tables/tableId".
|
||||
string linked_resource = 4;
|
||||
}
|
||||
|
||||
// The different types of resources that can be returned in search.
|
||||
enum SearchResultType {
|
||||
// Default unknown type.
|
||||
SEARCH_RESULT_TYPE_UNSPECIFIED = 0;
|
||||
|
||||
// An [Entry][google.cloud.datacatalog.v1beta1.Entry].
|
||||
ENTRY = 1;
|
||||
|
||||
// A [TagTemplate][google.cloud.datacatalog.v1beta1.TagTemplate].
|
||||
TAG_TEMPLATE = 2;
|
||||
|
||||
// An [EntryGroup][google.cloud.datacatalog.v1beta1.EntryGroup].
|
||||
ENTRY_GROUP = 3;
|
||||
}
|
||||
|
|
@ -24,12 +24,19 @@ option java_package = "com.google.cloud.datacatalog";
|
|||
|
||||
// Describes a BigQuery table.
|
||||
message BigQueryTableSpec {
|
||||
// The table source type.
|
||||
// Output only. The table source type.
|
||||
TableSourceType table_source_type = 1;
|
||||
|
||||
// Table view specification. This field should only be populated if
|
||||
// table_source_type is BIGQUERY_VIEW.
|
||||
ViewSpec view_spec = 2;
|
||||
// Output only.
|
||||
oneof type_spec {
|
||||
// Table view specification. This field should only be populated if
|
||||
// table_source_type is BIGQUERY_VIEW.
|
||||
ViewSpec view_spec = 2;
|
||||
|
||||
// Spec of a BigQuery table. This field should only be populated if
|
||||
// table_source_type is BIGQUERY_TABLE.
|
||||
TableSpec table_spec = 3;
|
||||
}
|
||||
}
|
||||
|
||||
// Table source type.
|
||||
|
|
@ -46,6 +53,36 @@ enum TableSourceType {
|
|||
|
||||
// Table view specification.
|
||||
message ViewSpec {
|
||||
// The query that defines the table view.
|
||||
// Output only. The query that defines the table view.
|
||||
string view_query = 1;
|
||||
}
|
||||
|
||||
// Normal BigQuery table spec.
|
||||
message TableSpec {
|
||||
// Output only. If the table is a dated shard, i.e. with name pattern
|
||||
// [prefix]YYYYMMDD, grouped_entry is the Data Catalog resource name of the
|
||||
// date sharded grouped entry, e.g.
|
||||
// projects/{project_id}/locations/{location}/entrygroups/{entry_group_id}
|
||||
// /entries/{entry_id}.
|
||||
// Otherwise, grouped_entry will be empty.
|
||||
string grouped_entry = 1;
|
||||
}
|
||||
|
||||
// Spec for a group of BigQuery tables with name pattern [prefix]YYYYMMDD.
|
||||
// Context:
|
||||
// https://cloud.google.com/bigquery/docs/partitioned-tables#partitioning_versus_sharding
|
||||
message BigQueryDateShardedSpec {
|
||||
// Output only. The Data Catalog resource name of the dataset entry the
|
||||
// current table belongs to, e.g.
|
||||
// projects/{project_id}/locations/{location}/entrygroups/{entry_group_id}
|
||||
// /entries/{entry_id}
|
||||
string dataset = 1;
|
||||
|
||||
// Output only. The table name prefix of the shards. The name of any given
|
||||
// shard is [table_prefix]YYYYMMDD, e.g. for shard MyTable20180101, the
|
||||
// table_prefix is "MyTable"
|
||||
string table_prefix = 2;
|
||||
|
||||
// Output only. Total number of shards.
|
||||
int64 shard_count = 3;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,174 @@
|
|||
// Copyright 2019 Google LLC.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package google.cloud.datacatalog.v1beta1;
|
||||
|
||||
import "google/protobuf/timestamp.proto";
|
||||
|
||||
option cc_enable_arenas = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/cloud/datacatalog/v1beta1;datacatalog";
|
||||
option java_multiple_files = true;
|
||||
option java_package = "com.google.cloud.datacatalog";
|
||||
|
||||
// Tags are used to attach custom metadata to Data Catalog resources. Tags
|
||||
// conform to the specifications within their tag template.
|
||||
message Tag {
|
||||
// Required when used in
|
||||
// [UpdateTagRequest][google.cloud.datacatalog.v1beta1.UpdateTagRequest]. The
|
||||
// resource name of the tag in URL format. For example,
|
||||
// projects/{project_id}/locations/{location}/entrygroups/{entry_group_id}/entries/{entry_id}/tags/{tag_id}",
|
||||
// where tag_id is a system-generated identifier.
|
||||
string name = 1;
|
||||
|
||||
// Required. The resource name of the tag template that this tag uses. For
|
||||
// example,
|
||||
// projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}.
|
||||
// This field cannot be modified after creation.
|
||||
string template = 2;
|
||||
|
||||
// Output only. The display name of the tag template.
|
||||
string template_display_name = 5;
|
||||
|
||||
// Optional. The scope within the parent resource that this tag is attached
|
||||
// to. If not provided, the tag is attached to the parent resource itself.
|
||||
// Deleting the scope from the parent resource will delete all tags attached
|
||||
// to that scope. These fields cannot be updated after creation.
|
||||
oneof scope {
|
||||
// Resources like Entry can have schemas associated with them. This scope
|
||||
// allows users to attach tags to an individual column based on that schema.
|
||||
//
|
||||
// For attaching a tag to a nested column, use '.' to separate the column
|
||||
// names: "outer_column.inner_column".
|
||||
string column = 4;
|
||||
}
|
||||
|
||||
// Required. This maps the id of a tag field to the value of & additional
|
||||
// information about that field. Valid field IDs are defined by the tag's
|
||||
// template. A tag must have at least 1 field and at most 500 fields.
|
||||
map<string, TagField> fields = 3;
|
||||
}
|
||||
|
||||
// Contains the value and supporting information for a field within
|
||||
// a [Tag][google.cloud.datacatalog.v1beta1.Tag].
|
||||
message TagField {
|
||||
// Holds an enum value.
|
||||
message EnumValue {
|
||||
// The display name of the enum value.
|
||||
string display_name = 1;
|
||||
}
|
||||
|
||||
// Output only. The display name of this field.
|
||||
string display_name = 1;
|
||||
|
||||
// Required. The value of this field.
|
||||
oneof kind {
|
||||
// Holds the value for a tag field with double type.
|
||||
double double_value = 2;
|
||||
|
||||
// Holds the value for a tag field with string type.
|
||||
string string_value = 3;
|
||||
|
||||
// Holds the value for a tag field with boolean type.
|
||||
bool bool_value = 4;
|
||||
|
||||
// Holds the value for a tag field with timestamp type.
|
||||
google.protobuf.Timestamp timestamp_value = 5;
|
||||
|
||||
// Holds the value for a tag field with enum type. This value must be
|
||||
// one of the allowed values in the definition of this enum.
|
||||
EnumValue enum_value = 6;
|
||||
}
|
||||
}
|
||||
|
||||
// Tag templates defines the schema of the tags used to attach to Data Catalog
|
||||
// resources. It defines the mapping of accepted field names and types that can
|
||||
// be used within the tag. The tag template also controls the access to the tag.
|
||||
message TagTemplate {
|
||||
// Required when used in
|
||||
// [UpdateTagTemplateRequest][google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest].
|
||||
// The resource name of the tag template in URL format. For example,
|
||||
// projects/{project_id}/locations/{location}/tagTemplates/{tag_template_id}.
|
||||
string name = 1;
|
||||
|
||||
// Optional. The display name for this template. Default value is an empty
|
||||
// string.
|
||||
string display_name = 2;
|
||||
|
||||
// Required. Map of tag template field ids to the settings for the field.
|
||||
// This map is an exhaustive list of the allowed fields. This map must contain
|
||||
// at least one field and at most 500 fields.
|
||||
//
|
||||
// The keys to this map are tag template field IDs. Field IDs can contain
|
||||
// letters (both uppercase and lowercase), numbers (0-9) and underscores (_).
|
||||
// Field IDs must be at least 1 character long and at most 64 characters long.
|
||||
// Field IDs must start with a letter or underscore.
|
||||
map<string, TagTemplateField> fields = 3;
|
||||
}
|
||||
|
||||
// The template for an individual field within a tag template.
|
||||
message TagTemplateField {
|
||||
// Optional. The display name for this field. Default value is an empty
|
||||
// string.
|
||||
string display_name = 1;
|
||||
|
||||
// Required. The type of value this tag field can contain.
|
||||
FieldType type = 2;
|
||||
}
|
||||
|
||||
message FieldType {
|
||||
message EnumType {
|
||||
message EnumValue {
|
||||
// Required. The display name of the enum value. Must not be an empty
|
||||
// string.
|
||||
string display_name = 1;
|
||||
}
|
||||
|
||||
// Required. The set of allowed values for this enum. This set must not be
|
||||
// empty, the display names of the values in this set must not be empty and
|
||||
// the display names of the values must be case-insensitively unique within
|
||||
// this set. Currently, enum values can only be added to the list of allowed
|
||||
// values. Deletion and renaming of enum values are not supported. Can have
|
||||
// up to 500 allowed values.
|
||||
repeated EnumValue allowed_values = 1;
|
||||
}
|
||||
|
||||
enum PrimitiveType {
|
||||
// This is the default invalid value for a type.
|
||||
PRIMITIVE_TYPE_UNSPECIFIED = 0;
|
||||
|
||||
// A double precision number.
|
||||
DOUBLE = 1;
|
||||
|
||||
// An UTF-8 string.
|
||||
STRING = 2;
|
||||
|
||||
// A boolean value.
|
||||
BOOL = 3;
|
||||
|
||||
// A timestamp.
|
||||
TIMESTAMP = 4;
|
||||
}
|
||||
|
||||
// Required.
|
||||
oneof type_decl {
|
||||
// Represents primitive types - string, bool etc.
|
||||
PrimitiveType primitive_type = 1;
|
||||
|
||||
// Represents an enum type.
|
||||
EnumType enum_type = 2;
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue