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.bigquery.migration.v2; 18 19import "google/api/field_behavior.proto"; 20import "google/rpc/error_details.proto"; 21 22option csharp_namespace = "Google.Cloud.BigQuery.Migration.V2"; 23option go_package = "cloud.google.com/go/bigquery/migration/apiv2/migrationpb;migrationpb"; 24option java_multiple_files = true; 25option java_outer_classname = "MigrationErrorDetailsProto"; 26option java_package = "com.google.cloud.bigquery.migration.v2"; 27option php_namespace = "Google\\Cloud\\BigQuery\\Migration\\V2"; 28 29// Provides details for errors and the corresponding resources. 30message ResourceErrorDetail { 31 // Required. Information about the resource where the error is located. 32 google.rpc.ResourceInfo resource_info = 1 33 [(google.api.field_behavior) = REQUIRED]; 34 35 // Required. The error details for the resource. 36 repeated ErrorDetail error_details = 2 37 [(google.api.field_behavior) = REQUIRED]; 38 39 // Required. How many errors there are in total for the resource. Truncation 40 // can be indicated by having an `error_count` that is higher than the size of 41 // `error_details`. 42 int32 error_count = 3 [(google.api.field_behavior) = REQUIRED]; 43} 44 45// Provides details for errors, e.g. issues that where encountered when 46// processing a subtask. 47message ErrorDetail { 48 // Optional. The exact location within the resource (if applicable). 49 ErrorLocation location = 1 [(google.api.field_behavior) = OPTIONAL]; 50 51 // Required. Describes the cause of the error with structured detail. 52 google.rpc.ErrorInfo error_info = 2 [(google.api.field_behavior) = REQUIRED]; 53} 54 55// Holds information about where the error is located. 56message ErrorLocation { 57 // Optional. If applicable, denotes the line where the error occurred. A zero 58 // value means that there is no line information. 59 int32 line = 1 [(google.api.field_behavior) = OPTIONAL]; 60 61 // Optional. If applicable, denotes the column where the error occurred. A 62 // zero value means that there is no columns information. 63 int32 column = 2 [(google.api.field_behavior) = OPTIONAL]; 64} 65