question

olimue avatar image
1 Vote"
olimue asked Prrudram-MSFT answered

maintenanceConfiguration list uses CamelCase and update uses snake_case for hourSlots

The question was already asked on GitHub, but I should move it here. So here we are.

If you run the command az aks maintenanceconfiguration list you 'll get back a configuration like this:

   {
     "id": "{someId}",
     "name": "default",
     "notAllowedTime": null,
     "resourceGroup": "{MyResource}",
     "systemData": null,
     "timeInWeek": [
       {
         "day": "Sunday",
         "hourSlots": [
           22,
           23
         ]
       }
     ],
     "type": null
   }

If you like to update a configuration by a file, the format must be:

 {
         "timeInWeek": [
           {
             "day": "Tuesday",
             "hour_slots": [
               1,
               2
             ]
           },
           {
             "day": "Wednesday",
             "hour_slots": [
               1,
               6
             ]
           }
         ],
         "notAllowedTime": [
           {
             "start": "2021-05-26T03:00:00Z",
             "end": "2021-05-30T12:00:00Z"
           }
         ]
 }

It really took me a few minutes to spot, why the update didn't take my hourSlots. The reason is, that the output uses camelCase and defines hourSlots, while the input file uses snake_case and defines hour_slots.

Instead the notAllowedTime property uses in both cases camelCase. So would be great if this would be done for hourSlots also.







azure-kubernetes-service
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Just ran into this issue as well, would be great if the docs reflected how the configuration actually works!

0 Votes 0 ·

Hello @olimue, @MarkWooff-8762,


Thanks a lot for the feedback on the configuration cases. It does look like a fair feedback and understand the confusion caused here.
I have already reported this to our product team and they are evaluating the proposed changes will revert back to you as soon as there is an update.

0 Votes 0 ·

1 Answer

Prrudram-MSFT avatar image
0 Votes"
Prrudram-MSFT answered

Hello @olimue, @MarkWooff-8762,

I am glad to inform that this is fixed. The fix is part of the AKS extension whose version is equal or later than 0.5.52.
Feel free to tag me in the comments in case if you face the same problem again.

Please "Accept as Answer" and Upvote if any of the above helped to help others in the community looking for remediation for similar issues.



5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.