-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
creating an APIM revision results in error message Can't change property ApiVersion for non-current revision #18093
Comments
Hello , first of all thanks to the entire terraform and the terraform azurerm provider teams for all of your great work and your hard work is truly appreciated by the community at large. Previously, this was working perfectly fine , eg, revisions were being created successfully using our existing swagger files. Then, I had to create a separate environment using our existing working terraform code base and then suddenly , we are getting this 400 error from the azurerm provider. Tested both in azurerm 2.84 and 3.17 with same HTTP 400 results In contrast, trying the same payload that was acquired from the terraform diagnostic log file in docs.micosoft.com (try button) results in a successful operation for both the base API and its ;rev-2 Please do take note that in both cases for the base API and revision=2, the same swagger file is being imported Thanks so much for your assistance! |
Update: Modifying the swagger file’s title and description fields under “info” property to be the same as the name, display name, description and path in the terraform file has resulted on a different error on another field From: Message="Can't change property Name for non-current revision" To: Message="Can't change property ApiVersion for non-current revision" │ Error: waiting on creating/updating API Management API "SampleApi" (Resource Group "rg-sample-api"): Future#WaitForCompletion: the number of retries has been exceeded: StatusCode=400 -- Original Error: Code="ValidationError" Message="Can't change property ApiVersion for non-current revision " │ any thoughts? Thanks! |
@jojoismael does working with revisions work for you now? I've noticed that with azurerm 3.17.0+ the revision in the state file is always set to "1", even so it's definitely configured with "2" etc. |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
I am trying to create a new revision an an existing APIM API, and still getting an error on
With the code:
Am I doing something wrong, or is it the case that #23031 didn't solve the issue? |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Is there an existing issue for this?
Community Note
Terraform Version
1.2.6
AzureRM Provider Version
2.84, 3.17.0
Affected Resource(s)/Data Source(s)
azurerm_api_management_api
Terraform Configuration Files
Debug Output/Panic Output
Expected Behaviour
APIM API revision to be created in Azure portal, as per previous behaviour
Actual Behaviour
HTTP 400 returned with message: Can't change property Name for non-current revision
Steps to Reproduce
TF_LOG="TRACE"
TF_LOG_PROVIDER="TRACE"
TF_LOG_PATH="c:\tmp\terraform.txt"
AzureRM v 2.84 and v.3.17.0 returns error 400: Can't change property Name for non-current revision
Next, copy PUT payload from terraform log file and submit via https://docs.microsoft.com/en-us/rest/api/apimanagement/current-ga/apis/create-or-update?tabs=HTTP#code-try-0
Important Factoids
No response
References
No response
The text was updated successfully, but these errors were encountered: