fix: adjust to new generator and sdk use
Some checks failed
CI Workflow / Check GoReleaser config (pull_request) Successful in 5s
CI Workflow / Test readiness for publishing provider (pull_request) Failing after 3m33s
CI Workflow / CI run tests (pull_request) Failing after 4m51s
CI Workflow / CI run build and linting (pull_request) Failing after 4m37s
CI Workflow / Code coverage report (pull_request) Has been skipped
Some checks failed
CI Workflow / Check GoReleaser config (pull_request) Successful in 5s
CI Workflow / Test readiness for publishing provider (pull_request) Failing after 3m33s
CI Workflow / CI run tests (pull_request) Failing after 4m51s
CI Workflow / CI run build and linting (pull_request) Failing after 4m37s
CI Workflow / Code coverage report (pull_request) Has been skipped
This commit is contained in:
parent
ca0f646526
commit
826bb5b36a
36 changed files with 2089 additions and 1166 deletions
|
|
@ -10,11 +10,12 @@ import (
|
|||
"github.com/hashicorp/terraform-plugin-framework/diag"
|
||||
"github.com/hashicorp/terraform-plugin-framework/types"
|
||||
"github.com/hashicorp/terraform-plugin-log/tflog"
|
||||
|
||||
"github.com/stackitcloud/stackit-sdk-go/services/postgresflex/v3alpha1api"
|
||||
|
||||
"tf-provider.git.onstackit.cloud/stackit-dev-tools/terraform-provider-stackitprivatepreview/stackit/internal/conversion"
|
||||
"tf-provider.git.onstackit.cloud/stackit-dev-tools/terraform-provider-stackitprivatepreview/stackit/internal/core"
|
||||
postgresflexalpha2 "tf-provider.git.onstackit.cloud/stackit-dev-tools/terraform-provider-stackitprivatepreview/stackit/internal/services/postgresflexalpha/database/datasources_gen"
|
||||
pgDsGen "tf-provider.git.onstackit.cloud/stackit-dev-tools/terraform-provider-stackitprivatepreview/stackit/internal/services/postgresflexalpha/database/datasources_gen"
|
||||
postgresflexUtils "tf-provider.git.onstackit.cloud/stackit-dev-tools/terraform-provider-stackitprivatepreview/stackit/internal/services/postgresflexalpha/utils"
|
||||
"tf-provider.git.onstackit.cloud/stackit-dev-tools/terraform-provider-stackitprivatepreview/stackit/internal/utils"
|
||||
)
|
||||
|
|
@ -31,7 +32,7 @@ func NewDatabaseDataSource() datasource.DataSource {
|
|||
|
||||
// dataSourceModel maps the data source schema data.
|
||||
type dataSourceModel struct {
|
||||
postgresflexalpha2.DatabaseModel
|
||||
pgDsGen.DatabaseModel
|
||||
TerraformID types.String `tfsdk:"id"`
|
||||
}
|
||||
|
||||
|
|
@ -72,7 +73,7 @@ func (r *databaseDataSource) Configure(
|
|||
|
||||
// Schema defines the schema for the data source.
|
||||
func (r *databaseDataSource) Schema(ctx context.Context, _ datasource.SchemaRequest, resp *datasource.SchemaResponse) {
|
||||
s := postgresflexalpha2.DatabaseDataSourceSchema(ctx)
|
||||
s := pgDsGen.DatabaseDataSourceSchema(ctx)
|
||||
s.Attributes["id"] = schema.StringAttribute{
|
||||
Description: "Terraform's internal resource ID. It is structured as \\\"`project_id`,`region`,`instance_id`," +
|
||||
"`database_id`\\\".\",",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue