gridscale / terraform-provider-gridscale

Terraform gridscale provider
https://registry.terraform.io/providers/gridscale/gridscale/latest/docs
Mozilla Public License 2.0
12 stars 11 forks source link

Error 400: Invalid Service Parameters when Creating MySQL 8 PaaS Instance #246

Closed FloSchick closed 9 months ago

FloSchick commented 9 months ago

When attempting to create a MySQL 8.0 PaaS instance using the gridscale Terraform Provider (version 1.22.0), an error with status code 400 is encountered. The error message is as follows:

Error: Status code: 400. Error: {'type': 'HTTPError', 'status_code': 400, 'message': "(400, 'Service parameters are not valid - please check the parameter schema definition')"}. Request UUID: 38ba37aa-402e-4477-8f9c-0cdcca3426b6.

Steps to Reproduce:

resource "gridscale_mysql" "terra-mysql-test" {
  name              = "test"
  release           = "8.0"
  performance_class = "insane"
}

Additional Note: Creating the MySQL 8 PaaS instance via the gridscale panel works as expected.

Documentation Note: Additionally, the terraform provider documentation employs examples based on MySQL 5.7, which is now marked as inactive. The default mysql_sql_mode parameters contain NO_AUTO_CREATE_USER wich is not supported by version 8 anymore. However, removing it from the parameter list in terraform doesn't solve the issue.

nvthongswansea commented 9 months ago

@FloSchick Thank you for reporting the issue. I will check it asap.

ajfriesen commented 9 months ago

Thanks for reporting this.

We deprecated a few fields on our API because of changes for MySQL8. Will look into this.

ajfriesen commented 9 months ago

@FloSchick We just released a new provider v1.23.0 which has the resource type for gridscale_mysql8_0. There is also an example in the docs: https://registry.terraform.io/providers/gridscale/gridscale/latest/docs/resources/mysql8_0

FloSchick commented 9 months ago

@ajfriesen @nvthongswansea Tanks for the fast fix, works now as expected.