Skip to content

Commit

Permalink
azurerm_digital_twins_time_series_database_connection - remove `Com…
Browse files Browse the repository at this point in the history
…puted` from `kusto_table_name` (#26484)

* azurerm_digital_twins_time_series_database_connection - remove Computed from kusto_table_name

* add original schema
neil-yechenwei authored Jun 27, 2024

Verified

This commit was signed with the committer’s verified signature.
JounQin JounQin
1 parent 2356027 commit e0527dd
Showing 1 changed file with 15 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -12,6 +12,7 @@ import (
"github.com/hashicorp/go-azure-helpers/resourcemanager/commonids"
"github.com/hashicorp/go-azure-sdk/resource-manager/digitaltwins/2023-01-31/timeseriesdatabaseconnections"
"github.com/hashicorp/go-azure-sdk/resource-manager/eventhub/2021-11-01/eventhubs"
"github.com/hashicorp/terraform-provider-azurerm/internal/features"
"github.com/hashicorp/terraform-provider-azurerm/internal/sdk"
"github.com/hashicorp/terraform-provider-azurerm/internal/services/digitaltwins/validate"
eventhubValidate "github.com/hashicorp/terraform-provider-azurerm/internal/services/eventhub/validate"
@@ -37,7 +38,7 @@ type TimeSeriesDatabaseConnectionModel struct {
type TimeSeriesDatabaseConnectionResource struct{}

func (m TimeSeriesDatabaseConnectionResource) Arguments() map[string]*pluginsdk.Schema {
return map[string]*pluginsdk.Schema{
resource := map[string]*pluginsdk.Schema{
"name": {
Type: pluginsdk.TypeString,
Required: true,
@@ -105,11 +106,23 @@ func (m TimeSeriesDatabaseConnectionResource) Arguments() map[string]*pluginsdk.
"kusto_table_name": {
Type: pluginsdk.TypeString,
Optional: true,
Computed: true,
Default: "AdtPropertyEvents",
ForceNew: true,
ValidateFunc: kustoValidate.EntityName,
},
}

if !features.FourPointOhBeta() {
resource["kusto_table_name"] = &pluginsdk.Schema{
Type: pluginsdk.TypeString,
Optional: true,
Computed: true,
ForceNew: true,
ValidateFunc: kustoValidate.EntityName,
}
}

return resource
}

func (m TimeSeriesDatabaseConnectionResource) Attributes() map[string]*pluginsdk.Schema {

0 comments on commit e0527dd

Please sign in to comment.