datafusion.proto 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519
  1. // Copyright 2021 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. syntax = "proto3";
  15. package google.cloud.datafusion.v1;
  16. import "google/api/annotations.proto";
  17. import "google/api/client.proto";
  18. import "google/api/field_behavior.proto";
  19. import "google/api/resource.proto";
  20. import "google/longrunning/operations.proto";
  21. import "google/protobuf/field_mask.proto";
  22. import "google/protobuf/timestamp.proto";
  23. option csharp_namespace = "Google.Cloud.DataFusion.V1";
  24. option go_package = "google.golang.org/genproto/googleapis/cloud/datafusion/v1;datafusion";
  25. option java_multiple_files = true;
  26. option java_package = "com.google.cloud.datafusion.v1";
  27. option php_namespace = "Google\\Cloud\\DataFusion\\V1";
  28. option ruby_package = "Google::Cloud::DataFusion::V1";
  29. // Service for creating and managing Data Fusion instances.
  30. // Data Fusion enables ETL developers to build code-free, data integration
  31. // pipelines via a point-and-click UI.
  32. service DataFusion {
  33. option (google.api.default_host) = "datafusion.googleapis.com";
  34. option (google.api.oauth_scopes) =
  35. "https://www.googleapis.com/auth/cloud-platform";
  36. // Lists possible versions for Data Fusion instances in the specified project
  37. // and location.
  38. rpc ListAvailableVersions(ListAvailableVersionsRequest)
  39. returns (ListAvailableVersionsResponse) {
  40. option (google.api.http) = {
  41. get: "/v1/{parent=projects/*/locations/*}/versions"
  42. };
  43. option (google.api.method_signature) = "parent";
  44. }
  45. // Lists Data Fusion instances in the specified project and location.
  46. rpc ListInstances(ListInstancesRequest) returns (ListInstancesResponse) {
  47. option (google.api.http) = {
  48. get: "/v1/{parent=projects/*/locations/*}/instances"
  49. };
  50. }
  51. // Gets details of a single Data Fusion instance.
  52. rpc GetInstance(GetInstanceRequest) returns (Instance) {
  53. option (google.api.http) = {
  54. get: "/v1/{name=projects/*/locations/*/instances/*}"
  55. };
  56. }
  57. // Creates a new Data Fusion instance in the specified project and location.
  58. rpc CreateInstance(CreateInstanceRequest)
  59. returns (google.longrunning.Operation) {
  60. option (google.api.http) = {
  61. post: "/v1/{parent=projects/*/locations/*}/instances"
  62. body: "instance"
  63. };
  64. option (google.api.method_signature) = "parent,instance,instance_id";
  65. option (google.longrunning.operation_info) = {
  66. response_type: "Instance"
  67. metadata_type: "OperationMetadata"
  68. };
  69. }
  70. // Deletes a single Date Fusion instance.
  71. rpc DeleteInstance(DeleteInstanceRequest)
  72. returns (google.longrunning.Operation) {
  73. option (google.api.http) = {
  74. delete: "/v1/{name=projects/*/locations/*/instances/*}"
  75. };
  76. option (google.api.method_signature) = "name";
  77. option (google.longrunning.operation_info) = {
  78. response_type: "google.protobuf.Empty"
  79. metadata_type: "OperationMetadata"
  80. };
  81. }
  82. // Updates a single Data Fusion instance.
  83. rpc UpdateInstance(UpdateInstanceRequest)
  84. returns (google.longrunning.Operation) {
  85. option (google.api.http) = {
  86. patch: "/v1/{instance.name=projects/*/locations/*/instances/*}"
  87. body: "instance"
  88. };
  89. option (google.api.method_signature) = "instance,update_mask";
  90. option (google.longrunning.operation_info) = {
  91. response_type: "Instance"
  92. metadata_type: "OperationMetadata"
  93. };
  94. }
  95. // Restart a single Data Fusion instance.
  96. // At the end of an operation instance is fully restarted.
  97. rpc RestartInstance(RestartInstanceRequest)
  98. returns (google.longrunning.Operation) {
  99. option (google.api.http) = {
  100. post: "/v1/{name=projects/*/locations/*/instances/*}:restart"
  101. body: "*"
  102. };
  103. option (google.longrunning.operation_info) = {
  104. response_type: "Instance"
  105. metadata_type: "OperationMetadata"
  106. };
  107. }
  108. }
  109. // Network configuration for a Data Fusion instance. These configurations
  110. // are used for peering with the customer network. Configurations are optional
  111. // when a public Data Fusion instance is to be created. However, providing
  112. // these configurations allows several benefits, such as reduced network latency
  113. // while accessing the customer resources from managed Data Fusion instance
  114. // nodes, as well as access to the customer on-prem resources.
  115. message NetworkConfig {
  116. // Name of the network in the customer project with which the Tenant Project
  117. // will be peered for executing pipelines. In case of shared VPC where the
  118. // network resides in another host project the network should specified in
  119. // the form of projects/{host-project-id}/global/networks/{network}
  120. string network = 1;
  121. // The IP range in CIDR notation to use for the managed Data Fusion instance
  122. // nodes. This range must not overlap with any other ranges used in the
  123. // customer network.
  124. string ip_allocation = 2;
  125. }
  126. // The Data Fusion version. This proto message stores information about certain
  127. // Data Fusion version, which is used for Data Fusion version upgrade.
  128. message Version {
  129. // The version number of the Data Fusion instance, such as '6.0.1.0'.
  130. string version_number = 1;
  131. // Whether this is currently the default version for Cloud Data Fusion
  132. bool default_version = 2;
  133. // Represents a list of available feature names for a given version.
  134. repeated string available_features = 3;
  135. }
  136. // Identifies Data Fusion accelerators for an instance.
  137. message Accelerator {
  138. // Each type represents an Accelerator (Add-On) supported by Cloud Data Fusion
  139. // service.
  140. enum AcceleratorType {
  141. // Default value, if unspecified.
  142. ACCELERATOR_TYPE_UNSPECIFIED = 0;
  143. // Change Data Capture accelerator for CDF.
  144. CDC = 1;
  145. // Cloud Healthcare accelerator for CDF. This accelerator is to enable Cloud
  146. // Healthcare specific CDF plugins developed by Healthcare team.
  147. HEALTHCARE = 2;
  148. // Contact Center AI Insights
  149. // This accelerator is used to enable import and export pipelines
  150. // custom built to streamline CCAI Insights processing.
  151. CCAI_INSIGHTS = 3;
  152. }
  153. // Different values possible for the state of an accelerator
  154. enum State {
  155. // Default value, do not use
  156. STATE_UNSPECIFIED = 0;
  157. // Indicates that the accelerator is enabled and available to use
  158. ENABLED = 1;
  159. // Indicates that the accelerator is disabled and not available to use
  160. DISABLED = 2;
  161. // Indicates that accelerator state is currently unknown.
  162. // Requests for enable, disable could be retried while in this state
  163. UNKNOWN = 3;
  164. }
  165. // The type of an accelator for a CDF instance.
  166. AcceleratorType accelerator_type = 1;
  167. // The state of the accelerator
  168. State state = 2;
  169. }
  170. // The crypto key configuration. This field is used by the Customer-managed
  171. // encryption keys (CMEK) feature.
  172. message CryptoKeyConfig {
  173. // The name of the key which is used to encrypt/decrypt customer data. For key
  174. // in Cloud KMS, the key should be in the format of
  175. // `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
  176. string key_reference = 1;
  177. }
  178. // Represents a Data Fusion instance.
  179. message Instance {
  180. option (google.api.resource) = {
  181. type: "datafusion.googleapis.com/Instance"
  182. pattern: "projects/{project}/locations/{location}/instances/{instance}"
  183. };
  184. // Represents the type of Data Fusion instance. Each type is configured with
  185. // the default settings for processing and memory.
  186. enum Type {
  187. // No type specified. The instance creation will fail.
  188. TYPE_UNSPECIFIED = 0;
  189. // Basic Data Fusion instance. In Basic type, the user will be able to
  190. // create data pipelines using point and click UI. However, there are
  191. // certain limitations, such as fewer number of concurrent pipelines, no
  192. // support for streaming pipelines, etc.
  193. BASIC = 1;
  194. // Enterprise Data Fusion instance. In Enterprise type, the user will have
  195. // all features available, such as support for streaming pipelines, higher
  196. // number of concurrent pipelines, etc.
  197. ENTERPRISE = 2;
  198. // Developer Data Fusion instance. In Developer type, the user will have all
  199. // features available but with restrictive capabilities. This is to help
  200. // enterprises design and develop their data ingestion and integration
  201. // pipelines at low cost.
  202. DEVELOPER = 3;
  203. }
  204. // Represents the state of a Data Fusion instance
  205. enum State {
  206. // Instance does not have a state yet
  207. STATE_UNSPECIFIED = 0;
  208. // Instance is being created
  209. CREATING = 1;
  210. // Instance is active and ready for requests. This corresponds to 'RUNNING'
  211. // in datafusion.v1beta1.
  212. ACTIVE = 2;
  213. // Instance creation failed
  214. FAILED = 3;
  215. // Instance is being deleted
  216. DELETING = 4;
  217. // Instance is being upgraded
  218. UPGRADING = 5;
  219. // Instance is being restarted
  220. RESTARTING = 6;
  221. // Instance is being updated on customer request
  222. UPDATING = 7;
  223. // Instance is being auto-updated
  224. AUTO_UPDATING = 8;
  225. // Instance is being auto-upgraded
  226. AUTO_UPGRADING = 9;
  227. }
  228. // Output only. The name of this instance is in the form of
  229. // projects/{project}/locations/{location}/instances/{instance}.
  230. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  231. // A description of this instance.
  232. string description = 2;
  233. // Required. Instance type.
  234. Type type = 3 [(google.api.field_behavior) = REQUIRED];
  235. // Option to enable Stackdriver Logging.
  236. bool enable_stackdriver_logging = 4;
  237. // Option to enable Stackdriver Monitoring.
  238. bool enable_stackdriver_monitoring = 5;
  239. // Specifies whether the Data Fusion instance should be private. If set to
  240. // true, all Data Fusion nodes will have private IP addresses and will not be
  241. // able to access the public internet.
  242. bool private_instance = 6;
  243. // Network configuration options. These are required when a private Data
  244. // Fusion instance is to be created.
  245. NetworkConfig network_config = 7;
  246. // The resource labels for instance to use to annotate any related underlying
  247. // resources such as Compute Engine VMs. The character '=' is not allowed to
  248. // be used within the labels.
  249. map<string, string> labels = 8;
  250. // Map of additional options used to configure the behavior of
  251. // Data Fusion instance.
  252. map<string, string> options = 9;
  253. // Output only. The time the instance was created.
  254. google.protobuf.Timestamp create_time = 10
  255. [(google.api.field_behavior) = OUTPUT_ONLY];
  256. // Output only. The time the instance was last updated.
  257. google.protobuf.Timestamp update_time = 11
  258. [(google.api.field_behavior) = OUTPUT_ONLY];
  259. // Output only. The current state of this Data Fusion instance.
  260. State state = 12 [(google.api.field_behavior) = OUTPUT_ONLY];
  261. // Output only. Additional information about the current state of this Data
  262. // Fusion instance if available.
  263. string state_message = 13 [(google.api.field_behavior) = OUTPUT_ONLY];
  264. // Output only. Endpoint on which the Data Fusion UI is accessible.
  265. string service_endpoint = 14 [(google.api.field_behavior) = OUTPUT_ONLY];
  266. // Name of the zone in which the Data Fusion instance will be created. Only
  267. // DEVELOPER instances use this field.
  268. string zone = 15;
  269. // Current version of the Data Fusion. Only specifiable in Update.
  270. string version = 16;
  271. // Output only. Deprecated. Use tenant_project_id instead to extract the
  272. // tenant project ID.
  273. string service_account = 17
  274. [deprecated = true, (google.api.field_behavior) = OUTPUT_ONLY];
  275. // Display name for an instance.
  276. string display_name = 18;
  277. // Available versions that the instance can be upgraded to using
  278. // UpdateInstanceRequest.
  279. repeated Version available_version = 19;
  280. // Output only. Endpoint on which the REST APIs is accessible.
  281. string api_endpoint = 20 [(google.api.field_behavior) = OUTPUT_ONLY];
  282. // Output only. Cloud Storage bucket generated by Data Fusion in the customer
  283. // project.
  284. string gcs_bucket = 21 [(google.api.field_behavior) = OUTPUT_ONLY];
  285. // List of accelerators enabled for this CDF instance.
  286. repeated Accelerator accelerators = 22;
  287. // Output only. P4 service account for the customer project.
  288. string p4_service_account = 23 [(google.api.field_behavior) = OUTPUT_ONLY];
  289. // Output only. The name of the tenant project.
  290. string tenant_project_id = 24 [(google.api.field_behavior) = OUTPUT_ONLY];
  291. // User-managed service account to set on Dataproc when Cloud Data Fusion
  292. // creates Dataproc to run data processing pipelines.
  293. //
  294. // This allows users to have fine-grained access control on Dataproc's
  295. // accesses to cloud resources.
  296. string dataproc_service_account = 25;
  297. // Option to enable granular role-based access control.
  298. bool enable_rbac = 27;
  299. // The crypto key configuration. This field is used by the Customer-Managed
  300. // Encryption Keys (CMEK) feature.
  301. CryptoKeyConfig crypto_key_config = 28;
  302. }
  303. // Request message for listing Data Fusion instances.
  304. message ListInstancesRequest {
  305. // The project and location for which to retrieve instance information
  306. // in the format projects/{project}/locations/{location}. If the location is
  307. // specified as '-' (wildcard), then all regions available to the project
  308. // are queried, and the results are aggregated.
  309. string parent = 1;
  310. // The maximum number of items to return.
  311. int32 page_size = 2;
  312. // The next_page_token value to use if there are additional
  313. // results to retrieve for this list request.
  314. string page_token = 3;
  315. // List filter.
  316. string filter = 4;
  317. // Sort results. Supported values are "name", "name desc", or "" (unsorted).
  318. string order_by = 5;
  319. }
  320. // Response message for the list instance request.
  321. message ListInstancesResponse {
  322. // Represents a list of Data Fusion instances.
  323. repeated Instance instances = 1;
  324. // Token to retrieve the next page of results or empty if there are no more
  325. // results in the list.
  326. string next_page_token = 2;
  327. // Locations that could not be reached.
  328. repeated string unreachable = 3;
  329. }
  330. // Request message for the list available versions request.
  331. message ListAvailableVersionsRequest {
  332. // Required. The project and location for which to retrieve instance
  333. // information in the format projects/{project}/locations/{location}.
  334. string parent = 1 [(google.api.field_behavior) = REQUIRED];
  335. // The maximum number of items to return.
  336. int32 page_size = 2;
  337. // The next_page_token value to use if there are additional
  338. // results to retrieve for this list request.
  339. string page_token = 3;
  340. // Whether or not to return the latest patch of every available minor version.
  341. // If true, only the latest patch will be returned. Ex. if allowed versions is
  342. // [6.1.1, 6.1.2, 6.2.0] then response will be [6.1.2, 6.2.0]
  343. bool latest_patch_only = 4;
  344. }
  345. // Response message for the list available versions request.
  346. message ListAvailableVersionsResponse {
  347. // Represents a list of versions that are supported.
  348. repeated Version available_versions = 1;
  349. // Token to retrieve the next page of results or empty if there are no more
  350. // results in the list.
  351. string next_page_token = 2;
  352. }
  353. // Request message for getting details about a Data Fusion instance.
  354. message GetInstanceRequest {
  355. // The instance resource name in the format
  356. // projects/{project}/locations/{location}/instances/{instance}.
  357. string name = 1;
  358. }
  359. // Request message for creating a Data Fusion instance.
  360. message CreateInstanceRequest {
  361. // The instance's project and location in the format
  362. // projects/{project}/locations/{location}.
  363. string parent = 1;
  364. // The name of the instance to create.
  365. string instance_id = 2;
  366. // An instance resource.
  367. Instance instance = 3;
  368. }
  369. // Request message for deleting a Data Fusion instance.
  370. message DeleteInstanceRequest {
  371. // The instance resource name in the format
  372. // projects/{project}/locations/{location}/instances/{instance}
  373. string name = 1;
  374. }
  375. message UpdateInstanceRequest {
  376. // The instance resource that replaces the resource on the server. Currently,
  377. // Data Fusion only allows replacing labels, options, and stack driver
  378. // settings. All other fields will be ignored.
  379. Instance instance = 1;
  380. // Field mask is used to specify the fields that the update will overwrite
  381. // in an instance resource. The fields specified in the update_mask are
  382. // relative to the resource, not the full request.
  383. // A field will be overwritten if it is in the mask.
  384. // If the user does not provide a mask, all the supported fields (labels,
  385. // options, and version currently) will be overwritten.
  386. google.protobuf.FieldMask update_mask = 2;
  387. }
  388. // Request message for restarting a Data Fusion instance.
  389. message RestartInstanceRequest {
  390. // Name of the Data Fusion instance which need to be restarted in the form of
  391. // projects/{project}/locations/{location}/instances/{instance}
  392. string name = 1;
  393. }
  394. // Represents the metadata of a long-running operation.
  395. message OperationMetadata {
  396. // The time the operation was created.
  397. google.protobuf.Timestamp create_time = 1;
  398. // The time the operation finished running.
  399. google.protobuf.Timestamp end_time = 2;
  400. // Server-defined resource path for the target of the operation.
  401. string target = 3;
  402. // Name of the verb executed by the operation.
  403. string verb = 4;
  404. // Human-readable status of the operation if any.
  405. string status_detail = 5;
  406. // Identifies whether the user has requested cancellation
  407. // of the operation. Operations that have successfully been cancelled
  408. // have [Operation.error][] value with a
  409. // [google.rpc.Status.code][google.rpc.Status.code] of 1, corresponding to
  410. // `Code.CANCELLED`.
  411. bool requested_cancellation = 6;
  412. // API version used to start the operation.
  413. string api_version = 7;
  414. // Map to hold any additional status info for the operation
  415. // If there is an accelerator being enabled/disabled/deleted, this will be
  416. // populated with accelerator name as key and status as
  417. // ENABLING, DISABLING or DELETING
  418. map<string, string> additional_status = 8;
  419. }