azure_mgmt_container_service 0.18.5 → 0.20.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (359) hide show
  1. checksums.yaml +5 -5
  2. data/lib/2016-03-30/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  3. data/lib/2016-03-30/generated/azure_mgmt_container_service/container_services.rb +10 -0
  4. data/lib/2016-09-30/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  5. data/lib/2016-09-30/generated/azure_mgmt_container_service/container_services.rb +14 -0
  6. data/lib/2017-01-31/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  7. data/lib/2017-01-31/generated/azure_mgmt_container_service/container_services.rb +14 -0
  8. data/lib/2017-07-01/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  9. data/lib/2017-07-01/generated/azure_mgmt_container_service/container_services.rb +14 -0
  10. data/lib/2017-08-31/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  11. data/lib/2017-08-31/generated/azure_mgmt_container_service/managed_clusters.rb +20 -0
  12. data/lib/2017-09-30/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  13. data/lib/2017-09-30/generated/azure_mgmt_container_service/container_services.rb +2 -0
  14. data/lib/2018-03-31/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  15. data/lib/2018-03-31/generated/azure_mgmt_container_service/managed_clusters.rb +28 -0
  16. data/lib/2018-03-31/generated/azure_mgmt_container_service/operations.rb +2 -0
  17. data/lib/2018-08-01-preview/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  18. data/lib/2018-08-01-preview/generated/azure_mgmt_container_service/managed_clusters.rb +28 -0
  19. data/lib/2018-08-01-preview/generated/azure_mgmt_container_service/operations.rb +2 -0
  20. data/lib/2018-09-30-preview/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  21. data/lib/2018-09-30-preview/generated/azure_mgmt_container_service/open_shift_managed_clusters.rb +16 -0
  22. data/lib/2019-02-01/generated/azure_mgmt_container_service/agent_pools.rb +10 -0
  23. data/lib/2019-02-01/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  24. data/lib/2019-02-01/generated/azure_mgmt_container_service/managed_clusters.rb +28 -0
  25. data/lib/2019-02-01/generated/azure_mgmt_container_service/operations.rb +2 -0
  26. data/lib/2019-04-01/generated/azure_mgmt_container_service/agent_pools.rb +81 -76
  27. data/lib/2019-04-01/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  28. data/lib/2019-04-01/generated/azure_mgmt_container_service/container_services.rb +2 -0
  29. data/lib/2019-04-01/generated/azure_mgmt_container_service/managed_clusters.rb +58 -0
  30. data/lib/2019-04-01/generated/azure_mgmt_container_service/operations.rb +2 -0
  31. data/lib/2019-04-30/generated/azure_mgmt_container_service/container_service_client.rb +1 -1
  32. data/lib/2019-04-30/generated/azure_mgmt_container_service/open_shift_managed_clusters.rb +16 -0
  33. data/lib/2019-06-01/generated/azure_mgmt_container_service.rb +77 -0
  34. data/lib/2019-06-01/generated/azure_mgmt_container_service/agent_pools.rb +904 -0
  35. data/lib/2019-06-01/generated/azure_mgmt_container_service/container_service_client.rb +145 -0
  36. data/lib/2019-06-01/generated/azure_mgmt_container_service/container_services.rb +133 -0
  37. data/lib/2019-06-01/generated/azure_mgmt_container_service/managed_clusters.rb +1788 -0
  38. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/agent_pool.rb +344 -0
  39. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions.rb +93 -0
  40. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions_properties_agent_pool_versions_item.rb +71 -0
  41. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/agent_pool_list_result.rb +99 -0
  42. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/agent_pool_type.rb +16 -0
  43. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile.rb +117 -0
  44. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile_properties_upgrades_item.rb +59 -0
  45. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_diagnostics_profile.rb +48 -0
  46. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_linux_profile.rb +62 -0
  47. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_master_profile.rb +188 -0
  48. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_network_profile.rb +140 -0
  49. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_ssh_configuration.rb +57 -0
  50. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_ssh_public_key.rb +48 -0
  51. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_storage_profile_types.rb +16 -0
  52. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_vmdiagnostics.rb +60 -0
  53. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/container_service_vmsize_types.rb +188 -0
  54. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/credential_result.rb +59 -0
  55. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/credential_results.rb +57 -0
  56. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/load_balancer_sku.rb +16 -0
  57. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster.rb +325 -0
  58. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_aadprofile.rb +80 -0
  59. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_access_profile.rb +97 -0
  60. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_addon_profile.rb +66 -0
  61. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile.rb +211 -0
  62. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile_properties.rb +317 -0
  63. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_identity.rb +78 -0
  64. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_list_result.rb +100 -0
  65. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile.rb +92 -0
  66. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile_upgrades_item.rb +59 -0
  67. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_service_principal_profile.rb +59 -0
  68. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_upgrade_profile.rb +105 -0
  69. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/managed_cluster_windows_profile.rb +63 -0
  70. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/network_plugin.rb +16 -0
  71. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/network_policy.rb +16 -0
  72. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/operation_list_result.rb +56 -0
  73. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/operation_value.rb +108 -0
  74. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/orchestrator_profile.rb +68 -0
  75. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/orchestrator_version_profile.rb +100 -0
  76. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/orchestrator_version_profile_list_result.rb +92 -0
  77. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/ostype.rb +16 -0
  78. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/resource.rb +110 -0
  79. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/resource_identity_type.rb +16 -0
  80. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/scale_set_eviction_policy.rb +16 -0
  81. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/scale_set_priority.rb +16 -0
  82. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/sub_resource.rb +72 -0
  83. data/lib/2019-06-01/generated/azure_mgmt_container_service/models/tags_object.rb +54 -0
  84. data/lib/2019-06-01/generated/azure_mgmt_container_service/module_definition.rb +9 -0
  85. data/lib/2019-06-01/generated/azure_mgmt_container_service/operations.rb +109 -0
  86. data/lib/2019-08-01/generated/azure_mgmt_container_service.rb +83 -0
  87. data/lib/2019-08-01/generated/azure_mgmt_container_service/agent_pools.rb +904 -0
  88. data/lib/2019-08-01/generated/azure_mgmt_container_service/container_service_client.rb +145 -0
  89. data/lib/2019-08-01/generated/azure_mgmt_container_service/container_services.rb +133 -0
  90. data/lib/2019-08-01/generated/azure_mgmt_container_service/managed_clusters.rb +1788 -0
  91. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/agent_pool.rb +344 -0
  92. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions.rb +93 -0
  93. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions_properties_agent_pool_versions_item.rb +71 -0
  94. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/agent_pool_list_result.rb +99 -0
  95. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/agent_pool_type.rb +16 -0
  96. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile.rb +117 -0
  97. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile_properties_upgrades_item.rb +59 -0
  98. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_diagnostics_profile.rb +48 -0
  99. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_linux_profile.rb +62 -0
  100. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_master_profile.rb +188 -0
  101. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_network_profile.rb +153 -0
  102. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_ssh_configuration.rb +57 -0
  103. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_ssh_public_key.rb +48 -0
  104. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_storage_profile_types.rb +16 -0
  105. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_vmdiagnostics.rb +60 -0
  106. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/container_service_vmsize_types.rb +188 -0
  107. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/credential_result.rb +59 -0
  108. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/credential_results.rb +57 -0
  109. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/load_balancer_sku.rb +16 -0
  110. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster.rb +318 -0
  111. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_aadprofile.rb +80 -0
  112. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_access_profile.rb +97 -0
  113. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_addon_profile.rb +66 -0
  114. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile.rb +211 -0
  115. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile_properties.rb +317 -0
  116. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_apiserver_access_profile.rb +66 -0
  117. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_identity.rb +78 -0
  118. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_list_result.rb +100 -0
  119. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile.rb +95 -0
  120. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_managed_outbound_ips.rb +55 -0
  121. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ipprefixes.rb +57 -0
  122. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ips.rb +56 -0
  123. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile.rb +92 -0
  124. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile_upgrades_item.rb +59 -0
  125. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_service_principal_profile.rb +59 -0
  126. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_upgrade_profile.rb +105 -0
  127. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/managed_cluster_windows_profile.rb +63 -0
  128. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/network_plugin.rb +16 -0
  129. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/network_policy.rb +16 -0
  130. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/operation_list_result.rb +56 -0
  131. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/operation_value.rb +108 -0
  132. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/orchestrator_profile.rb +68 -0
  133. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/orchestrator_version_profile.rb +100 -0
  134. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/orchestrator_version_profile_list_result.rb +92 -0
  135. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/ostype.rb +16 -0
  136. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/resource.rb +110 -0
  137. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/resource_identity_type.rb +16 -0
  138. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/resource_reference.rb +46 -0
  139. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/scale_set_eviction_policy.rb +16 -0
  140. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/scale_set_priority.rb +16 -0
  141. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/sub_resource.rb +72 -0
  142. data/lib/2019-08-01/generated/azure_mgmt_container_service/models/tags_object.rb +54 -0
  143. data/lib/2019-08-01/generated/azure_mgmt_container_service/module_definition.rb +9 -0
  144. data/lib/2019-08-01/generated/azure_mgmt_container_service/operations.rb +109 -0
  145. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service.rb +45 -0
  146. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/container_service_client.rb +133 -0
  147. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/network_profile.rb +70 -0
  148. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_agent_pool_profile_role.rb +16 -0
  149. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_container_service_vmsize.rb +47 -0
  150. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster.rb +255 -0
  151. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_aadidentity_provider.rb +95 -0
  152. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_agent_pool_profile.rb +119 -0
  153. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_auth_profile.rb +56 -0
  154. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_base_identity_provider.rb +47 -0
  155. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_identity_provider.rb +62 -0
  156. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_list_result.rb +101 -0
  157. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_master_pool_profile.rb +107 -0
  158. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_managed_cluster_monitor_profile.rb +59 -0
  159. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/open_shift_router_profile.rb +70 -0
  160. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/ostype.rb +16 -0
  161. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/purchase_plan.rb +82 -0
  162. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/resource.rb +110 -0
  163. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/models/tags_object.rb +54 -0
  164. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/module_definition.rb +9 -0
  165. data/lib/2019-09-30-preview/generated/azure_mgmt_container_service/open_shift_managed_clusters.rb +1068 -0
  166. data/lib/2019-10-01/generated/azure_mgmt_container_service.rb +79 -0
  167. data/lib/2019-10-01/generated/azure_mgmt_container_service/agent_pools.rb +900 -0
  168. data/lib/2019-10-01/generated/azure_mgmt_container_service/container_service_client.rb +141 -0
  169. data/lib/2019-10-01/generated/azure_mgmt_container_service/managed_clusters.rb +1921 -0
  170. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/agent_pool.rb +344 -0
  171. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions.rb +93 -0
  172. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions_properties_agent_pool_versions_item.rb +71 -0
  173. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/agent_pool_list_result.rb +99 -0
  174. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/agent_pool_type.rb +16 -0
  175. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile.rb +117 -0
  176. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile_properties_upgrades_item.rb +59 -0
  177. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_diagnostics_profile.rb +48 -0
  178. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_linux_profile.rb +62 -0
  179. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_master_profile.rb +188 -0
  180. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_network_profile.rb +153 -0
  181. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_ssh_configuration.rb +57 -0
  182. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_ssh_public_key.rb +48 -0
  183. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_storage_profile_types.rb +16 -0
  184. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_vmdiagnostics.rb +60 -0
  185. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/container_service_vmsize_types.rb +188 -0
  186. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/credential_result.rb +59 -0
  187. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/credential_results.rb +57 -0
  188. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/load_balancer_sku.rb +16 -0
  189. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster.rb +330 -0
  190. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_aadprofile.rb +80 -0
  191. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_access_profile.rb +97 -0
  192. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_addon_profile.rb +66 -0
  193. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile.rb +211 -0
  194. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile_properties.rb +317 -0
  195. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_apiserver_access_profile.rb +66 -0
  196. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_identity.rb +78 -0
  197. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_list_result.rb +100 -0
  198. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile.rb +95 -0
  199. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_managed_outbound_ips.rb +55 -0
  200. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ipprefixes.rb +57 -0
  201. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ips.rb +56 -0
  202. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile.rb +92 -0
  203. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile_upgrades_item.rb +59 -0
  204. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_service_principal_profile.rb +59 -0
  205. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_upgrade_profile.rb +105 -0
  206. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/managed_cluster_windows_profile.rb +63 -0
  207. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/network_plugin.rb +16 -0
  208. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/network_policy.rb +16 -0
  209. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/operation_list_result.rb +56 -0
  210. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/operation_value.rb +108 -0
  211. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/ostype.rb +16 -0
  212. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/resource.rb +110 -0
  213. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/resource_identity_type.rb +16 -0
  214. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/resource_reference.rb +46 -0
  215. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/scale_set_eviction_policy.rb +16 -0
  216. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/scale_set_priority.rb +16 -0
  217. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/sub_resource.rb +72 -0
  218. data/lib/2019-10-01/generated/azure_mgmt_container_service/models/tags_object.rb +54 -0
  219. data/lib/2019-10-01/generated/azure_mgmt_container_service/module_definition.rb +9 -0
  220. data/lib/2019-10-01/generated/azure_mgmt_container_service/operations.rb +109 -0
  221. data/lib/2020-02-01/generated/azure_mgmt_container_service.rb +85 -0
  222. data/lib/2020-02-01/generated/azure_mgmt_container_service/agent_pools.rb +900 -0
  223. data/lib/2020-02-01/generated/azure_mgmt_container_service/container_service_client.rb +141 -0
  224. data/lib/2020-02-01/generated/azure_mgmt_container_service/managed_clusters.rb +2028 -0
  225. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/agent_pool.rb +398 -0
  226. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions.rb +93 -0
  227. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions_properties_agent_pool_versions_item.rb +71 -0
  228. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/agent_pool_list_result.rb +99 -0
  229. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/agent_pool_type.rb +16 -0
  230. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile.rb +117 -0
  231. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile_properties_upgrades_item.rb +59 -0
  232. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_diagnostics_profile.rb +48 -0
  233. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_linux_profile.rb +62 -0
  234. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_master_profile.rb +188 -0
  235. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_network_profile.rb +179 -0
  236. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_ssh_configuration.rb +57 -0
  237. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_ssh_public_key.rb +48 -0
  238. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_storage_profile_types.rb +16 -0
  239. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_vmdiagnostics.rb +60 -0
  240. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/container_service_vmsize_types.rb +188 -0
  241. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/credential_result.rb +59 -0
  242. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/credential_results.rb +57 -0
  243. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/load_balancer_sku.rb +16 -0
  244. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster.rb +376 -0
  245. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_aadprofile.rb +80 -0
  246. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_access_profile.rb +97 -0
  247. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_addon_profile.rb +80 -0
  248. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_addon_profile_identity.rb +59 -0
  249. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile.rb +251 -0
  250. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile_properties.rb +371 -0
  251. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_apiserver_access_profile.rb +66 -0
  252. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_identity.rb +78 -0
  253. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_list_result.rb +100 -0
  254. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile.rb +132 -0
  255. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_managed_outbound_ips.rb +55 -0
  256. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ipprefixes.rb +57 -0
  257. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ips.rb +56 -0
  258. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile.rb +92 -0
  259. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile_upgrades_item.rb +59 -0
  260. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_properties_auto_scaler_profile.rb +124 -0
  261. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_properties_identity_profile_value.rb +61 -0
  262. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_service_principal_profile.rb +59 -0
  263. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_upgrade_profile.rb +105 -0
  264. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/managed_cluster_windows_profile.rb +63 -0
  265. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/network_mode.rb +16 -0
  266. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/network_plugin.rb +16 -0
  267. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/network_policy.rb +16 -0
  268. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/operation_list_result.rb +56 -0
  269. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/operation_value.rb +108 -0
  270. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/ostype.rb +16 -0
  271. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/outbound_type.rb +16 -0
  272. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/resource.rb +110 -0
  273. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/resource_identity_type.rb +16 -0
  274. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/resource_reference.rb +46 -0
  275. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/scale_set_eviction_policy.rb +16 -0
  276. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/scale_set_priority.rb +17 -0
  277. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/sub_resource.rb +72 -0
  278. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/tags_object.rb +54 -0
  279. data/lib/2020-02-01/generated/azure_mgmt_container_service/models/user_assigned_identity.rb +69 -0
  280. data/lib/2020-02-01/generated/azure_mgmt_container_service/module_definition.rb +9 -0
  281. data/lib/2020-02-01/generated/azure_mgmt_container_service/operations.rb +109 -0
  282. data/lib/2020-06-01/generated/azure_mgmt_container_service.rb +98 -0
  283. data/lib/2020-06-01/generated/azure_mgmt_container_service/agent_pools.rb +900 -0
  284. data/lib/2020-06-01/generated/azure_mgmt_container_service/container_service_client.rb +145 -0
  285. data/lib/2020-06-01/generated/azure_mgmt_container_service/managed_clusters.rb +2043 -0
  286. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool.rb +440 -0
  287. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions.rb +93 -0
  288. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_available_versions_properties_agent_pool_versions_item.rb +71 -0
  289. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_list_result.rb +99 -0
  290. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_mode.rb +16 -0
  291. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_type.rb +16 -0
  292. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile.rb +129 -0
  293. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_profile_properties_upgrades_item.rb +59 -0
  294. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/agent_pool_upgrade_settings.rb +47 -0
  295. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/connection_status.rb +18 -0
  296. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_diagnostics_profile.rb +48 -0
  297. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_linux_profile.rb +62 -0
  298. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_master_profile.rb +188 -0
  299. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_network_profile.rb +179 -0
  300. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_ssh_configuration.rb +57 -0
  301. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_ssh_public_key.rb +48 -0
  302. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_storage_profile_types.rb +16 -0
  303. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_vmdiagnostics.rb +60 -0
  304. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/container_service_vmsize_types.rb +188 -0
  305. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/credential_result.rb +59 -0
  306. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/credential_results.rb +57 -0
  307. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/load_balancer_sku.rb +16 -0
  308. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster.rb +388 -0
  309. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_aadprofile.rb +123 -0
  310. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_access_profile.rb +97 -0
  311. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_addon_profile.rb +80 -0
  312. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_addon_profile_identity.rb +59 -0
  313. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile.rb +279 -0
  314. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_agent_pool_profile_properties.rb +413 -0
  315. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_apiserver_access_profile.rb +66 -0
  316. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_identity.rb +104 -0
  317. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_identity_user_assigned_identities_value.rb +61 -0
  318. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_list_result.rb +100 -0
  319. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile.rb +132 -0
  320. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_managed_outbound_ips.rb +55 -0
  321. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ipprefixes.rb +57 -0
  322. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_load_balancer_profile_outbound_ips.rb +56 -0
  323. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile.rb +92 -0
  324. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_pool_upgrade_profile_upgrades_item.rb +59 -0
  325. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_properties_auto_scaler_profile.rb +135 -0
  326. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_properties_identity_profile_value.rb +61 -0
  327. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_service_principal_profile.rb +59 -0
  328. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_sku.rb +60 -0
  329. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_skuname.rb +15 -0
  330. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_skutier.rb +16 -0
  331. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_upgrade_profile.rb +105 -0
  332. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/managed_cluster_windows_profile.rb +63 -0
  333. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/network_mode.rb +16 -0
  334. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/network_plugin.rb +16 -0
  335. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/network_policy.rb +16 -0
  336. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/operation_list_result.rb +56 -0
  337. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/operation_value.rb +108 -0
  338. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/ostype.rb +16 -0
  339. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/outbound_type.rb +16 -0
  340. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/private_endpoint.rb +46 -0
  341. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/private_endpoint_connection.rb +111 -0
  342. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/private_endpoint_connection_list_result.rb +55 -0
  343. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/private_endpoint_connection_provisioning_state.rb +18 -0
  344. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/private_link_service_connection_state.rb +59 -0
  345. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/resource.rb +110 -0
  346. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/resource_identity_type.rb +17 -0
  347. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/resource_reference.rb +46 -0
  348. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/scale_set_eviction_policy.rb +16 -0
  349. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/scale_set_priority.rb +16 -0
  350. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/sub_resource.rb +72 -0
  351. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/tags_object.rb +54 -0
  352. data/lib/2020-06-01/generated/azure_mgmt_container_service/models/user_assigned_identity.rb +69 -0
  353. data/lib/2020-06-01/generated/azure_mgmt_container_service/module_definition.rb +9 -0
  354. data/lib/2020-06-01/generated/azure_mgmt_container_service/operations.rb +109 -0
  355. data/lib/2020-06-01/generated/azure_mgmt_container_service/private_endpoint_connections.rb +515 -0
  356. data/lib/azure_mgmt_container_service.rb +13 -7
  357. data/lib/profiles/latest/modules/containerservice_profile_module.rb +284 -146
  358. data/lib/version.rb +1 -1
  359. metadata +328 -5
