Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

azurerm_kusto_cluster: deprecate and make engine non functional #22497

Merged
merged 3 commits into from
Jul 21, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions internal/services/kusto/kusto_cluster_resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ func resourceKustoCluster() *pluginsdk.Resource {
"engine": {
Type: pluginsdk.TypeString,
Optional: true,
ForceNew: true,
Deprecated: "The `engine` property will automatically be upgraded by the service team to v3 and is due to be removed from the api therefore it has been deprecated and will no longer function. It will be removed in a future version of the provider.",
katbyte marked this conversation as resolved.
Show resolved Hide resolved
ValidateFunc: validation.StringInSlice(clusters.PossibleValuesForEngineType(), false),
},

Expand Down Expand Up @@ -241,7 +241,6 @@ func resourceKustoCluster() *pluginsdk.Resource {
}

if features.FourPointOhBeta() {
s.Schema["engine"].Default = string(clusters.EngineTypeVThree)
s.Schema["language_extensions"] = &pluginsdk.Schema{
Type: pluginsdk.TypeList,
Optional: true,
Expand All @@ -262,7 +261,6 @@ func resourceKustoCluster() *pluginsdk.Resource {
},
}
} else {
s.Schema["engine"].Default = string(clusters.EngineTypeVTwo)
s.Schema["language_extensions"] = &pluginsdk.Schema{
Type: pluginsdk.TypeSet,
Optional: true,
Expand Down Expand Up @@ -328,8 +326,6 @@ func resourceKustoClusterCreateUpdate(d *pluginsdk.ResourceData, meta interface{
}
}

engine := clusters.EngineType(d.Get("engine").(string))

publicNetworkAccess := clusters.PublicNetworkAccessEnabled
if !d.Get("public_network_access_enabled").(bool) {
publicNetworkAccess = clusters.PublicNetworkAccessDisabled
Expand Down Expand Up @@ -469,7 +465,6 @@ func resourceKustoClusterRead(d *pluginsdk.ResourceData, meta interface{}) error
d.Set("virtual_network_configuration", flattenKustoClusterVNET(props.VirtualNetworkConfiguration))
d.Set("uri", props.Uri)
d.Set("data_ingestion_uri", props.DataIngestionUri)
d.Set("engine", string(pointer.From(props.EngineType)))
d.Set("public_ip_type", string(pointer.From(props.PublicIPType)))

if features.FourPointOhBeta() {
Expand Down
4 changes: 0 additions & 4 deletions website/docs/r/kusto_cluster.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,6 @@ The following arguments are supported:

* `zones` - (Optional) Specifies a list of Availability Zones in which this Kusto Cluster should be located. Changing this forces a new Kusto Cluster to be created.

* `engine` - (Optional). The engine type that will be used in the backend. Possible values are `V2` and `V3`. Defaults to `V2`.

~> **NOTE:** In `v4.0.0` and later version of the AzureRM Provider, default engine type will be changed to `V3`.

---

A `sku` block supports the following:
Expand Down