Azure-rest-api-specs: update aks encounter error when using user assigned identity

Created on 25 Mar 2021  路  8Comments  路  Source: Azure/azure-rest-api-specs

swagger link: https://github.com/Azure/azure-rest-api-specs/blob/HEAD/specification/containerservice/resource-manager/Microsoft.ContainerService/stable/2020-12-01/managedClusters.json#L416

reproduce step:

  1. create a cluster with user assigned identity
  2. get the cluster and change some property
  3. update

the error message:
Invalid value for the identities '/subscriptions/sub-id/resourceGroups/resource-group-name/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity-name'. The 'UserAssignedIdentities' property keys should only be empty json objects, null or the resource exisiting property."

after investigation, the reason is:
identity.UserAssignedIdentities is a map, the value is readonly struct. if the update rest api contains the readonly infomation, the backend will throw this error.

some times before, there was no such limitation.

Have checked with AKS team, they says there is no such error in their codebase.
needs check from ARM team

ARM ARM - Core Service Attention

Most helpful comment

Hi, looks like's it is (almost) the same issue as reported in https://github.com/Azure/azure-rest-api-specs/issues/13501
Hope there's a fix soon.

All 8 comments

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @armleads-azure.


Issue Details

swagger link: https://github.com/Azure/azure-rest-api-specs/blob/HEAD/specification/containerservice/resource-manager/Microsoft.ContainerService/stable/2020-12-01/managedClusters.json#L416

reproduce step:

  1. create a cluster with user assigned identity
  2. get the cluster and change some property
  3. update

the error message:
Invalid value for the identities '/subscriptions/sub-id/resourceGroups/resource-group-name/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity-name'. The 'UserAssignedIdentities' property keys should only be empty json objects, null or the resource exisiting property."

after investigation, the reason is:
identity.UserAssignedIdentities is a map, the value is readonly struct. if the update rest api contains the readonly infomation, the backend will throw this error.

some times before, there was no such limitation.

Have checked with AKS team, they says there is no such error in their codebase.
needs check from ARM team

Author: njuCZ
Assignees: -
Labels: `ARM - Core`, `Service Attention`, `needs-triage`
Milestone: -

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @armleads-azure.


Issue Details

swagger link: https://github.com/Azure/azure-rest-api-specs/blob/HEAD/specification/containerservice/resource-manager/Microsoft.ContainerService/stable/2020-12-01/managedClusters.json#L416

reproduce step:

  1. create a cluster with user assigned identity
  2. get the cluster and change some property
  3. update

the error message:
Invalid value for the identities '/subscriptions/sub-id/resourceGroups/resource-group-name/providers/Microsoft.ManagedIdentity/userAssignedIdentities/identity-name'. The 'UserAssignedIdentities' property keys should only be empty json objects, null or the resource exisiting property."

after investigation, the reason is:
identity.UserAssignedIdentities is a map, the value is readonly struct. if the update rest api contains the readonly infomation, the backend will throw this error.

some times before, there was no such limitation.

Have checked with AKS team, they says there is no such error in their codebase.
needs check from ARM team

Author: njuCZ
Assignees: ruowan, jianyexi
Labels: `ARM`, `ARM - Core`, `Service Attention`
Milestone: -

Hi. This issue has been impacting our ability to upgrade clusters for nearly 2 months now. Can you please respond soon?
cc @clarenceb

We are experiencing the same problem as OP

Hi, looks like's it is (almost) the same issue as reported in https://github.com/Azure/azure-rest-api-specs/issues/13501
Hope there's a fix soon.

i got the same error when using a user assigned identity and trying to update the aks cluster in the portal.

I opened a support issue in Azure and as of 04/15/2021 the problem is not reproducible any longer.

We still have this Issue :(

Was this page helpful?
0 / 5 - 0 ratings