@@ -0,0 +1,141 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::ContainerService::Mgmt::V2019_10_01
7
+ #
8
+ # A service client - single point of access to the REST API.
9
+ #
10
+ class ContainerServiceClient < MsRestAzure::AzureServiceClient
11
+ include MsRestAzure
12
+ include MsRestAzure::Serialization
13
+
14
+ # @return [String] the base URI of the service.
15
+ attr_accessor :base_url
16
+
17
+ # @return Credentials needed for the client to connect to Azure.
18
+ attr_reader :credentials
19
+
20
+ # @return [String] Subscription credentials which uniquely identify
21
+ # Microsoft Azure subscription. The subscription ID forms part of the URI
22
+ # for every service call.
23
+ attr_accessor :subscription_id
24
+
25
+ # @return [String] Client Api Version.
26
+ attr_reader :api_version
27
+
28
+ # @return [String] The preferred language for the response.
29
+ attr_accessor :accept_language
30
+
31
+ # @return [Integer] The retry timeout in seconds for Long Running
32
+ # Operations. Default value is 30.
33
+ attr_accessor :long_running_operation_retry_timeout
34
+
35
+ # @return [Boolean] Whether a unique x-ms-client-request-id should be
36
+ # generated. When set to true a unique x-ms-client-request-id value is
37
+ # generated and included in each request. Default is true.
38
+ attr_accessor :generate_client_request_id
39
+
40
+ # @return [Operations] operations
41
+ attr_reader :operations
42
+
43
+ # @return [ManagedClusters] managed_clusters
44
+ attr_reader :managed_clusters
45
+
46
+ # @return [AgentPools] agent_pools
47
+ attr_reader :agent_pools
48
+
49
+ #
50
+ # Creates initializes a new instance of the ContainerServiceClient class.
51
+ # @param credentials [MsRest::ServiceClientCredentials] credentials to authorize HTTP requests made by the service client.
52
+ # @param base_url [String] the base URI of the service.
53
+ # @param options [Array] filters to be applied to the HTTP requests.
54
+ #
55
+ def initialize(credentials = nil, base_url = nil, options = nil)
56
+ super(credentials, options)
57
+ @base_url = base_url || 'https://management.azure.com'
58
+
59
+ fail ArgumentError, 'invalid type of credentials input parameter' unless credentials.is_a?(MsRest::ServiceClientCredentials) unless credentials.nil?
60
+ @credentials = credentials
61
+
62
+ @operations = Operations.new(self)
63
+ @managed_clusters = ManagedClusters.new(self)
64
+ @agent_pools = AgentPools.new(self)
65
+ @api_version = '2019-10-01'
66
+ @accept_language = 'en-US'
67
+ @long_running_operation_retry_timeout = 30
68
+ @generate_client_request_id = true
69
+ add_telemetry
70
+ end
71
+
72
+ #
73
+ # Makes a request and returns the body of the response.
74
+ # @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
75
+ # @param path [String] the path, relative to {base_url}.
76
+ # @param options [Hash{String=>String}] specifying any request options like :body.
77
+ # @return [Hash{String=>String}] containing the body of the response.
78
+ # Example:
79
+ #
80
+ # request_content = "{'location':'westus','tags':{'tag1':'val1','tag2':'val2'}}"
81
+ # path = "/path"
82
+ # options = {
83
+ # body: request_content,
84
+ # query_params: {'api-version' => '2016-02-01'}
85
+ # }
86
+ # result = @client.make_request(:put, path, options)
87
+ #
88
+ def make_request(method, path, options = {})
89
+ result = make_request_with_http_info(method, path, options)
90
+ result.body unless result.nil?
91
+ end
92
+
93
+ #
94
+ # Makes a request and returns the operation response.
95
+ # @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
96
+ # @param path [String] the path, relative to {base_url}.
97
+ # @param options [Hash{String=>String}] specifying any request options like :body.
98
+ # @return [MsRestAzure::AzureOperationResponse] Operation response containing the request, response and status.
99
+ #
100
+ def make_request_with_http_info(method, path, options = {})
101
+ result = make_request_async(method, path, options).value!
102
+ result.body = result.response.body.to_s.empty? ? nil : JSON.load(result.response.body)
103
+ result
104
+ end
105
+
106
+ #
107
+ # Makes a request asynchronously.
108
+ # @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
109
+ # @param path [String] the path, relative to {base_url}.
110
+ # @param options [Hash{String=>String}] specifying any request options like :body.
111
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
112
+ #
113
+ def make_request_async(method, path, options = {})
114
+ fail ArgumentError, 'method is nil' if method.nil?
115
+ fail ArgumentError, 'path is nil' if path.nil?
116
+
117
+ request_url = options[:base_url] || @base_url
118
+ if(!options[:headers].nil? && !options[:headers]['Content-Type'].nil?)
119
+ @request_headers['Content-Type'] = options[:headers]['Content-Type']
120
+ end
121
+
122
+ request_headers = @request_headers
123
+ request_headers.merge!({'accept-language' => @accept_language}) unless @accept_language.nil?
124
+ options.merge!({headers: request_headers.merge(options[:headers] || {})})
125
+ options.merge!({credentials: @credentials}) unless @credentials.nil?
126
+
127
+ super(request_url, method, path, options)
128
+ end
129
+
130
+
131
+ private
132
+ #
133
+ # Adds telemetry information.
134
+ #
135
+ def add_telemetry
136
+ sdk_information = 'azure_mgmt_container_service'
137
+ sdk_information = "#{sdk_information}/0.20.3"
138
+ add_user_agent_information(sdk_information)
139
+ end
140
+ end
141
+ end
@@ -0,0 +1,1921 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::ContainerService::Mgmt::V2019_10_01
7
+ #
8
+ # The Container Service Client.
9
+ #
10
+ class ManagedClusters
11
+ include MsRestAzure
12
+
13
+ #
14
+ # Creates and initializes a new instance of the ManagedClusters class.
15
+ # @param client service class for accessing basic functionality.
16
+ #
17
+ def initialize(client)
18
+ @client = client
19
+ end
20
+
21
+ # @return [ContainerServiceClient] reference to the ContainerServiceClient
22
+ attr_reader :client
23
+
24
+ #
25
+ # Gets a list of managed clusters in the specified subscription.
26
+ #
27
+ # Gets a list of managed clusters in the specified subscription. The operation
28
+ # returns properties of each managed cluster.
29
+ #
30
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
31
+ # will be added to the HTTP request.
32
+ #
33
+ # @return [Array<ManagedCluster>] operation results.
34
+ #
35
+ def list(custom_headers:nil)
36
+ first_page = list_as_lazy(custom_headers:custom_headers)
37
+ first_page.get_all_items
38
+ end
39
+
40
+ #
41
+ # Gets a list of managed clusters in the specified subscription.
42
+ #
43
+ # Gets a list of managed clusters in the specified subscription. The operation
44
+ # returns properties of each managed cluster.
45
+ #
46
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
47
+ # will be added to the HTTP request.
48
+ #
49
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
50
+ #
51
+ def list_with_http_info(custom_headers:nil)
52
+ list_async(custom_headers:custom_headers).value!
53
+ end
54
+
55
+ #
56
+ # Gets a list of managed clusters in the specified subscription.
57
+ #
58
+ # Gets a list of managed clusters in the specified subscription. The operation
59
+ # returns properties of each managed cluster.
60
+ #
61
+ # @param [Hash{String => String}] A hash of custom headers that will be added
62
+ # to the HTTP request.
63
+ #
64
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
65
+ #
66
+ def list_async(custom_headers:nil)
67
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
68
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
69
+
70
+
71
+ request_headers = {}
72
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
73
+
74
+ # Set Headers
75
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
76
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
77
+ path_template = 'subscriptions/{subscriptionId}/providers/Microsoft.ContainerService/managedClusters'
78
+
79
+ request_url = @base_url || @client.base_url
80
+
81
+ options = {
82
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
83
+ path_params: {'subscriptionId' => @client.subscription_id},
84
+ query_params: {'api-version' => @client.api_version},
85
+ headers: request_headers.merge(custom_headers || {}),
86
+ base_url: request_url
87
+ }
88
+ promise = @client.make_request_async(:get, path_template, options)
89
+
90
+ promise = promise.then do |result|
91
+ http_response = result.response
92
+ status_code = http_response.status
93
+ response_content = http_response.body
94
+ unless status_code == 200
95
+ error_model = JSON.load(response_content)
96
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
97
+ end
98
+
99
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
100
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
101
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
102
+ # Deserialize Response
103
+ if status_code == 200
104
+ begin
105
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
106
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterListResult.mapper()
107
+ result.body = @client.deserialize(result_mapper, parsed_response)
108
+ rescue Exception => e
109
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
110
+ end
111
+ end
112
+
113
+ result
114
+ end
115
+
116
+ promise.execute
117
+ end
118
+
119
+ #
120
+ # Lists managed clusters in the specified subscription and resource group.
121
+ #
122
+ # Lists managed clusters in the specified subscription and resource group. The
123
+ # operation returns properties of each managed cluster.
124
+ #
125
+ # @param resource_group_name [String] The name of the resource group.
126
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
127
+ # will be added to the HTTP request.
128
+ #
129
+ # @return [Array<ManagedCluster>] operation results.
130
+ #
131
+ def list_by_resource_group(resource_group_name, custom_headers:nil)
132
+ first_page = list_by_resource_group_as_lazy(resource_group_name, custom_headers:custom_headers)
133
+ first_page.get_all_items
134
+ end
135
+
136
+ #
137
+ # Lists managed clusters in the specified subscription and resource group.
138
+ #
139
+ # Lists managed clusters in the specified subscription and resource group. The
140
+ # operation returns properties of each managed cluster.
141
+ #
142
+ # @param resource_group_name [String] The name of the resource group.
143
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
144
+ # will be added to the HTTP request.
145
+ #
146
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
147
+ #
148
+ def list_by_resource_group_with_http_info(resource_group_name, custom_headers:nil)
149
+ list_by_resource_group_async(resource_group_name, custom_headers:custom_headers).value!
150
+ end
151
+
152
+ #
153
+ # Lists managed clusters in the specified subscription and resource group.
154
+ #
155
+ # Lists managed clusters in the specified subscription and resource group. The
156
+ # operation returns properties of each managed cluster.
157
+ #
158
+ # @param resource_group_name [String] The name of the resource group.
159
+ # @param [Hash{String => String}] A hash of custom headers that will be added
160
+ # to the HTTP request.
161
+ #
162
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
163
+ #
164
+ def list_by_resource_group_async(resource_group_name, custom_headers:nil)
165
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
166
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
167
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
168
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
169
+
170
+
171
+ request_headers = {}
172
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
173
+
174
+ # Set Headers
175
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
176
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
177
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters'
178
+
179
+ request_url = @base_url || @client.base_url
180
+
181
+ options = {
182
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
183
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name},
184
+ query_params: {'api-version' => @client.api_version},
185
+ headers: request_headers.merge(custom_headers || {}),
186
+ base_url: request_url
187
+ }
188
+ promise = @client.make_request_async(:get, path_template, options)
189
+
190
+ promise = promise.then do |result|
191
+ http_response = result.response
192
+ status_code = http_response.status
193
+ response_content = http_response.body
194
+ unless status_code == 200
195
+ error_model = JSON.load(response_content)
196
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
197
+ end
198
+
199
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
200
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
201
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
202
+ # Deserialize Response
203
+ if status_code == 200
204
+ begin
205
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
206
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterListResult.mapper()
207
+ result.body = @client.deserialize(result_mapper, parsed_response)
208
+ rescue Exception => e
209
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
210
+ end
211
+ end
212
+
213
+ result
214
+ end
215
+
216
+ promise.execute
217
+ end
218
+
219
+ #
220
+ # Gets upgrade profile for a managed cluster.
221
+ #
222
+ # Gets the details of the upgrade profile for a managed cluster with a
223
+ # specified resource group and name.
224
+ #
225
+ # @param resource_group_name [String] The name of the resource group.
226
+ # @param resource_name [String] The name of the managed cluster resource.
227
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
228
+ # will be added to the HTTP request.
229
+ #
230
+ # @return [ManagedClusterUpgradeProfile] operation results.
231
+ #
232
+ def get_upgrade_profile(resource_group_name, resource_name, custom_headers:nil)
233
+ response = get_upgrade_profile_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
234
+ response.body unless response.nil?
235
+ end
236
+
237
+ #
238
+ # Gets upgrade profile for a managed cluster.
239
+ #
240
+ # Gets the details of the upgrade profile for a managed cluster with a
241
+ # specified resource group and name.
242
+ #
243
+ # @param resource_group_name [String] The name of the resource group.
244
+ # @param resource_name [String] The name of the managed cluster resource.
245
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
246
+ # will be added to the HTTP request.
247
+ #
248
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
249
+ #
250
+ def get_upgrade_profile_with_http_info(resource_group_name, resource_name, custom_headers:nil)
251
+ get_upgrade_profile_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
252
+ end
253
+
254
+ #
255
+ # Gets upgrade profile for a managed cluster.
256
+ #
257
+ # Gets the details of the upgrade profile for a managed cluster with a
258
+ # specified resource group and name.
259
+ #
260
+ # @param resource_group_name [String] The name of the resource group.
261
+ # @param resource_name [String] The name of the managed cluster resource.
262
+ # @param [Hash{String => String}] A hash of custom headers that will be added
263
+ # to the HTTP request.
264
+ #
265
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
266
+ #
267
+ def get_upgrade_profile_async(resource_group_name, resource_name, custom_headers:nil)
268
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
269
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
270
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
271
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
272
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
273
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
274
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
275
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
276
+
277
+
278
+ request_headers = {}
279
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
280
+
281
+ # Set Headers
282
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
283
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
284
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/upgradeProfiles/default'
285
+
286
+ request_url = @base_url || @client.base_url
287
+
288
+ options = {
289
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
290
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
291
+ query_params: {'api-version' => @client.api_version},
292
+ headers: request_headers.merge(custom_headers || {}),
293
+ base_url: request_url
294
+ }
295
+ promise = @client.make_request_async(:get, path_template, options)
296
+
297
+ promise = promise.then do |result|
298
+ http_response = result.response
299
+ status_code = http_response.status
300
+ response_content = http_response.body
301
+ unless status_code == 200
302
+ error_model = JSON.load(response_content)
303
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
304
+ end
305
+
306
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
307
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
308
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
309
+ # Deserialize Response
310
+ if status_code == 200
311
+ begin
312
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
313
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterUpgradeProfile.mapper()
314
+ result.body = @client.deserialize(result_mapper, parsed_response)
315
+ rescue Exception => e
316
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
317
+ end
318
+ end
319
+
320
+ result
321
+ end
322
+
323
+ promise.execute
324
+ end
325
+
326
+ #
327
+ # Gets an access profile of a managed cluster.
328
+ #
329
+ # Gets the accessProfile for the specified role name of the managed cluster
330
+ # with a specified resource group and name.
331
+ #
332
+ # @param resource_group_name [String] The name of the resource group.
333
+ # @param resource_name [String] The name of the managed cluster resource.
334
+ # @param role_name [String] The name of the role for managed cluster
335
+ # accessProfile resource.
336
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
337
+ # will be added to the HTTP request.
338
+ #
339
+ # @return [ManagedClusterAccessProfile] operation results.
340
+ #
341
+ def get_access_profile(resource_group_name, resource_name, role_name, custom_headers:nil)
342
+ response = get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers:custom_headers).value!
343
+ response.body unless response.nil?
344
+ end
345
+
346
+ #
347
+ # Gets an access profile of a managed cluster.
348
+ #
349
+ # Gets the accessProfile for the specified role name of the managed cluster
350
+ # with a specified resource group and name.
351
+ #
352
+ # @param resource_group_name [String] The name of the resource group.
353
+ # @param resource_name [String] The name of the managed cluster resource.
354
+ # @param role_name [String] The name of the role for managed cluster
355
+ # accessProfile resource.
356
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
357
+ # will be added to the HTTP request.
358
+ #
359
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
360
+ #
361
+ def get_access_profile_with_http_info(resource_group_name, resource_name, role_name, custom_headers:nil)
362
+ get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers:custom_headers).value!
363
+ end
364
+
365
+ #
366
+ # Gets an access profile of a managed cluster.
367
+ #
368
+ # Gets the accessProfile for the specified role name of the managed cluster
369
+ # with a specified resource group and name.
370
+ #
371
+ # @param resource_group_name [String] The name of the resource group.
372
+ # @param resource_name [String] The name of the managed cluster resource.
373
+ # @param role_name [String] The name of the role for managed cluster
374
+ # accessProfile resource.
375
+ # @param [Hash{String => String}] A hash of custom headers that will be added
376
+ # to the HTTP request.
377
+ #
378
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
379
+ #
380
+ def get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers:nil)
381
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
382
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
383
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
384
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
385
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
386
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
387
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
388
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
389
+ fail ArgumentError, 'role_name is nil' if role_name.nil?
390
+
391
+
392
+ request_headers = {}
393
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
394
+
395
+ # Set Headers
396
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
397
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
398
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/accessProfiles/{roleName}/listCredential'
399
+
400
+ request_url = @base_url || @client.base_url
401
+
402
+ options = {
403
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
404
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name,'roleName' => role_name},
405
+ query_params: {'api-version' => @client.api_version},
406
+ headers: request_headers.merge(custom_headers || {}),
407
+ base_url: request_url
408
+ }
409
+ promise = @client.make_request_async(:post, path_template, options)
410
+
411
+ promise = promise.then do |result|
412
+ http_response = result.response
413
+ status_code = http_response.status
414
+ response_content = http_response.body
415
+ unless status_code == 200
416
+ error_model = JSON.load(response_content)
417
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
418
+ end
419
+
420
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
421
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
422
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
423
+ # Deserialize Response
424
+ if status_code == 200
425
+ begin
426
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
427
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterAccessProfile.mapper()
428
+ result.body = @client.deserialize(result_mapper, parsed_response)
429
+ rescue Exception => e
430
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
431
+ end
432
+ end
433
+
434
+ result
435
+ end
436
+
437
+ promise.execute
438
+ end
439
+
440
+ #
441
+ # Gets cluster admin credential of a managed cluster.
442
+ #
443
+ # Gets cluster admin credential of the managed cluster with a specified
444
+ # resource group and name.
445
+ #
446
+ # @param resource_group_name [String] The name of the resource group.
447
+ # @param resource_name [String] The name of the managed cluster resource.
448
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
449
+ # will be added to the HTTP request.
450
+ #
451
+ # @return [CredentialResults] operation results.
452
+ #
453
+ def list_cluster_admin_credentials(resource_group_name, resource_name, custom_headers:nil)
454
+ response = list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
455
+ response.body unless response.nil?
456
+ end
457
+
458
+ #
459
+ # Gets cluster admin credential of a managed cluster.
460
+ #
461
+ # Gets cluster admin credential of the managed cluster with a specified
462
+ # resource group and name.
463
+ #
464
+ # @param resource_group_name [String] The name of the resource group.
465
+ # @param resource_name [String] The name of the managed cluster resource.
466
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
467
+ # will be added to the HTTP request.
468
+ #
469
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
470
+ #
471
+ def list_cluster_admin_credentials_with_http_info(resource_group_name, resource_name, custom_headers:nil)
472
+ list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
473
+ end
474
+
475
+ #
476
+ # Gets cluster admin credential of a managed cluster.
477
+ #
478
+ # Gets cluster admin credential of the managed cluster with a specified
479
+ # resource group and name.
480
+ #
481
+ # @param resource_group_name [String] The name of the resource group.
482
+ # @param resource_name [String] The name of the managed cluster resource.
483
+ # @param [Hash{String => String}] A hash of custom headers that will be added
484
+ # to the HTTP request.
485
+ #
486
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
487
+ #
488
+ def list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers:nil)
489
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
490
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
491
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
492
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
493
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
494
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
495
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
496
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
497
+
498
+
499
+ request_headers = {}
500
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
501
+
502
+ # Set Headers
503
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
504
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
505
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/listClusterAdminCredential'
506
+
507
+ request_url = @base_url || @client.base_url
508
+
509
+ options = {
510
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
511
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
512
+ query_params: {'api-version' => @client.api_version},
513
+ headers: request_headers.merge(custom_headers || {}),
514
+ base_url: request_url
515
+ }
516
+ promise = @client.make_request_async(:post, path_template, options)
517
+
518
+ promise = promise.then do |result|
519
+ http_response = result.response
520
+ status_code = http_response.status
521
+ response_content = http_response.body
522
+ unless status_code == 200
523
+ error_model = JSON.load(response_content)
524
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
525
+ end
526
+
527
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
528
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
529
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
530
+ # Deserialize Response
531
+ if status_code == 200
532
+ begin
533
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
534
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::CredentialResults.mapper()
535
+ result.body = @client.deserialize(result_mapper, parsed_response)
536
+ rescue Exception => e
537
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
538
+ end
539
+ end
540
+
541
+ result
542
+ end
543
+
544
+ promise.execute
545
+ end
546
+
547
+ #
548
+ # Gets cluster user credential of a managed cluster.
549
+ #
550
+ # Gets cluster user credential of the managed cluster with a specified resource
551
+ # group and name.
552
+ #
553
+ # @param resource_group_name [String] The name of the resource group.
554
+ # @param resource_name [String] The name of the managed cluster resource.
555
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
556
+ # will be added to the HTTP request.
557
+ #
558
+ # @return [CredentialResults] operation results.
559
+ #
560
+ def list_cluster_user_credentials(resource_group_name, resource_name, custom_headers:nil)
561
+ response = list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
562
+ response.body unless response.nil?
563
+ end
564
+
565
+ #
566
+ # Gets cluster user credential of a managed cluster.
567
+ #
568
+ # Gets cluster user credential of the managed cluster with a specified resource
569
+ # group and name.
570
+ #
571
+ # @param resource_group_name [String] The name of the resource group.
572
+ # @param resource_name [String] The name of the managed cluster resource.
573
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
574
+ # will be added to the HTTP request.
575
+ #
576
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
577
+ #
578
+ def list_cluster_user_credentials_with_http_info(resource_group_name, resource_name, custom_headers:nil)
579
+ list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
580
+ end
581
+
582
+ #
583
+ # Gets cluster user credential of a managed cluster.
584
+ #
585
+ # Gets cluster user credential of the managed cluster with a specified resource
586
+ # group and name.
587
+ #
588
+ # @param resource_group_name [String] The name of the resource group.
589
+ # @param resource_name [String] The name of the managed cluster resource.
590
+ # @param [Hash{String => String}] A hash of custom headers that will be added
591
+ # to the HTTP request.
592
+ #
593
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
594
+ #
595
+ def list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers:nil)
596
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
597
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
598
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
599
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
600
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
601
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
602
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
603
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
604
+
605
+
606
+ request_headers = {}
607
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
608
+
609
+ # Set Headers
610
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
611
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
612
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/listClusterUserCredential'
613
+
614
+ request_url = @base_url || @client.base_url
615
+
616
+ options = {
617
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
618
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
619
+ query_params: {'api-version' => @client.api_version},
620
+ headers: request_headers.merge(custom_headers || {}),
621
+ base_url: request_url
622
+ }
623
+ promise = @client.make_request_async(:post, path_template, options)
624
+
625
+ promise = promise.then do |result|
626
+ http_response = result.response
627
+ status_code = http_response.status
628
+ response_content = http_response.body
629
+ unless status_code == 200
630
+ error_model = JSON.load(response_content)
631
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
632
+ end
633
+
634
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
635
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
636
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
637
+ # Deserialize Response
638
+ if status_code == 200
639
+ begin
640
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
641
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::CredentialResults.mapper()
642
+ result.body = @client.deserialize(result_mapper, parsed_response)
643
+ rescue Exception => e
644
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
645
+ end
646
+ end
647
+
648
+ result
649
+ end
650
+
651
+ promise.execute
652
+ end
653
+
654
+ #
655
+ # Gets a managed cluster.
656
+ #
657
+ # Gets the details of the managed cluster with a specified resource group and
658
+ # name.
659
+ #
660
+ # @param resource_group_name [String] The name of the resource group.
661
+ # @param resource_name [String] The name of the managed cluster resource.
662
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
663
+ # will be added to the HTTP request.
664
+ #
665
+ # @return [ManagedCluster] operation results.
666
+ #
667
+ def get(resource_group_name, resource_name, custom_headers:nil)
668
+ response = get_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
669
+ response.body unless response.nil?
670
+ end
671
+
672
+ #
673
+ # Gets a managed cluster.
674
+ #
675
+ # Gets the details of the managed cluster with a specified resource group and
676
+ # name.
677
+ #
678
+ # @param resource_group_name [String] The name of the resource group.
679
+ # @param resource_name [String] The name of the managed cluster resource.
680
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
681
+ # will be added to the HTTP request.
682
+ #
683
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
684
+ #
685
+ def get_with_http_info(resource_group_name, resource_name, custom_headers:nil)
686
+ get_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
687
+ end
688
+
689
+ #
690
+ # Gets a managed cluster.
691
+ #
692
+ # Gets the details of the managed cluster with a specified resource group and
693
+ # name.
694
+ #
695
+ # @param resource_group_name [String] The name of the resource group.
696
+ # @param resource_name [String] The name of the managed cluster resource.
697
+ # @param [Hash{String => String}] A hash of custom headers that will be added
698
+ # to the HTTP request.
699
+ #
700
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
701
+ #
702
+ def get_async(resource_group_name, resource_name, custom_headers:nil)
703
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
704
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
705
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
706
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
707
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
708
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
709
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
710
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
711
+
712
+
713
+ request_headers = {}
714
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
715
+
716
+ # Set Headers
717
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
718
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
719
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}'
720
+
721
+ request_url = @base_url || @client.base_url
722
+
723
+ options = {
724
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
725
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
726
+ query_params: {'api-version' => @client.api_version},
727
+ headers: request_headers.merge(custom_headers || {}),
728
+ base_url: request_url
729
+ }
730
+ promise = @client.make_request_async(:get, path_template, options)
731
+
732
+ promise = promise.then do |result|
733
+ http_response = result.response
734
+ status_code = http_response.status
735
+ response_content = http_response.body
736
+ unless status_code == 200
737
+ error_model = JSON.load(response_content)
738
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
739
+ end
740
+
741
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
742
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
743
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
744
+ # Deserialize Response
745
+ if status_code == 200
746
+ begin
747
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
748
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedCluster.mapper()
749
+ result.body = @client.deserialize(result_mapper, parsed_response)
750
+ rescue Exception => e
751
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
752
+ end
753
+ end
754
+
755
+ result
756
+ end
757
+
758
+ promise.execute
759
+ end
760
+
761
+ #
762
+ # Creates or updates a managed cluster.
763
+ #
764
+ # Creates or updates a managed cluster with the specified configuration for
765
+ # agents and Kubernetes version.
766
+ #
767
+ # @param resource_group_name [String] The name of the resource group.
768
+ # @param resource_name [String] The name of the managed cluster resource.
769
+ # @param parameters [ManagedCluster] Parameters supplied to the Create or
770
+ # Update a Managed Cluster operation.
771
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
772
+ # will be added to the HTTP request.
773
+ #
774
+ # @return [ManagedCluster] operation results.
775
+ #
776
+ def create_or_update(resource_group_name, resource_name, parameters, custom_headers:nil)
777
+ response = create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
778
+ response.body unless response.nil?
779
+ end
780
+
781
+ #
782
+ # @param resource_group_name [String] The name of the resource group.
783
+ # @param resource_name [String] The name of the managed cluster resource.
784
+ # @param parameters [ManagedCluster] Parameters supplied to the Create or
785
+ # Update a Managed Cluster operation.
786
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
787
+ # will be added to the HTTP request.
788
+ #
789
+ # @return [Concurrent::Promise] promise which provides async access to http
790
+ # response.
791
+ #
792
+ def create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:nil)
793
+ # Send request
794
+ promise = begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers)
795
+
796
+ promise = promise.then do |response|
797
+ # Defining deserialization method.
798
+ deserialize_method = lambda do |parsed_response|
799
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedCluster.mapper()
800
+ parsed_response = @client.deserialize(result_mapper, parsed_response)
801
+ end
802
+
803
+ # Waiting for response.
804
+ @client.get_long_running_operation_result(response, deserialize_method)
805
+ end
806
+
807
+ promise
808
+ end
809
+
810
+ #
811
+ # Updates tags on a managed cluster.
812
+ #
813
+ # Updates a managed cluster with the specified tags.
814
+ #
815
+ # @param resource_group_name [String] The name of the resource group.
816
+ # @param resource_name [String] The name of the managed cluster resource.
817
+ # @param parameters [TagsObject] Parameters supplied to the Update Managed
818
+ # Cluster Tags operation.
819
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
820
+ # will be added to the HTTP request.
821
+ #
822
+ # @return [ManagedCluster] operation results.
823
+ #
824
+ def update_tags(resource_group_name, resource_name, parameters, custom_headers:nil)
825
+ response = update_tags_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
826
+ response.body unless response.nil?
827
+ end
828
+
829
+ #
830
+ # @param resource_group_name [String] The name of the resource group.
831
+ # @param resource_name [String] The name of the managed cluster resource.
832
+ # @param parameters [TagsObject] Parameters supplied to the Update Managed
833
+ # Cluster Tags operation.
834
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
835
+ # will be added to the HTTP request.
836
+ #
837
+ # @return [Concurrent::Promise] promise which provides async access to http
838
+ # response.
839
+ #
840
+ def update_tags_async(resource_group_name, resource_name, parameters, custom_headers:nil)
841
+ # Send request
842
+ promise = begin_update_tags_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers)
843
+
844
+ promise = promise.then do |response|
845
+ # Defining deserialization method.
846
+ deserialize_method = lambda do |parsed_response|
847
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedCluster.mapper()
848
+ parsed_response = @client.deserialize(result_mapper, parsed_response)
849
+ end
850
+
851
+ # Waiting for response.
852
+ @client.get_long_running_operation_result(response, deserialize_method)
853
+ end
854
+
855
+ promise
856
+ end
857
+
858
+ #
859
+ # Deletes a managed cluster.
860
+ #
861
+ # Deletes the managed cluster with a specified resource group and name.
862
+ #
863
+ # @param resource_group_name [String] The name of the resource group.
864
+ # @param resource_name [String] The name of the managed cluster resource.
865
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
866
+ # will be added to the HTTP request.
867
+ #
868
+ def delete(resource_group_name, resource_name, custom_headers:nil)
869
+ response = delete_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
870
+ nil
871
+ end
872
+
873
+ #
874
+ # @param resource_group_name [String] The name of the resource group.
875
+ # @param resource_name [String] The name of the managed cluster resource.
876
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
877
+ # will be added to the HTTP request.
878
+ #
879
+ # @return [Concurrent::Promise] promise which provides async access to http
880
+ # response.
881
+ #
882
+ def delete_async(resource_group_name, resource_name, custom_headers:nil)
883
+ # Send request
884
+ promise = begin_delete_async(resource_group_name, resource_name, custom_headers:custom_headers)
885
+
886
+ promise = promise.then do |response|
887
+ # Defining deserialization method.
888
+ deserialize_method = lambda do |parsed_response|
889
+ end
890
+
891
+ # Waiting for response.
892
+ @client.get_long_running_operation_result(response, deserialize_method)
893
+ end
894
+
895
+ promise
896
+ end
897
+
898
+ #
899
+ # Reset Service Principal Profile of a managed cluster.
900
+ #
901
+ # Update the service principal Profile for a managed cluster.
902
+ #
903
+ # @param resource_group_name [String] The name of the resource group.
904
+ # @param resource_name [String] The name of the managed cluster resource.
905
+ # @param parameters [ManagedClusterServicePrincipalProfile] Parameters supplied
906
+ # to the Reset Service Principal Profile operation for a Managed Cluster.
907
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
908
+ # will be added to the HTTP request.
909
+ #
910
+ def reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers:nil)
911
+ response = reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
912
+ nil
913
+ end
914
+
915
+ #
916
+ # @param resource_group_name [String] The name of the resource group.
917
+ # @param resource_name [String] The name of the managed cluster resource.
918
+ # @param parameters [ManagedClusterServicePrincipalProfile] Parameters supplied
919
+ # to the Reset Service Principal Profile operation for a Managed Cluster.
920
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
921
+ # will be added to the HTTP request.
922
+ #
923
+ # @return [Concurrent::Promise] promise which provides async access to http
924
+ # response.
925
+ #
926
+ def reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:nil)
927
+ # Send request
928
+ promise = begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers)
929
+
930
+ promise = promise.then do |response|
931
+ # Defining deserialization method.
932
+ deserialize_method = lambda do |parsed_response|
933
+ end
934
+
935
+ # Waiting for response.
936
+ @client.get_long_running_operation_result(response, deserialize_method)
937
+ end
938
+
939
+ promise
940
+ end
941
+
942
+ #
943
+ # Reset AAD Profile of a managed cluster.
944
+ #
945
+ # Update the AAD Profile for a managed cluster.
946
+ #
947
+ # @param resource_group_name [String] The name of the resource group.
948
+ # @param resource_name [String] The name of the managed cluster resource.
949
+ # @param parameters [ManagedClusterAADProfile] Parameters supplied to the Reset
950
+ # AAD Profile operation for a Managed Cluster.
951
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
952
+ # will be added to the HTTP request.
953
+ #
954
+ def reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers:nil)
955
+ response = reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
956
+ nil
957
+ end
958
+
959
+ #
960
+ # @param resource_group_name [String] The name of the resource group.
961
+ # @param resource_name [String] The name of the managed cluster resource.
962
+ # @param parameters [ManagedClusterAADProfile] Parameters supplied to the Reset
963
+ # AAD Profile operation for a Managed Cluster.
964
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
965
+ # will be added to the HTTP request.
966
+ #
967
+ # @return [Concurrent::Promise] promise which provides async access to http
968
+ # response.
969
+ #
970
+ def reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:nil)
971
+ # Send request
972
+ promise = begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers)
973
+
974
+ promise = promise.then do |response|
975
+ # Defining deserialization method.
976
+ deserialize_method = lambda do |parsed_response|
977
+ end
978
+
979
+ # Waiting for response.
980
+ @client.get_long_running_operation_result(response, deserialize_method)
981
+ end
982
+
983
+ promise
984
+ end
985
+
986
+ #
987
+ # Rotate certificates of a managed cluster.
988
+ #
989
+ # Rotate certificates of a managed cluster.
990
+ #
991
+ # @param resource_group_name [String] The name of the resource group.
992
+ # @param resource_name [String] The name of the managed cluster resource.
993
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
994
+ # will be added to the HTTP request.
995
+ #
996
+ def rotate_cluster_certificates(resource_group_name, resource_name, custom_headers:nil)
997
+ response = rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
998
+ nil
999
+ end
1000
+
1001
+ #
1002
+ # @param resource_group_name [String] The name of the resource group.
1003
+ # @param resource_name [String] The name of the managed cluster resource.
1004
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1005
+ # will be added to the HTTP request.
1006
+ #
1007
+ # @return [Concurrent::Promise] promise which provides async access to http
1008
+ # response.
1009
+ #
1010
+ def rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:nil)
1011
+ # Send request
1012
+ promise = begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers)
1013
+
1014
+ promise = promise.then do |response|
1015
+ # Defining deserialization method.
1016
+ deserialize_method = lambda do |parsed_response|
1017
+ end
1018
+
1019
+ # Waiting for response.
1020
+ @client.get_long_running_operation_result(response, deserialize_method)
1021
+ end
1022
+
1023
+ promise
1024
+ end
1025
+
1026
+ #
1027
+ # Creates or updates a managed cluster.
1028
+ #
1029
+ # Creates or updates a managed cluster with the specified configuration for
1030
+ # agents and Kubernetes version.
1031
+ #
1032
+ # @param resource_group_name [String] The name of the resource group.
1033
+ # @param resource_name [String] The name of the managed cluster resource.
1034
+ # @param parameters [ManagedCluster] Parameters supplied to the Create or
1035
+ # Update a Managed Cluster operation.
1036
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1037
+ # will be added to the HTTP request.
1038
+ #
1039
+ # @return [ManagedCluster] operation results.
1040
+ #
1041
+ def begin_create_or_update(resource_group_name, resource_name, parameters, custom_headers:nil)
1042
+ response = begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1043
+ response.body unless response.nil?
1044
+ end
1045
+
1046
+ #
1047
+ # Creates or updates a managed cluster.
1048
+ #
1049
+ # Creates or updates a managed cluster with the specified configuration for
1050
+ # agents and Kubernetes version.
1051
+ #
1052
+ # @param resource_group_name [String] The name of the resource group.
1053
+ # @param resource_name [String] The name of the managed cluster resource.
1054
+ # @param parameters [ManagedCluster] Parameters supplied to the Create or
1055
+ # Update a Managed Cluster operation.
1056
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1057
+ # will be added to the HTTP request.
1058
+ #
1059
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1060
+ #
1061
+ def begin_create_or_update_with_http_info(resource_group_name, resource_name, parameters, custom_headers:nil)
1062
+ begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1063
+ end
1064
+
1065
+ #
1066
+ # Creates or updates a managed cluster.
1067
+ #
1068
+ # Creates or updates a managed cluster with the specified configuration for
1069
+ # agents and Kubernetes version.
1070
+ #
1071
+ # @param resource_group_name [String] The name of the resource group.
1072
+ # @param resource_name [String] The name of the managed cluster resource.
1073
+ # @param parameters [ManagedCluster] Parameters supplied to the Create or
1074
+ # Update a Managed Cluster operation.
1075
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1076
+ # to the HTTP request.
1077
+ #
1078
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1079
+ #
1080
+ def begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:nil)
1081
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
1082
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
1083
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1084
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
1085
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
1086
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
1087
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
1088
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
1089
+ fail ArgumentError, 'parameters is nil' if parameters.nil?
1090
+
1091
+
1092
+ request_headers = {}
1093
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1094
+
1095
+ # Set Headers
1096
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1097
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1098
+
1099
+ # Serialize Request
1100
+ request_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedCluster.mapper()
1101
+ request_content = @client.serialize(request_mapper, parameters)
1102
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
1103
+
1104
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}'
1105
+
1106
+ request_url = @base_url || @client.base_url
1107
+
1108
+ options = {
1109
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1110
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
1111
+ query_params: {'api-version' => @client.api_version},
1112
+ body: request_content,
1113
+ headers: request_headers.merge(custom_headers || {}),
1114
+ base_url: request_url
1115
+ }
1116
+ promise = @client.make_request_async(:put, path_template, options)
1117
+
1118
+ promise = promise.then do |result|
1119
+ http_response = result.response
1120
+ status_code = http_response.status
1121
+ response_content = http_response.body
1122
+ unless status_code == 200 || status_code == 201
1123
+ error_model = JSON.load(response_content)
1124
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1125
+ end
1126
+
1127
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1128
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1129
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1130
+ # Deserialize Response
1131
+ if status_code == 200
1132
+ begin
1133
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
1134
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedCluster.mapper()
1135
+ result.body = @client.deserialize(result_mapper, parsed_response)
1136
+ rescue Exception => e
1137
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
1138
+ end
1139
+ end
1140
+ # Deserialize Response
1141
+ if status_code == 201
1142
+ begin
1143
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
1144
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedCluster.mapper()
1145
+ result.body = @client.deserialize(result_mapper, parsed_response)
1146
+ rescue Exception => e
1147
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
1148
+ end
1149
+ end
1150
+
1151
+ result
1152
+ end
1153
+
1154
+ promise.execute
1155
+ end
1156
+
1157
+ #
1158
+ # Updates tags on a managed cluster.
1159
+ #
1160
+ # Updates a managed cluster with the specified tags.
1161
+ #
1162
+ # @param resource_group_name [String] The name of the resource group.
1163
+ # @param resource_name [String] The name of the managed cluster resource.
1164
+ # @param parameters [TagsObject] Parameters supplied to the Update Managed
1165
+ # Cluster Tags operation.
1166
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1167
+ # will be added to the HTTP request.
1168
+ #
1169
+ # @return [ManagedCluster] operation results.
1170
+ #
1171
+ def begin_update_tags(resource_group_name, resource_name, parameters, custom_headers:nil)
1172
+ response = begin_update_tags_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1173
+ response.body unless response.nil?
1174
+ end
1175
+
1176
+ #
1177
+ # Updates tags on a managed cluster.
1178
+ #
1179
+ # Updates a managed cluster with the specified tags.
1180
+ #
1181
+ # @param resource_group_name [String] The name of the resource group.
1182
+ # @param resource_name [String] The name of the managed cluster resource.
1183
+ # @param parameters [TagsObject] Parameters supplied to the Update Managed
1184
+ # Cluster Tags operation.
1185
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1186
+ # will be added to the HTTP request.
1187
+ #
1188
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1189
+ #
1190
+ def begin_update_tags_with_http_info(resource_group_name, resource_name, parameters, custom_headers:nil)
1191
+ begin_update_tags_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1192
+ end
1193
+
1194
+ #
1195
+ # Updates tags on a managed cluster.
1196
+ #
1197
+ # Updates a managed cluster with the specified tags.
1198
+ #
1199
+ # @param resource_group_name [String] The name of the resource group.
1200
+ # @param resource_name [String] The name of the managed cluster resource.
1201
+ # @param parameters [TagsObject] Parameters supplied to the Update Managed
1202
+ # Cluster Tags operation.
1203
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1204
+ # to the HTTP request.
1205
+ #
1206
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1207
+ #
1208
+ def begin_update_tags_async(resource_group_name, resource_name, parameters, custom_headers:nil)
1209
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
1210
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
1211
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1212
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
1213
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
1214
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
1215
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
1216
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
1217
+ fail ArgumentError, 'parameters is nil' if parameters.nil?
1218
+
1219
+
1220
+ request_headers = {}
1221
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1222
+
1223
+ # Set Headers
1224
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1225
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1226
+
1227
+ # Serialize Request
1228
+ request_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::TagsObject.mapper()
1229
+ request_content = @client.serialize(request_mapper, parameters)
1230
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
1231
+
1232
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}'
1233
+
1234
+ request_url = @base_url || @client.base_url
1235
+
1236
+ options = {
1237
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1238
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
1239
+ query_params: {'api-version' => @client.api_version},
1240
+ body: request_content,
1241
+ headers: request_headers.merge(custom_headers || {}),
1242
+ base_url: request_url
1243
+ }
1244
+ promise = @client.make_request_async(:patch, path_template, options)
1245
+
1246
+ promise = promise.then do |result|
1247
+ http_response = result.response
1248
+ status_code = http_response.status
1249
+ response_content = http_response.body
1250
+ unless status_code == 200
1251
+ error_model = JSON.load(response_content)
1252
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1253
+ end
1254
+
1255
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1256
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1257
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1258
+ # Deserialize Response
1259
+ if status_code == 200
1260
+ begin
1261
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
1262
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedCluster.mapper()
1263
+ result.body = @client.deserialize(result_mapper, parsed_response)
1264
+ rescue Exception => e
1265
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
1266
+ end
1267
+ end
1268
+
1269
+ result
1270
+ end
1271
+
1272
+ promise.execute
1273
+ end
1274
+
1275
+ #
1276
+ # Deletes a managed cluster.
1277
+ #
1278
+ # Deletes the managed cluster with a specified resource group and name.
1279
+ #
1280
+ # @param resource_group_name [String] The name of the resource group.
1281
+ # @param resource_name [String] The name of the managed cluster resource.
1282
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1283
+ # will be added to the HTTP request.
1284
+ #
1285
+ #
1286
+ def begin_delete(resource_group_name, resource_name, custom_headers:nil)
1287
+ response = begin_delete_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
1288
+ nil
1289
+ end
1290
+
1291
+ #
1292
+ # Deletes a managed cluster.
1293
+ #
1294
+ # Deletes the managed cluster with a specified resource group and name.
1295
+ #
1296
+ # @param resource_group_name [String] The name of the resource group.
1297
+ # @param resource_name [String] The name of the managed cluster resource.
1298
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1299
+ # will be added to the HTTP request.
1300
+ #
1301
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1302
+ #
1303
+ def begin_delete_with_http_info(resource_group_name, resource_name, custom_headers:nil)
1304
+ begin_delete_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
1305
+ end
1306
+
1307
+ #
1308
+ # Deletes a managed cluster.
1309
+ #
1310
+ # Deletes the managed cluster with a specified resource group and name.
1311
+ #
1312
+ # @param resource_group_name [String] The name of the resource group.
1313
+ # @param resource_name [String] The name of the managed cluster resource.
1314
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1315
+ # to the HTTP request.
1316
+ #
1317
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1318
+ #
1319
+ def begin_delete_async(resource_group_name, resource_name, custom_headers:nil)
1320
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
1321
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
1322
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1323
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
1324
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
1325
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
1326
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
1327
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
1328
+
1329
+
1330
+ request_headers = {}
1331
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1332
+
1333
+ # Set Headers
1334
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1335
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1336
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}'
1337
+
1338
+ request_url = @base_url || @client.base_url
1339
+
1340
+ options = {
1341
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1342
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
1343
+ query_params: {'api-version' => @client.api_version},
1344
+ headers: request_headers.merge(custom_headers || {}),
1345
+ base_url: request_url
1346
+ }
1347
+ promise = @client.make_request_async(:delete, path_template, options)
1348
+
1349
+ promise = promise.then do |result|
1350
+ http_response = result.response
1351
+ status_code = http_response.status
1352
+ response_content = http_response.body
1353
+ unless status_code == 202 || status_code == 204
1354
+ error_model = JSON.load(response_content)
1355
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1356
+ end
1357
+
1358
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1359
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1360
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1361
+
1362
+ result
1363
+ end
1364
+
1365
+ promise.execute
1366
+ end
1367
+
1368
+ #
1369
+ # Reset Service Principal Profile of a managed cluster.
1370
+ #
1371
+ # Update the service principal Profile for a managed cluster.
1372
+ #
1373
+ # @param resource_group_name [String] The name of the resource group.
1374
+ # @param resource_name [String] The name of the managed cluster resource.
1375
+ # @param parameters [ManagedClusterServicePrincipalProfile] Parameters supplied
1376
+ # to the Reset Service Principal Profile operation for a Managed Cluster.
1377
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1378
+ # will be added to the HTTP request.
1379
+ #
1380
+ #
1381
+ def begin_reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers:nil)
1382
+ response = begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1383
+ nil
1384
+ end
1385
+
1386
+ #
1387
+ # Reset Service Principal Profile of a managed cluster.
1388
+ #
1389
+ # Update the service principal Profile for a managed cluster.
1390
+ #
1391
+ # @param resource_group_name [String] The name of the resource group.
1392
+ # @param resource_name [String] The name of the managed cluster resource.
1393
+ # @param parameters [ManagedClusterServicePrincipalProfile] Parameters supplied
1394
+ # to the Reset Service Principal Profile operation for a Managed Cluster.
1395
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1396
+ # will be added to the HTTP request.
1397
+ #
1398
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1399
+ #
1400
+ def begin_reset_service_principal_profile_with_http_info(resource_group_name, resource_name, parameters, custom_headers:nil)
1401
+ begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1402
+ end
1403
+
1404
+ #
1405
+ # Reset Service Principal Profile of a managed cluster.
1406
+ #
1407
+ # Update the service principal Profile for a managed cluster.
1408
+ #
1409
+ # @param resource_group_name [String] The name of the resource group.
1410
+ # @param resource_name [String] The name of the managed cluster resource.
1411
+ # @param parameters [ManagedClusterServicePrincipalProfile] Parameters supplied
1412
+ # to the Reset Service Principal Profile operation for a Managed Cluster.
1413
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1414
+ # to the HTTP request.
1415
+ #
1416
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1417
+ #
1418
+ def begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:nil)
1419
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
1420
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
1421
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1422
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
1423
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
1424
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
1425
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
1426
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
1427
+ fail ArgumentError, 'parameters is nil' if parameters.nil?
1428
+
1429
+
1430
+ request_headers = {}
1431
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1432
+
1433
+ # Set Headers
1434
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1435
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1436
+
1437
+ # Serialize Request
1438
+ request_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterServicePrincipalProfile.mapper()
1439
+ request_content = @client.serialize(request_mapper, parameters)
1440
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
1441
+
1442
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/resetServicePrincipalProfile'
1443
+
1444
+ request_url = @base_url || @client.base_url
1445
+
1446
+ options = {
1447
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1448
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
1449
+ query_params: {'api-version' => @client.api_version},
1450
+ body: request_content,
1451
+ headers: request_headers.merge(custom_headers || {}),
1452
+ base_url: request_url
1453
+ }
1454
+ promise = @client.make_request_async(:post, path_template, options)
1455
+
1456
+ promise = promise.then do |result|
1457
+ http_response = result.response
1458
+ status_code = http_response.status
1459
+ response_content = http_response.body
1460
+ unless status_code == 200 || status_code == 202
1461
+ error_model = JSON.load(response_content)
1462
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1463
+ end
1464
+
1465
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1466
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1467
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1468
+
1469
+ result
1470
+ end
1471
+
1472
+ promise.execute
1473
+ end
1474
+
1475
+ #
1476
+ # Reset AAD Profile of a managed cluster.
1477
+ #
1478
+ # Update the AAD Profile for a managed cluster.
1479
+ #
1480
+ # @param resource_group_name [String] The name of the resource group.
1481
+ # @param resource_name [String] The name of the managed cluster resource.
1482
+ # @param parameters [ManagedClusterAADProfile] Parameters supplied to the Reset
1483
+ # AAD Profile operation for a Managed Cluster.
1484
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1485
+ # will be added to the HTTP request.
1486
+ #
1487
+ #
1488
+ def begin_reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers:nil)
1489
+ response = begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1490
+ nil
1491
+ end
1492
+
1493
+ #
1494
+ # Reset AAD Profile of a managed cluster.
1495
+ #
1496
+ # Update the AAD Profile for a managed cluster.
1497
+ #
1498
+ # @param resource_group_name [String] The name of the resource group.
1499
+ # @param resource_name [String] The name of the managed cluster resource.
1500
+ # @param parameters [ManagedClusterAADProfile] Parameters supplied to the Reset
1501
+ # AAD Profile operation for a Managed Cluster.
1502
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1503
+ # will be added to the HTTP request.
1504
+ #
1505
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1506
+ #
1507
+ def begin_reset_aadprofile_with_http_info(resource_group_name, resource_name, parameters, custom_headers:nil)
1508
+ begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value!
1509
+ end
1510
+
1511
+ #
1512
+ # Reset AAD Profile of a managed cluster.
1513
+ #
1514
+ # Update the AAD Profile for a managed cluster.
1515
+ #
1516
+ # @param resource_group_name [String] The name of the resource group.
1517
+ # @param resource_name [String] The name of the managed cluster resource.
1518
+ # @param parameters [ManagedClusterAADProfile] Parameters supplied to the Reset
1519
+ # AAD Profile operation for a Managed Cluster.
1520
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1521
+ # to the HTTP request.
1522
+ #
1523
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1524
+ #
1525
+ def begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:nil)
1526
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
1527
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
1528
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1529
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
1530
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
1531
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
1532
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
1533
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
1534
+ fail ArgumentError, 'parameters is nil' if parameters.nil?
1535
+
1536
+
1537
+ request_headers = {}
1538
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1539
+
1540
+ # Set Headers
1541
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1542
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1543
+
1544
+ # Serialize Request
1545
+ request_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterAADProfile.mapper()
1546
+ request_content = @client.serialize(request_mapper, parameters)
1547
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
1548
+
1549
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/resetAADProfile'
1550
+
1551
+ request_url = @base_url || @client.base_url
1552
+
1553
+ options = {
1554
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1555
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
1556
+ query_params: {'api-version' => @client.api_version},
1557
+ body: request_content,
1558
+ headers: request_headers.merge(custom_headers || {}),
1559
+ base_url: request_url
1560
+ }
1561
+ promise = @client.make_request_async(:post, path_template, options)
1562
+
1563
+ promise = promise.then do |result|
1564
+ http_response = result.response
1565
+ status_code = http_response.status
1566
+ response_content = http_response.body
1567
+ unless status_code == 200 || status_code == 202
1568
+ error_model = JSON.load(response_content)
1569
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1570
+ end
1571
+
1572
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1573
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1574
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1575
+
1576
+ result
1577
+ end
1578
+
1579
+ promise.execute
1580
+ end
1581
+
1582
+ #
1583
+ # Rotate certificates of a managed cluster.
1584
+ #
1585
+ # Rotate certificates of a managed cluster.
1586
+ #
1587
+ # @param resource_group_name [String] The name of the resource group.
1588
+ # @param resource_name [String] The name of the managed cluster resource.
1589
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1590
+ # will be added to the HTTP request.
1591
+ #
1592
+ #
1593
+ def begin_rotate_cluster_certificates(resource_group_name, resource_name, custom_headers:nil)
1594
+ response = begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
1595
+ nil
1596
+ end
1597
+
1598
+ #
1599
+ # Rotate certificates of a managed cluster.
1600
+ #
1601
+ # Rotate certificates of a managed cluster.
1602
+ #
1603
+ # @param resource_group_name [String] The name of the resource group.
1604
+ # @param resource_name [String] The name of the managed cluster resource.
1605
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1606
+ # will be added to the HTTP request.
1607
+ #
1608
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1609
+ #
1610
+ def begin_rotate_cluster_certificates_with_http_info(resource_group_name, resource_name, custom_headers:nil)
1611
+ begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers).value!
1612
+ end
1613
+
1614
+ #
1615
+ # Rotate certificates of a managed cluster.
1616
+ #
1617
+ # Rotate certificates of a managed cluster.
1618
+ #
1619
+ # @param resource_group_name [String] The name of the resource group.
1620
+ # @param resource_name [String] The name of the managed cluster resource.
1621
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1622
+ # to the HTTP request.
1623
+ #
1624
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1625
+ #
1626
+ def begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:nil)
1627
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
1628
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
1629
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1630
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
1631
+ fail ArgumentError, 'resource_name is nil' if resource_name.nil?
1632
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63
1633
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1
1634
+ fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil?
1635
+
1636
+
1637
+ request_headers = {}
1638
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1639
+
1640
+ # Set Headers
1641
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1642
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1643
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/rotateClusterCertificates'
1644
+
1645
+ request_url = @base_url || @client.base_url
1646
+
1647
+ options = {
1648
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1649
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name},
1650
+ query_params: {'api-version' => @client.api_version},
1651
+ headers: request_headers.merge(custom_headers || {}),
1652
+ base_url: request_url
1653
+ }
1654
+ promise = @client.make_request_async(:post, path_template, options)
1655
+
1656
+ promise = promise.then do |result|
1657
+ http_response = result.response
1658
+ status_code = http_response.status
1659
+ response_content = http_response.body
1660
+ unless status_code == 202 || status_code == 204
1661
+ error_model = JSON.load(response_content)
1662
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1663
+ end
1664
+
1665
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1666
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1667
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1668
+
1669
+ result
1670
+ end
1671
+
1672
+ promise.execute
1673
+ end
1674
+
1675
+ #
1676
+ # Gets a list of managed clusters in the specified subscription.
1677
+ #
1678
+ # Gets a list of managed clusters in the specified subscription. The operation
1679
+ # returns properties of each managed cluster.
1680
+ #
1681
+ # @param next_page_link [String] The NextLink from the previous successful call
1682
+ # to List operation.
1683
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1684
+ # will be added to the HTTP request.
1685
+ #
1686
+ # @return [ManagedClusterListResult] operation results.
1687
+ #
1688
+ def list_next(next_page_link, custom_headers:nil)
1689
+ response = list_next_async(next_page_link, custom_headers:custom_headers).value!
1690
+ response.body unless response.nil?
1691
+ end
1692
+
1693
+ #
1694
+ # Gets a list of managed clusters in the specified subscription.
1695
+ #
1696
+ # Gets a list of managed clusters in the specified subscription. The operation
1697
+ # returns properties of each managed cluster.
1698
+ #
1699
+ # @param next_page_link [String] The NextLink from the previous successful call
1700
+ # to List operation.
1701
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1702
+ # will be added to the HTTP request.
1703
+ #
1704
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1705
+ #
1706
+ def list_next_with_http_info(next_page_link, custom_headers:nil)
1707
+ list_next_async(next_page_link, custom_headers:custom_headers).value!
1708
+ end
1709
+
1710
+ #
1711
+ # Gets a list of managed clusters in the specified subscription.
1712
+ #
1713
+ # Gets a list of managed clusters in the specified subscription. The operation
1714
+ # returns properties of each managed cluster.
1715
+ #
1716
+ # @param next_page_link [String] The NextLink from the previous successful call
1717
+ # to List operation.
1718
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1719
+ # to the HTTP request.
1720
+ #
1721
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1722
+ #
1723
+ def list_next_async(next_page_link, custom_headers:nil)
1724
+ fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
1725
+
1726
+
1727
+ request_headers = {}
1728
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1729
+
1730
+ # Set Headers
1731
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1732
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1733
+ path_template = '{nextLink}'
1734
+
1735
+ request_url = @base_url || @client.base_url
1736
+
1737
+ options = {
1738
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1739
+ skip_encoding_path_params: {'nextLink' => next_page_link},
1740
+ headers: request_headers.merge(custom_headers || {}),
1741
+ base_url: request_url
1742
+ }
1743
+ promise = @client.make_request_async(:get, path_template, options)
1744
+
1745
+ promise = promise.then do |result|
1746
+ http_response = result.response
1747
+ status_code = http_response.status
1748
+ response_content = http_response.body
1749
+ unless status_code == 200
1750
+ error_model = JSON.load(response_content)
1751
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1752
+ end
1753
+
1754
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1755
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1756
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1757
+ # Deserialize Response
1758
+ if status_code == 200
1759
+ begin
1760
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
1761
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterListResult.mapper()
1762
+ result.body = @client.deserialize(result_mapper, parsed_response)
1763
+ rescue Exception => e
1764
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
1765
+ end
1766
+ end
1767
+
1768
+ result
1769
+ end
1770
+
1771
+ promise.execute
1772
+ end
1773
+
1774
+ #
1775
+ # Lists managed clusters in the specified subscription and resource group.
1776
+ #
1777
+ # Lists managed clusters in the specified subscription and resource group. The
1778
+ # operation returns properties of each managed cluster.
1779
+ #
1780
+ # @param next_page_link [String] The NextLink from the previous successful call
1781
+ # to List operation.
1782
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1783
+ # will be added to the HTTP request.
1784
+ #
1785
+ # @return [ManagedClusterListResult] operation results.
1786
+ #
1787
+ def list_by_resource_group_next(next_page_link, custom_headers:nil)
1788
+ response = list_by_resource_group_next_async(next_page_link, custom_headers:custom_headers).value!
1789
+ response.body unless response.nil?
1790
+ end
1791
+
1792
+ #
1793
+ # Lists managed clusters in the specified subscription and resource group.
1794
+ #
1795
+ # Lists managed clusters in the specified subscription and resource group. The
1796
+ # operation returns properties of each managed cluster.
1797
+ #
1798
+ # @param next_page_link [String] The NextLink from the previous successful call
1799
+ # to List operation.
1800
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1801
+ # will be added to the HTTP request.
1802
+ #
1803
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1804
+ #
1805
+ def list_by_resource_group_next_with_http_info(next_page_link, custom_headers:nil)
1806
+ list_by_resource_group_next_async(next_page_link, custom_headers:custom_headers).value!
1807
+ end
1808
+
1809
+ #
1810
+ # Lists managed clusters in the specified subscription and resource group.
1811
+ #
1812
+ # Lists managed clusters in the specified subscription and resource group. The
1813
+ # operation returns properties of each managed cluster.
1814
+ #
1815
+ # @param next_page_link [String] The NextLink from the previous successful call
1816
+ # to List operation.
1817
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1818
+ # to the HTTP request.
1819
+ #
1820
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1821
+ #
1822
+ def list_by_resource_group_next_async(next_page_link, custom_headers:nil)
1823
+ fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
1824
+
1825
+
1826
+ request_headers = {}
1827
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1828
+
1829
+ # Set Headers
1830
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1831
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1832
+ path_template = '{nextLink}'
1833
+
1834
+ request_url = @base_url || @client.base_url
1835
+
1836
+ options = {
1837
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1838
+ skip_encoding_path_params: {'nextLink' => next_page_link},
1839
+ headers: request_headers.merge(custom_headers || {}),
1840
+ base_url: request_url
1841
+ }
1842
+ promise = @client.make_request_async(:get, path_template, options)
1843
+
1844
+ promise = promise.then do |result|
1845
+ http_response = result.response
1846
+ status_code = http_response.status
1847
+ response_content = http_response.body
1848
+ unless status_code == 200
1849
+ error_model = JSON.load(response_content)
1850
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1851
+ end
1852
+
1853
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1854
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1855
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1856
+ # Deserialize Response
1857
+ if status_code == 200
1858
+ begin
1859
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
1860
+ result_mapper = Azure::ContainerService::Mgmt::V2019_10_01::Models::ManagedClusterListResult.mapper()
1861
+ result.body = @client.deserialize(result_mapper, parsed_response)
1862
+ rescue Exception => e
1863
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
1864
+ end
1865
+ end
1866
+
1867
+ result
1868
+ end
1869
+
1870
+ promise.execute
1871
+ end
1872
+
1873
+ #
1874
+ # Gets a list of managed clusters in the specified subscription.
1875
+ #
1876
+ # Gets a list of managed clusters in the specified subscription. The operation
1877
+ # returns properties of each managed cluster.
1878
+ #
1879
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1880
+ # will be added to the HTTP request.
1881
+ #
1882
+ # @return [ManagedClusterListResult] which provide lazy access to pages of the
1883
+ # response.
1884
+ #
1885
+ def list_as_lazy(custom_headers:nil)
1886
+ response = list_async(custom_headers:custom_headers).value!
1887
+ unless response.nil?
1888
+ page = response.body
1889
+ page.next_method = Proc.new do |next_page_link|
1890
+ list_next_async(next_page_link, custom_headers:custom_headers)
1891
+ end
1892
+ page
1893
+ end
1894
+ end
1895
+
1896
+ #
1897
+ # Lists managed clusters in the specified subscription and resource group.
1898
+ #
1899
+ # Lists managed clusters in the specified subscription and resource group. The
1900
+ # operation returns properties of each managed cluster.
1901
+ #
1902
+ # @param resource_group_name [String] The name of the resource group.
1903
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1904
+ # will be added to the HTTP request.
1905
+ #
1906
+ # @return [ManagedClusterListResult] which provide lazy access to pages of the
1907
+ # response.
1908
+ #
1909
+ def list_by_resource_group_as_lazy(resource_group_name, custom_headers:nil)
1910
+ response = list_by_resource_group_async(resource_group_name, custom_headers:custom_headers).value!
1911
+ unless response.nil?
1912
+ page = response.body
1913
+ page.next_method = Proc.new do |next_page_link|
1914
+ list_by_resource_group_next_async(next_page_link, custom_headers:custom_headers)
1915
+ end
1916
+ page
1917
+ end
1918
+ end
1919
+
1920
+ end
1921
+ end