|
1 | | -// Copyright 2025 Google LLC |
| 1 | +// Copyright 2026 Google LLC |
2 | 2 | // |
3 | 3 | // Licensed under the Apache License, Version 2.0 (the "License"); |
4 | 4 | // you may not use this file except in compliance with the License. |
@@ -18,6 +18,7 @@ package google.cloud.bigquery.migration.v2; |
18 | 18 |
|
19 | 19 | import "google/api/field_behavior.proto"; |
20 | 20 | import "google/api/resource.proto"; |
| 21 | +import "google/cloud/bigquery/migration/v2/assessment_task.proto"; |
21 | 22 | import "google/cloud/bigquery/migration/v2/migration_error_details.proto"; |
22 | 23 | import "google/cloud/bigquery/migration/v2/migration_metrics.proto"; |
23 | 24 | import "google/cloud/bigquery/migration/v2/translation_config.proto"; |
@@ -85,11 +86,13 @@ message MigrationWorkflow { |
85 | 86 | // Output only. That status of the workflow. |
86 | 87 | State state = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; |
87 | 88 |
|
88 | | - // Time when the workflow was created. |
89 | | - google.protobuf.Timestamp create_time = 4; |
| 89 | + // Output only. Time when the workflow was created. |
| 90 | + google.protobuf.Timestamp create_time = 4 |
| 91 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
90 | 92 |
|
91 | | - // Time when the workflow was last updated. |
92 | | - google.protobuf.Timestamp last_update_time = 5; |
| 93 | + // Output only. Time when the workflow was last updated. |
| 94 | + google.protobuf.Timestamp last_update_time = 5 |
| 95 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
93 | 96 | } |
94 | 97 |
|
95 | 98 | // A single task for a migration which has details about the configuration of |
@@ -109,7 +112,7 @@ message MigrationTask { |
109 | 112 | // The task is running, i.e. its subtasks are ready for execution. |
110 | 113 | RUNNING = 3; |
111 | 114 |
|
112 | | - // Tha task is paused. Assigned subtasks can continue, but no new subtasks |
| 115 | + // The task is paused. Assigned subtasks can continue, but no new subtasks |
113 | 116 | // will be scheduled. |
114 | 117 | PAUSED = 4; |
115 | 118 |
|
@@ -122,6 +125,9 @@ message MigrationTask { |
122 | 125 |
|
123 | 126 | // The details of the task. |
124 | 127 | oneof task_details { |
| 128 | + // Task configuration for Assessment. |
| 129 | + AssessmentTaskDetails assessment_task_details = 12; |
| 130 | + |
125 | 131 | // Task configuration for CW Batch/Offline SQL Translation. |
126 | 132 | TranslationConfigDetails translation_config_details = 14; |
127 | 133 |
|
@@ -136,13 +142,22 @@ message MigrationTask { |
136 | 142 | (google.api.field_behavior) = IMMUTABLE |
137 | 143 | ]; |
138 | 144 |
|
139 | | - // The type of the task. This must be one of the supported task types: |
140 | | - // Translation_Teradata2BQ, Translation_Redshift2BQ, Translation_Bteq2BQ, |
141 | | - // Translation_Oracle2BQ, Translation_HiveQL2BQ, Translation_SparkSQL2BQ, |
142 | | - // Translation_Snowflake2BQ, Translation_Netezza2BQ, |
143 | | - // Translation_AzureSynapse2BQ, Translation_Vertica2BQ, |
144 | | - // Translation_SQLServer2BQ, Translation_Presto2BQ, Translation_MySQL2BQ, |
145 | | - // Translation_Postgresql2BQ, Translation_SQLite2BQ, Translation_Greenplum2BQ. |
| 145 | + // The type of the task. This must be one of the supported task types. |
| 146 | + // |
| 147 | + // Assessment: |
| 148 | + // |
| 149 | + // - `Assessment_Hive` - Assessment for Hive. |
| 150 | + // - `Assessment_Redshift` - Assessment for Redshift. |
| 151 | + // - `Assessment_Snowflake` - Assessment for Snowflake. |
| 152 | + // - `Assessment_Teradata_v2` - Assessment for Teradata. |
| 153 | + // - `Assessment_Oracle` - Assessment for Oracle. |
| 154 | + // - `Assessment_Hadoop` - Assessment for Hadoop. |
| 155 | + // - `Assessment_Informatica` - Assessment for Informatica. |
| 156 | + // |
| 157 | + // Translation: |
| 158 | + // See [Supported Task |
| 159 | + // Types](https://docs.cloud.google.com/bigquery/docs/api-sql-translator#supported_task_types) |
| 160 | + // for a list of supported task types. |
146 | 161 | string type = 2; |
147 | 162 |
|
148 | 163 | // Output only. The current state of the task. |
@@ -153,36 +168,42 @@ message MigrationTask { |
153 | 168 | google.rpc.ErrorInfo processing_error = 5 |
154 | 169 | [(google.api.field_behavior) = OUTPUT_ONLY]; |
155 | 170 |
|
156 | | - // Time when the task was created. |
157 | | - google.protobuf.Timestamp create_time = 6; |
| 171 | + // Output only. Time when the task was created. |
| 172 | + google.protobuf.Timestamp create_time = 6 |
| 173 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
158 | 174 |
|
159 | | - // Time when the task was last updated. |
160 | | - google.protobuf.Timestamp last_update_time = 7; |
| 175 | + // Output only. Time when the task was last updated. |
| 176 | + google.protobuf.Timestamp last_update_time = 7 |
| 177 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
161 | 178 |
|
162 | 179 | // Output only. Provides details to errors and issues encountered while |
163 | 180 | // processing the task. Presence of error details does not mean that the task |
164 | 181 | // failed. |
165 | 182 | repeated ResourceErrorDetail resource_error_details = 17 |
166 | 183 | [(google.api.field_behavior) = OUTPUT_ONLY]; |
167 | 184 |
|
168 | | - // The number or resources with errors. Note: This is not the total |
169 | | - // number of errors as each resource can have more than one error. |
170 | | - // This is used to indicate truncation by having a `resource_error_count` |
171 | | - // that is higher than the size of `resource_error_details`. |
172 | | - int32 resource_error_count = 18; |
| 185 | + // Output only. The number or resources with errors. Note: This is not the |
| 186 | + // total number of errors as each resource can have more than one error. This |
| 187 | + // is used to indicate truncation by having a `resource_error_count` that is |
| 188 | + // higher than the size of `resource_error_details`. |
| 189 | + int32 resource_error_count = 18 [(google.api.field_behavior) = OUTPUT_ONLY]; |
173 | 190 |
|
174 | | - // The metrics for the task. |
175 | | - repeated TimeSeries metrics = 19; |
| 191 | + // Output only. The metrics for the task. |
| 192 | + repeated TimeSeries metrics = 19 [(google.api.field_behavior) = OUTPUT_ONLY]; |
176 | 193 |
|
177 | 194 | // Output only. The result of the task. |
178 | 195 | MigrationTaskResult task_result = 20 |
179 | 196 | [(google.api.field_behavior) = OUTPUT_ONLY]; |
180 | 197 |
|
181 | | - // Count of all the processing errors in this task and its subtasks. |
182 | | - int32 total_processing_error_count = 21; |
| 198 | + // Output only. Count of all the processing errors in this task and its |
| 199 | + // subtasks. |
| 200 | + int32 total_processing_error_count = 21 |
| 201 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
183 | 202 |
|
184 | | - // Count of all the resource errors in this task and its subtasks. |
185 | | - int32 total_resource_error_count = 22; |
| 203 | + // Output only. Count of all the resource errors in this task and its |
| 204 | + // subtasks. |
| 205 | + int32 total_resource_error_count = 22 |
| 206 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
186 | 207 | } |
187 | 208 |
|
188 | 209 | // A subtask for a migration which carries details about the configuration of |
@@ -252,20 +273,22 @@ message MigrationSubtask { |
252 | 273 | repeated ResourceErrorDetail resource_error_details = 12 |
253 | 274 | [(google.api.field_behavior) = OUTPUT_ONLY]; |
254 | 275 |
|
255 | | - // The number or resources with errors. Note: This is not the total |
256 | | - // number of errors as each resource can have more than one error. |
257 | | - // This is used to indicate truncation by having a `resource_error_count` |
258 | | - // that is higher than the size of `resource_error_details`. |
259 | | - int32 resource_error_count = 13; |
| 276 | + // Output only. The number or resources with errors. Note: This is not the |
| 277 | + // total number of errors as each resource can have more than one error. This |
| 278 | + // is used to indicate truncation by having a `resource_error_count` that is |
| 279 | + // higher than the size of `resource_error_details`. |
| 280 | + int32 resource_error_count = 13 [(google.api.field_behavior) = OUTPUT_ONLY]; |
260 | 281 |
|
261 | | - // Time when the subtask was created. |
262 | | - google.protobuf.Timestamp create_time = 7; |
| 282 | + // Output only. Time when the subtask was created. |
| 283 | + google.protobuf.Timestamp create_time = 7 |
| 284 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
263 | 285 |
|
264 | | - // Time when the subtask was last updated. |
265 | | - google.protobuf.Timestamp last_update_time = 8; |
| 286 | + // Output only. Time when the subtask was last updated. |
| 287 | + google.protobuf.Timestamp last_update_time = 8 |
| 288 | + [(google.api.field_behavior) = OUTPUT_ONLY]; |
266 | 289 |
|
267 | | - // The metrics for the subtask. |
268 | | - repeated TimeSeries metrics = 11; |
| 290 | + // Output only. The metrics for the subtask. |
| 291 | + repeated TimeSeries metrics = 11 [(google.api.field_behavior) = OUTPUT_ONLY]; |
269 | 292 | } |
270 | 293 |
|
271 | 294 | // The migration task result. |
@@ -284,4 +307,7 @@ message TranslationTaskResult { |
284 | 307 |
|
285 | 308 | // The records from the aggregate CSV report for a migration workflow. |
286 | 309 | repeated GcsReportLogMessage report_log_messages = 2; |
| 310 | + |
| 311 | + // The Cloud Console URI for the migration workflow. |
| 312 | + string console_uri = 3; |
287 | 313 | } |