mulesoft-anypoint / terraform-provider-anypoint

The Anypoint Platform Terraform Provider
https://registry.terraform.io/providers/mulesoft-anypoint/anypoint/latest
MIT License
12 stars 6 forks source link

Bug: Unable to read connected-app when attempting upgrade 1.5.6 -> 1.6.0 #38

Closed collins-benj closed 5 months ago

collins-benj commented 6 months ago

When attempting to upgrade provider version from 1.5.6 to 1.6, I get the following error on plan:

│ Error: Missing required argument
│
│   on main.tf line 61, in resource "anypoint_connected_app" "reader":
│   61: resource "anypoint_connected_app" "reader" {
│
│ The argument "org_id" is required, but no definition was found.

this much is clear to me; org_id indeed appears to be a new required parameter in 1.6 according to the docs.

However, when attempting to provide a value for such existing instance, no matter what I provide in the org_id parameter on my anypoint_connected_app, whether the id of the buisness group it has access to, the root bg of our org, which is just above that one, the team id where the owner is defined, (which I tried based on the phrasing in the docs: "The organization id where the connected app's owner is defined"), or just a blank value, I get:

│ Error: Unable to read connected-app (spits out the id here)
│
│   with anypoint_connected_app.reader,
│   on main.tf line 61, in resource "anypoint_connected_app" "reader":
│   61: resource "anypoint_connected_app" "reader" {
│
│ Not Found

I did notice that this change is not listed in "Important Breaking Changes" in the release notes for 1.6.0

soufi commented 6 months ago

Hi @collins-benj, Thank you for reporting this and apologies for the inconvenience, the breaking change wasn't listed in the release note indeed. I will look into this. Please keep in mind that this provider is only supported by me at the moment, I'm only doing this for the community on week-ends... Any help is much appreciated. Thank you for your patience.

soufi commented 5 months ago

Hello @collins-benj,

I just published a new release of the go connector here: https://github.com/mulesoft-anypoint/anypoint-client-go/releases/tag/connected_app%2Fv1.1.0

I will be publishing a fix.

Thank you.

soufi commented 5 months ago

solved in v1.6.1