1// Copyright 2023 Google LLC 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15syntax = "proto3"; 16 17package google.cloud.datacatalog.v1; 18 19import "google/api/field_behavior.proto"; 20import "google/cloud/datacatalog/v1/timestamps.proto"; 21 22option cc_enable_arenas = true; 23option csharp_namespace = "Google.Cloud.DataCatalog.V1"; 24option go_package = "cloud.google.com/go/datacatalog/apiv1/datacatalogpb;datacatalogpb"; 25option java_multiple_files = true; 26option java_package = "com.google.cloud.datacatalog.v1"; 27option php_namespace = "Google\\Cloud\\DataCatalog\\V1"; 28option ruby_package = "Google::Cloud::DataCatalog::V1"; 29 30// Describes a Cloud Storage fileset entry. 31message GcsFilesetSpec { 32 // Required. Patterns to identify a set of files in Google Cloud Storage. 33 // 34 // For more information, see [Wildcard Names] 35 // (https://cloud.google.com/storage/docs/gsutil/addlhelp/WildcardNames). 36 // 37 // Note: Currently, bucket wildcards are not supported. 38 // 39 // Examples of valid `file_patterns`: 40 // 41 // * `gs://bucket_name/dir/*`: matches all files in `bucket_name/dir` 42 // directory 43 // * `gs://bucket_name/dir/**`: matches all files in `bucket_name/dir` 44 // and all subdirectories 45 // * `gs://bucket_name/file*`: matches files prefixed by `file` in 46 // `bucket_name` 47 // * `gs://bucket_name/??.txt`: matches files with two characters followed by 48 // `.txt` in `bucket_name` 49 // * `gs://bucket_name/[aeiou].txt`: matches files that contain a single 50 // vowel character followed by `.txt` in 51 // `bucket_name` 52 // * `gs://bucket_name/[a-m].txt`: matches files that contain `a`, `b`, ... 53 // or `m` followed by `.txt` in `bucket_name` 54 // * `gs://bucket_name/a/*/b`: matches all files in `bucket_name` that match 55 // the `a/*/b` pattern, such as `a/c/b`, `a/d/b` 56 // * `gs://another_bucket/a.txt`: matches `gs://another_bucket/a.txt` 57 // 58 // You can combine wildcards to match complex sets of files, for example: 59 // 60 // `gs://bucket_name/[a-m]??.j*g` 61 repeated string file_patterns = 1 [(google.api.field_behavior) = REQUIRED]; 62 63 // Output only. Sample files contained in this fileset, not all files 64 // contained in this fileset are represented here. 65 repeated GcsFileSpec sample_gcs_file_specs = 2 66 [(google.api.field_behavior) = OUTPUT_ONLY]; 67} 68 69// Specification of a single file in Cloud Storage. 70message GcsFileSpec { 71 // Required. Full file path. Example: `gs://bucket_name/a/b.txt`. 72 string file_path = 1 [(google.api.field_behavior) = REQUIRED]; 73 74 // Output only. Creation, modification, and expiration timestamps of a Cloud 75 // Storage file. 76 SystemTimestamps gcs_timestamps = 2 77 [(google.api.field_behavior) = OUTPUT_ONLY]; 78 79 // Output only. File size in bytes. 80 int64 size_bytes = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; 81} 82