|
| 1 | +# Copyright 2025 Google Inc. |
| 2 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 3 | +# you may not use this file except in compliance with the License. |
| 4 | +# You may obtain a copy of the License at |
| 5 | +# |
| 6 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 7 | +# |
| 8 | +# Unless required by applicable law or agreed to in writing, software |
| 9 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 10 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 11 | +# See the License for the specific language governing permissions and |
| 12 | +# limitations under the License. |
| 13 | + |
| 14 | +--- |
| 15 | +name: 'ConnectCluster' |
| 16 | +description: A Managed Service for Kafka Connect cluster. |
| 17 | +min_version: 'beta' |
| 18 | +docs: |
| 19 | +id_format: 'projects/{{project}}/locations/{{location}}/connectClusters/{{connect_cluster_id}}' |
| 20 | +base_url: 'projects/{{project}}/locations/{{location}}/connectClusters' |
| 21 | +self_link: 'projects/{{project}}/locations/{{location}}/connectClusters/{{connect_cluster_id}}' |
| 22 | +create_url: 'projects/{{project}}/locations/{{location}}/connectClusters?connectClusterId={{connect_cluster_id}}' |
| 23 | +update_verb: 'PATCH' |
| 24 | +update_mask: true |
| 25 | +import_format: |
| 26 | + - 'projects/{{project}}/locations/{{location}}/connectClusters/{{connect_cluster_id}}' |
| 27 | +timeouts: |
| 28 | + insert_minutes: 60 |
| 29 | + update_minutes: 30 |
| 30 | + delete_minutes: 30 |
| 31 | +autogen_async: true |
| 32 | +async: |
| 33 | + actions: ['create', 'delete', 'update'] |
| 34 | + type: 'OpAsync' |
| 35 | + operation: |
| 36 | + base_url: '{{op_id}}' |
| 37 | + timeouts: |
| 38 | + result: |
| 39 | + resource_inside_response: true |
| 40 | +custom_code: |
| 41 | +examples: |
| 42 | + - name: 'managedkafka_connect_cluster_basic' |
| 43 | + primary_resource_id: 'example' |
| 44 | + min_version: 'beta' |
| 45 | + vars: |
| 46 | + connect_cluster_id: 'my-connect-cluster' |
| 47 | + cluster_id: 'my-cluster' |
| 48 | + subnetwork_id: 'my-subnetwork' |
| 49 | + network_id: 'my-network' |
| 50 | +parameters: |
| 51 | + - name: 'location' |
| 52 | + type: String |
| 53 | + description: "ID of the location of the Kafka Connect resource. See |
| 54 | + https://cloud.google.com/managed-kafka/docs/locations for a list of |
| 55 | + supported locations." |
| 56 | + required: true |
| 57 | + immutable: true |
| 58 | + url_param_only: true |
| 59 | + - name: 'connectClusterId' |
| 60 | + type: String |
| 61 | + description: "The ID to use for the Connect Cluster, which will become the final |
| 62 | + component of the connect cluster's name. This value is structured like: `my-connect-cluster-id`." |
| 63 | + url_param_only: true |
| 64 | + required: true |
| 65 | + immutable: true |
| 66 | +properties: |
| 67 | + - name: 'name' |
| 68 | + type: String |
| 69 | + description: "The name of the connect cluster. Structured like: `projects/PROJECT_ID/locations/LOCATION/connectClusters/CONNECT_CLUSTER_ID`." |
| 70 | + output: true |
| 71 | + - name: 'kafkaCluster' |
| 72 | + type: String |
| 73 | + description: "The name of the Kafka cluster this Kafka Connect cluster is attached to. Structured like: `projects/PROJECT_ID/locations/LOCATION/clusters/CLUSTER_ID`." |
| 74 | + required: true |
| 75 | + - name: 'createTime' |
| 76 | + type: String |
| 77 | + description: "The time when the cluster was created." |
| 78 | + output: true |
| 79 | + - name: 'updateTime' |
| 80 | + type: String |
| 81 | + description: "The time when the cluster was last updated." |
| 82 | + output: true |
| 83 | + - name: 'labels' |
| 84 | + type: KeyValueLabels |
| 85 | + description: "List of label KEY=VALUE pairs to add. Keys must start with a lowercase |
| 86 | + character and contain only hyphens (-), underscores (\_), lowercase |
| 87 | + characters, and numbers. Values must contain only hyphens (-), |
| 88 | + underscores (\_), lowercase characters, and numbers." |
| 89 | + - name: 'capacityConfig' |
| 90 | + type: NestedObject |
| 91 | + description: "A capacity configuration of a Kafka cluster." |
| 92 | + required: true |
| 93 | + properties: |
| 94 | + - name: vcpuCount |
| 95 | + type: String |
| 96 | + description: "The number of vCPUs to provision for the cluster. The minimum is 3." |
| 97 | + required: true |
| 98 | + - name: memoryBytes |
| 99 | + type: String |
| 100 | + description: "The memory to provision for the cluster in bytes. The CPU:memory ratio (vCPU:GiB) must be between 1:1 and 1:8. Minimum: 3221225472 (3 GiB)." |
| 101 | + required: true |
| 102 | + - name: 'gcpConfig' |
| 103 | + type: NestedObject |
| 104 | + description: "Configuration properties for a Kafka Connect cluster deployed to Google Cloud Platform." |
| 105 | + required: true |
| 106 | + properties: |
| 107 | + - name: 'accessConfig' |
| 108 | + type: NestedObject |
| 109 | + description: "The configuration of access to the Kafka Connect cluster." |
| 110 | + required: true |
| 111 | + properties: |
| 112 | + - name: 'networkConfigs' |
| 113 | + type: Array |
| 114 | + description: "Virtual Private Cloud (VPC) subnets where IP addresses for the Kafka Connect |
| 115 | + cluster are allocated. To make the connect cluster available in a VPC, you must specify at least |
| 116 | + one subnet per network. You must specify between 1 and 10 subnets. |
| 117 | + Additional subnets may be specified with additional `network_configs` blocks." |
| 118 | + required: true |
| 119 | + item_type: |
| 120 | + type: NestedObject |
| 121 | + properties: |
| 122 | + - name: 'primarySubnet' |
| 123 | + type: String |
| 124 | + description: "VPC subnet to make available to the Kafka Connect cluster. Structured like: projects/{project}/regions/{region}/subnetworks/{subnet_id}. |
| 125 | + It is used to create a Private Service Connect (PSC) interface for the Kafka Connect workers. It must be located in the same region as the |
| 126 | + Kafka Connect cluster. The CIDR range of the subnet must be within the IPv4 address ranges for private networks, as specified in RFC 1918. |
| 127 | + The primary subnet CIDR range must have a minimum size of /22 (1024 addresses)." |
| 128 | + required: true |
| 129 | + diff_suppress_func: 'tpgresource.ProjectNumberDiffSuppress' |
| 130 | + - name: 'additionalSubnets' |
| 131 | + type: Array |
| 132 | + description: "Additional subnets may be specified. They may be in another region, but must be in the |
| 133 | + same VPC network. The Connect workers can communicate with |
| 134 | + network endpoints in either the primary or additional subnets." |
| 135 | + item_type: |
| 136 | + type: String |
| 137 | + - name: 'dnsDomainNames' |
| 138 | + type: Array |
| 139 | + description: "Additional DNS domain names from the subnet's network to be made visible to the Connect Cluster. When using |
| 140 | + MirrorMaker2, it's necessary to add the bootstrap address's dns domain name of the target cluster to make it visible to |
| 141 | + the connector. For example: my-kafka-cluster.us-central1.managedkafka.my-project.cloud.goog" |
| 142 | + item_type: |
| 143 | + type: String |
| 144 | + - name: 'state' |
| 145 | + type: String |
| 146 | + description: "The current state of the connect cluster. Possible values: `STATE_UNSPECIFIED`, `CREATING`, `ACTIVE`, `DELETING`." |
| 147 | + output: true |
0 commit comments