azure_mgmt_compute 0.20.0 → 0.21.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (251) hide show
  1. checksums.yaml +4 -4
  2. data/lib/2015-06-15/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  3. data/lib/2016-03-30/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  4. data/lib/2016-04-30-preview/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  5. data/lib/2017-03-30/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  6. data/lib/2017-09-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  7. data/lib/2017-12-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  8. data/lib/2018-04-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  9. data/lib/2018-06-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  10. data/lib/2018-09-30/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  11. data/lib/2018-10-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  12. data/lib/2019-03-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  13. data/lib/2019-04-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  14. data/lib/2019-07-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  15. data/lib/2019-11-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  16. data/lib/2019-12-01/generated/azure_mgmt_compute.rb +94 -93
  17. data/lib/2019-12-01/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  18. data/lib/2019-12-01/generated/azure_mgmt_compute/models/gallery_application_version_publishing_profile.rb +7 -7
  19. data/lib/2019-12-01/generated/azure_mgmt_compute/models/user_artifact_manage.rb +74 -0
  20. data/lib/2019-12-01/generated/azure_mgmt_compute/models/user_artifact_source.rb +10 -9
  21. data/lib/2019-12-01/generated/azure_mgmt_compute/virtual_machine_scale_set_vms.rb +12 -4
  22. data/lib/2019-12-01/generated/azure_mgmt_compute/virtual_machines.rb +36 -8
  23. data/lib/2020-06-01/generated/azure_mgmt_compute.rb +102 -92
  24. data/lib/2020-06-01/generated/azure_mgmt_compute/compute_management_client.rb +6 -1
  25. data/lib/2020-06-01/generated/azure_mgmt_compute/models/dedicated_host_group.rb +1 -1
  26. data/lib/2020-06-01/generated/azure_mgmt_compute/models/dedicated_host_group_update.rb +1 -1
  27. data/lib/2020-06-01/generated/azure_mgmt_compute/models/execution_state.rb +21 -0
  28. data/lib/2020-06-01/generated/azure_mgmt_compute/models/hardware_profile.rb +20 -15
  29. data/lib/2020-06-01/generated/azure_mgmt_compute/models/log_analytics_input_base.rb +22 -0
  30. data/lib/2020-06-01/generated/azure_mgmt_compute/models/request_rate_by_interval_input.rb +16 -0
  31. data/lib/2020-06-01/generated/azure_mgmt_compute/models/ssh_public_key.rb +1 -1
  32. data/lib/2020-06-01/generated/azure_mgmt_compute/models/throttled_requests_input.rb +16 -0
  33. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine.rb +8 -7
  34. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_run_command.rb +241 -0
  35. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_run_command_instance_view.rb +135 -0
  36. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_run_command_script_source.rb +68 -0
  37. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_run_command_update.rb +206 -0
  38. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_run_commands_list_result.rb +98 -0
  39. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_scale_set_network_configuration.rb +12 -0
  40. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_scale_set_update_network_configuration.rb +12 -0
  41. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_scale_set_vm.rb +8 -7
  42. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_scale_set_vmextension.rb +190 -0
  43. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_scale_set_vmextension_update.rb +164 -0
  44. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_scale_set_vmextensions_list_result.rb +57 -0
  45. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_scale_set_vmprofile.rb +8 -7
  46. data/lib/2020-06-01/generated/azure_mgmt_compute/models/virtual_machine_update.rb +8 -7
  47. data/lib/2020-06-01/generated/azure_mgmt_compute/virtual_machine_run_commands.rb +790 -0
  48. data/lib/2020-06-01/generated/azure_mgmt_compute/virtual_machine_scale_set_vmextensions.rb +35 -35
  49. data/lib/2020-06-01/generated/azure_mgmt_compute/virtual_machine_scale_set_vmrun_commands.rb +827 -0
  50. data/lib/2020-06-01/generated/azure_mgmt_compute/virtual_machines.rb +5 -5
  51. data/lib/2020-06-30/generated/azure_mgmt_compute/compute_management_client.rb +1 -1
  52. data/lib/2020-09-30-preview/generated/azure_mgmt_compute.rb +106 -0
  53. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/compute_management_client.rb +165 -0
  54. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/galleries.rb +994 -0
  55. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/gallery_application_versions.rb +915 -0
  56. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/gallery_applications.rb +856 -0
  57. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/gallery_image_versions.rb +911 -0
  58. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/gallery_images.rb +856 -0
  59. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/gallery_sharing_profile.rb +189 -0
  60. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/aggregated_replication_state.rb +18 -0
  61. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/api_error.rb +100 -0
  62. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/api_error_base.rb +68 -0
  63. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/data_disk_image_encryption.rb +57 -0
  64. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/disallowed.rb +54 -0
  65. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/disk_image_encryption.rb +47 -0
  66. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/encryption_images.rb +69 -0
  67. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery.rb +137 -0
  68. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_application.rb +161 -0
  69. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_application_list.rb +100 -0
  70. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_application_update.rb +153 -0
  71. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_application_version.rb +127 -0
  72. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_application_version_list.rb +101 -0
  73. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_application_version_publishing_profile.rb +130 -0
  74. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_application_version_update.rb +119 -0
  75. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_artifact_publishing_profile_base.rb +120 -0
  76. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_artifact_source.rb +47 -0
  77. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_artifact_version_source.rb +60 -0
  78. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_data_disk_image.rb +76 -0
  79. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_disk_image.rb +74 -0
  80. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_identifier.rb +48 -0
  81. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image.rb +271 -0
  82. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_feature.rb +57 -0
  83. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_identifier.rb +68 -0
  84. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_list.rb +100 -0
  85. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_update.rb +263 -0
  86. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_version.rb +139 -0
  87. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_version_list.rb +100 -0
  88. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_version_publishing_profile.rb +93 -0
  89. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_version_storage_profile.rb +79 -0
  90. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_image_version_update.rb +131 -0
  91. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_list.rb +99 -0
  92. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_osdisk_image.rb +62 -0
  93. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_sharing_permission_types.rb +16 -0
  94. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/gallery_update.rb +129 -0
  95. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/host_caching.rb +17 -0
  96. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/hyper_vgeneration.rb +16 -0
  97. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/image_purchase_plan.rb +69 -0
  98. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/inner_error.rb +57 -0
  99. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/managed_artifact.rb +46 -0
  100. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/operating_system_state_types.rb +16 -0
  101. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/operating_system_types.rb +16 -0
  102. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/osdisk_image_encryption.rb +43 -0
  103. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/pir_resource.rb +59 -0
  104. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/pir_shared_gallery_resource.rb +64 -0
  105. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/recommended_machine_configuration.rb +60 -0
  106. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/regional_replication_status.rb +86 -0
  107. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/replication_state.rb +18 -0
  108. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/replication_status.rb +71 -0
  109. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/replication_status_types.rb +15 -0
  110. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/resource.rb +110 -0
  111. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/resource_range.rb +57 -0
  112. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/select_permissions.rb +15 -0
  113. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/shared_gallery.rb +62 -0
  114. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/shared_gallery_image.rb +186 -0
  115. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/shared_gallery_image_list.rb +100 -0
  116. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/shared_gallery_image_version.rb +88 -0
  117. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/shared_gallery_image_version_list.rb +101 -0
  118. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/shared_gallery_list.rb +99 -0
  119. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/shared_to_values.rb +15 -0
  120. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/sharing_profile.rb +70 -0
  121. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/sharing_profile_group.rb +69 -0
  122. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/sharing_profile_group_types.rb +16 -0
  123. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/sharing_update.rb +69 -0
  124. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/sharing_update_operation_types.rb +17 -0
  125. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/storage_account_type.rb +17 -0
  126. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/target_region.rb +83 -0
  127. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/update_resource_definition.rb +90 -0
  128. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/user_artifact_manage.rb +74 -0
  129. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/models/user_artifact_source.rb +59 -0
  130. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/module_definition.rb +9 -0
  131. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/shared_galleries.rb +332 -0
  132. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/shared_gallery_image_versions.rb +366 -0
  133. data/lib/2020-09-30-preview/generated/azure_mgmt_compute/shared_gallery_images.rb +344 -0
  134. data/lib/2020-09-30/generated/azure_mgmt_compute.rb +89 -0
  135. data/lib/2020-09-30/generated/azure_mgmt_compute/compute_management_client.rb +149 -0
  136. data/lib/2020-09-30/generated/azure_mgmt_compute/disk_accesses.rb +1804 -0
  137. data/lib/2020-09-30/generated/azure_mgmt_compute/disk_encryption_sets.rb +1236 -0
  138. data/lib/2020-09-30/generated/azure_mgmt_compute/disk_restore_point_operations.rb +372 -0
  139. data/lib/2020-09-30/generated/azure_mgmt_compute/disks.rb +1294 -0
  140. data/lib/2020-09-30/generated/azure_mgmt_compute/models/access_level.rb +17 -0
  141. data/lib/2020-09-30/generated/azure_mgmt_compute/models/access_uri.rb +47 -0
  142. data/lib/2020-09-30/generated/azure_mgmt_compute/models/api_error.rb +100 -0
  143. data/lib/2020-09-30/generated/azure_mgmt_compute/models/api_error_base.rb +68 -0
  144. data/lib/2020-09-30/generated/azure_mgmt_compute/models/creation_data.rb +150 -0
  145. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk.rb +462 -0
  146. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_access.rb +133 -0
  147. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_access_list.rb +100 -0
  148. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_access_update.rb +54 -0
  149. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_create_option.rb +21 -0
  150. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_encryption_set.rb +160 -0
  151. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_encryption_set_identity_type.rb +16 -0
  152. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_encryption_set_list.rb +100 -0
  153. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_encryption_set_type.rb +16 -0
  154. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_encryption_set_update.rb +79 -0
  155. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_list.rb +99 -0
  156. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_restore_point.rb +164 -0
  157. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_restore_point_list.rb +100 -0
  158. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_sku.rb +61 -0
  159. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_state.rb +20 -0
  160. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_storage_account_types.rb +18 -0
  161. data/lib/2020-09-30/generated/azure_mgmt_compute/models/disk_update.rb +251 -0
  162. data/lib/2020-09-30/generated/azure_mgmt_compute/models/encryption.rb +60 -0
  163. data/lib/2020-09-30/generated/azure_mgmt_compute/models/encryption_set_identity.rb +81 -0
  164. data/lib/2020-09-30/generated/azure_mgmt_compute/models/encryption_settings_collection.rb +85 -0
  165. data/lib/2020-09-30/generated/azure_mgmt_compute/models/encryption_settings_element.rb +62 -0
  166. data/lib/2020-09-30/generated/azure_mgmt_compute/models/encryption_type.rb +17 -0
  167. data/lib/2020-09-30/generated/azure_mgmt_compute/models/extended_location.rb +58 -0
  168. data/lib/2020-09-30/generated/azure_mgmt_compute/models/extended_location_types.rb +15 -0
  169. data/lib/2020-09-30/generated/azure_mgmt_compute/models/grant_access_data.rb +58 -0
  170. data/lib/2020-09-30/generated/azure_mgmt_compute/models/hyper_vgeneration.rb +16 -0
  171. data/lib/2020-09-30/generated/azure_mgmt_compute/models/image_disk_reference.rb +60 -0
  172. data/lib/2020-09-30/generated/azure_mgmt_compute/models/inner_error.rb +57 -0
  173. data/lib/2020-09-30/generated/azure_mgmt_compute/models/key_for_disk_encryption_set.rb +61 -0
  174. data/lib/2020-09-30/generated/azure_mgmt_compute/models/key_vault_and_key_reference.rb +60 -0
  175. data/lib/2020-09-30/generated/azure_mgmt_compute/models/key_vault_and_secret_reference.rb +59 -0
  176. data/lib/2020-09-30/generated/azure_mgmt_compute/models/network_access_policy.rb +17 -0
  177. data/lib/2020-09-30/generated/azure_mgmt_compute/models/operating_system_types.rb +16 -0
  178. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_endpoint.rb +47 -0
  179. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_endpoint_connection.rb +110 -0
  180. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_endpoint_connection_list_result.rb +100 -0
  181. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_endpoint_connection_provisioning_state.rb +18 -0
  182. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_endpoint_service_connection_status.rb +17 -0
  183. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_link_resource.rb +123 -0
  184. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_link_resource_list_result.rb +55 -0
  185. data/lib/2020-09-30/generated/azure_mgmt_compute/models/private_link_service_connection_state.rb +72 -0
  186. data/lib/2020-09-30/generated/azure_mgmt_compute/models/proxy_only_resource.rb +71 -0
  187. data/lib/2020-09-30/generated/azure_mgmt_compute/models/purchase_plan.rb +82 -0
  188. data/lib/2020-09-30/generated/azure_mgmt_compute/models/resource.rb +110 -0
  189. data/lib/2020-09-30/generated/azure_mgmt_compute/models/resource_uri_list.rb +100 -0
  190. data/lib/2020-09-30/generated/azure_mgmt_compute/models/share_info_element.rb +49 -0
  191. data/lib/2020-09-30/generated/azure_mgmt_compute/models/snapshot.rb +316 -0
  192. data/lib/2020-09-30/generated/azure_mgmt_compute/models/snapshot_list.rb +99 -0
  193. data/lib/2020-09-30/generated/azure_mgmt_compute/models/snapshot_sku.rb +62 -0
  194. data/lib/2020-09-30/generated/azure_mgmt_compute/models/snapshot_storage_account_types.rb +17 -0
  195. data/lib/2020-09-30/generated/azure_mgmt_compute/models/snapshot_update.rb +145 -0
  196. data/lib/2020-09-30/generated/azure_mgmt_compute/models/source_vault.rb +47 -0
  197. data/lib/2020-09-30/generated/azure_mgmt_compute/module_definition.rb +9 -0
  198. data/lib/2020-09-30/generated/azure_mgmt_compute/snapshots.rb +1294 -0
  199. data/lib/2020-10-01-preview/generated/azure_mgmt_compute.rb +73 -0
  200. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/cloud_service_role_instances.rb +1091 -0
  201. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/cloud_service_roles.rb +343 -0
  202. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/cloud_services.rb +1870 -0
  203. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/cloud_services_update_domain.rb +486 -0
  204. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/compute_management_client.rb +145 -0
  205. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/api_error.rb +100 -0
  206. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/api_error_base.rb +68 -0
  207. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service.rb +113 -0
  208. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_extension_profile.rb +55 -0
  209. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_extension_properties.rb +180 -0
  210. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_instance_view.rb +81 -0
  211. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_list_result.rb +98 -0
  212. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_network_profile.rb +68 -0
  213. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_os_profile.rb +56 -0
  214. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_properties.rb +176 -0
  215. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_role.rb +107 -0
  216. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_role_list_result.rb +98 -0
  217. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_role_profile.rb +56 -0
  218. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_role_profile_properties.rb +58 -0
  219. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_role_properties.rb +49 -0
  220. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_role_sku.rb +72 -0
  221. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_update.rb +55 -0
  222. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_upgrade_mode.rb +17 -0
  223. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_vault_and_secret_reference.rb +59 -0
  224. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_vault_certificate.rb +48 -0
  225. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/cloud_service_vault_secret_group.rb +69 -0
  226. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/extension.rb +58 -0
  227. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/inner_error.rb +57 -0
  228. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/instance_sku.rb +60 -0
  229. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/instance_view_statuses_summary.rb +56 -0
  230. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/instance_view_types.rb +15 -0
  231. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/load_balancer_configuration.rb +58 -0
  232. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/load_balancer_configuration_properties.rb +56 -0
  233. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/load_balancer_frontend_ipconfiguration.rb +59 -0
  234. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/load_balancer_frontend_ipconfiguration_properties.rb +72 -0
  235. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/resource_instance_view_status.rb +97 -0
  236. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/role_instance.rb +128 -0
  237. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/role_instance_instance_view.rb +95 -0
  238. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/role_instance_list_result.rb +98 -0
  239. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/role_instance_network_profile.rb +57 -0
  240. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/role_instance_properties.rb +60 -0
  241. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/role_instances.rb +55 -0
  242. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/status_code_count.rb +60 -0
  243. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/status_level_types.rb +17 -0
  244. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/sub_resource.rb +47 -0
  245. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/update_domain.rb +59 -0
  246. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/models/update_domain_list_result.rb +98 -0
  247. data/lib/2020-10-01-preview/generated/azure_mgmt_compute/module_definition.rb +9 -0
  248. data/lib/azure_mgmt_compute.rb +3 -0
  249. data/lib/profiles/latest/modules/compute_profile_module.rb +700 -468
  250. data/lib/version.rb +1 -1
  251. metadata +209 -2
@@ -28,12 +28,12 @@ module Azure::Compute::Mgmt::V2020_06_01
28
28
  # @param vm_scale_set_name [String] The name of the VM scale set.
29
29
  # @param instance_id [String] The instance ID of the virtual machine.
30
30
  # @param vm_extension_name [String] The name of the virtual machine extension.
31
- # @param extension_parameters [VirtualMachineExtension] Parameters supplied to
32
- # the Create Virtual Machine Extension operation.
31
+ # @param extension_parameters [VirtualMachineScaleSetVMExtension] Parameters
32
+ # supplied to the Create Virtual Machine Extension operation.
33
33
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
34
34
  # will be added to the HTTP request.
35
35
  #
36
- # @return [VirtualMachineExtension] operation results.
36
+ # @return [VirtualMachineScaleSetVMExtension] operation results.
37
37
  #
38
38
  def create_or_update(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:nil)
39
39
  response = create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:custom_headers).value!
@@ -45,8 +45,8 @@ module Azure::Compute::Mgmt::V2020_06_01
45
45
  # @param vm_scale_set_name [String] The name of the VM scale set.
46
46
  # @param instance_id [String] The instance ID of the virtual machine.
47
47
  # @param vm_extension_name [String] The name of the virtual machine extension.
48
- # @param extension_parameters [VirtualMachineExtension] Parameters supplied to
49
- # the Create Virtual Machine Extension operation.
48
+ # @param extension_parameters [VirtualMachineScaleSetVMExtension] Parameters
49
+ # supplied to the Create Virtual Machine Extension operation.
50
50
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
51
51
  # will be added to the HTTP request.
52
52
  #
@@ -60,7 +60,7 @@ module Azure::Compute::Mgmt::V2020_06_01
60
60
  promise = promise.then do |response|
61
61
  # Defining deserialization method.
62
62
  deserialize_method = lambda do |parsed_response|
63
- result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtension.mapper()
63
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtension.mapper()
64
64
  parsed_response = @client.deserialize(result_mapper, parsed_response)
65
65
  end
66
66
 
@@ -78,12 +78,12 @@ module Azure::Compute::Mgmt::V2020_06_01
78
78
  # @param vm_scale_set_name [String] The name of the VM scale set.
79
79
  # @param instance_id [String] The instance ID of the virtual machine.
80
80
  # @param vm_extension_name [String] The name of the virtual machine extension.
81
- # @param extension_parameters [VirtualMachineExtensionUpdate] Parameters
82
- # supplied to the Update Virtual Machine Extension operation.
81
+ # @param extension_parameters [VirtualMachineScaleSetVMExtensionUpdate]
82
+ # Parameters supplied to the Update Virtual Machine Extension operation.
83
83
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
84
84
  # will be added to the HTTP request.
85
85
  #
86
- # @return [VirtualMachineExtension] operation results.
86
+ # @return [VirtualMachineScaleSetVMExtension] operation results.
87
87
  #
88
88
  def update(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:nil)
89
89
  response = update_async(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:custom_headers).value!
@@ -95,8 +95,8 @@ module Azure::Compute::Mgmt::V2020_06_01
95
95
  # @param vm_scale_set_name [String] The name of the VM scale set.
96
96
  # @param instance_id [String] The instance ID of the virtual machine.
97
97
  # @param vm_extension_name [String] The name of the virtual machine extension.
98
- # @param extension_parameters [VirtualMachineExtensionUpdate] Parameters
99
- # supplied to the Update Virtual Machine Extension operation.
98
+ # @param extension_parameters [VirtualMachineScaleSetVMExtensionUpdate]
99
+ # Parameters supplied to the Update Virtual Machine Extension operation.
100
100
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
101
101
  # will be added to the HTTP request.
102
102
  #
@@ -110,7 +110,7 @@ module Azure::Compute::Mgmt::V2020_06_01
110
110
  promise = promise.then do |response|
111
111
  # Defining deserialization method.
112
112
  deserialize_method = lambda do |parsed_response|
113
- result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtension.mapper()
113
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtension.mapper()
114
114
  parsed_response = @client.deserialize(result_mapper, parsed_response)
115
115
  end
116
116
 
@@ -174,7 +174,7 @@ module Azure::Compute::Mgmt::V2020_06_01
174
174
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
175
175
  # will be added to the HTTP request.
176
176
  #
177
- # @return [VirtualMachineExtension] operation results.
177
+ # @return [VirtualMachineScaleSetVMExtension] operation results.
178
178
  #
179
179
  def get(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, expand:nil, custom_headers:nil)
180
180
  response = get_async(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, expand:expand, custom_headers:custom_headers).value!
@@ -255,7 +255,7 @@ module Azure::Compute::Mgmt::V2020_06_01
255
255
  if status_code == 200
256
256
  begin
257
257
  parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
258
- result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtension.mapper()
258
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtension.mapper()
259
259
  result.body = @client.deserialize(result_mapper, parsed_response)
260
260
  rescue Exception => e
261
261
  fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
@@ -279,7 +279,7 @@ module Azure::Compute::Mgmt::V2020_06_01
279
279
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
280
280
  # will be added to the HTTP request.
281
281
  #
282
- # @return [VirtualMachineExtensionsListResult] operation results.
282
+ # @return [VirtualMachineScaleSetVMExtensionsListResult] operation results.
283
283
  #
284
284
  def list(resource_group_name, vm_scale_set_name, instance_id, expand:nil, custom_headers:nil)
285
285
  response = list_async(resource_group_name, vm_scale_set_name, instance_id, expand:expand, custom_headers:custom_headers).value!
@@ -359,7 +359,7 @@ module Azure::Compute::Mgmt::V2020_06_01
359
359
  if status_code == 200
360
360
  begin
361
361
  parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
362
- result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtensionsListResult.mapper()
362
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtensionsListResult.mapper()
363
363
  result.body = @client.deserialize(result_mapper, parsed_response)
364
364
  rescue Exception => e
365
365
  fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
@@ -379,12 +379,12 @@ module Azure::Compute::Mgmt::V2020_06_01
379
379
  # @param vm_scale_set_name [String] The name of the VM scale set.
380
380
  # @param instance_id [String] The instance ID of the virtual machine.
381
381
  # @param vm_extension_name [String] The name of the virtual machine extension.
382
- # @param extension_parameters [VirtualMachineExtension] Parameters supplied to
383
- # the Create Virtual Machine Extension operation.
382
+ # @param extension_parameters [VirtualMachineScaleSetVMExtension] Parameters
383
+ # supplied to the Create Virtual Machine Extension operation.
384
384
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
385
385
  # will be added to the HTTP request.
386
386
  #
387
- # @return [VirtualMachineExtension] operation results.
387
+ # @return [VirtualMachineScaleSetVMExtension] operation results.
388
388
  #
389
389
  def begin_create_or_update(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:nil)
390
390
  response = begin_create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:custom_headers).value!
@@ -398,8 +398,8 @@ module Azure::Compute::Mgmt::V2020_06_01
398
398
  # @param vm_scale_set_name [String] The name of the VM scale set.
399
399
  # @param instance_id [String] The instance ID of the virtual machine.
400
400
  # @param vm_extension_name [String] The name of the virtual machine extension.
401
- # @param extension_parameters [VirtualMachineExtension] Parameters supplied to
402
- # the Create Virtual Machine Extension operation.
401
+ # @param extension_parameters [VirtualMachineScaleSetVMExtension] Parameters
402
+ # supplied to the Create Virtual Machine Extension operation.
403
403
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
404
404
  # will be added to the HTTP request.
405
405
  #
@@ -416,8 +416,8 @@ module Azure::Compute::Mgmt::V2020_06_01
416
416
  # @param vm_scale_set_name [String] The name of the VM scale set.
417
417
  # @param instance_id [String] The instance ID of the virtual machine.
418
418
  # @param vm_extension_name [String] The name of the virtual machine extension.
419
- # @param extension_parameters [VirtualMachineExtension] Parameters supplied to
420
- # the Create Virtual Machine Extension operation.
419
+ # @param extension_parameters [VirtualMachineScaleSetVMExtension] Parameters
420
+ # supplied to the Create Virtual Machine Extension operation.
421
421
  # @param [Hash{String => String}] A hash of custom headers that will be added
422
422
  # to the HTTP request.
423
423
  #
@@ -441,7 +441,7 @@ module Azure::Compute::Mgmt::V2020_06_01
441
441
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
442
442
 
443
443
  # Serialize Request
444
- request_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtension.mapper()
444
+ request_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtension.mapper()
445
445
  request_content = @client.serialize(request_mapper, extension_parameters)
446
446
  request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
447
447
 
@@ -475,7 +475,7 @@ module Azure::Compute::Mgmt::V2020_06_01
475
475
  if status_code == 200
476
476
  begin
477
477
  parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
478
- result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtension.mapper()
478
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtension.mapper()
479
479
  result.body = @client.deserialize(result_mapper, parsed_response)
480
480
  rescue Exception => e
481
481
  fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
@@ -485,7 +485,7 @@ module Azure::Compute::Mgmt::V2020_06_01
485
485
  if status_code == 201
486
486
  begin
487
487
  parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
488
- result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtension.mapper()
488
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtension.mapper()
489
489
  result.body = @client.deserialize(result_mapper, parsed_response)
490
490
  rescue Exception => e
491
491
  fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
@@ -505,12 +505,12 @@ module Azure::Compute::Mgmt::V2020_06_01
505
505
  # @param vm_scale_set_name [String] The name of the VM scale set.
506
506
  # @param instance_id [String] The instance ID of the virtual machine.
507
507
  # @param vm_extension_name [String] The name of the virtual machine extension.
508
- # @param extension_parameters [VirtualMachineExtensionUpdate] Parameters
509
- # supplied to the Update Virtual Machine Extension operation.
508
+ # @param extension_parameters [VirtualMachineScaleSetVMExtensionUpdate]
509
+ # Parameters supplied to the Update Virtual Machine Extension operation.
510
510
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
511
511
  # will be added to the HTTP request.
512
512
  #
513
- # @return [VirtualMachineExtension] operation results.
513
+ # @return [VirtualMachineScaleSetVMExtension] operation results.
514
514
  #
515
515
  def begin_update(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:nil)
516
516
  response = begin_update_async(resource_group_name, vm_scale_set_name, instance_id, vm_extension_name, extension_parameters, custom_headers:custom_headers).value!
@@ -524,8 +524,8 @@ module Azure::Compute::Mgmt::V2020_06_01
524
524
  # @param vm_scale_set_name [String] The name of the VM scale set.
525
525
  # @param instance_id [String] The instance ID of the virtual machine.
526
526
  # @param vm_extension_name [String] The name of the virtual machine extension.
527
- # @param extension_parameters [VirtualMachineExtensionUpdate] Parameters
528
- # supplied to the Update Virtual Machine Extension operation.
527
+ # @param extension_parameters [VirtualMachineScaleSetVMExtensionUpdate]
528
+ # Parameters supplied to the Update Virtual Machine Extension operation.
529
529
  # @param custom_headers [Hash{String => String}] A hash of custom headers that
530
530
  # will be added to the HTTP request.
531
531
  #
@@ -542,8 +542,8 @@ module Azure::Compute::Mgmt::V2020_06_01
542
542
  # @param vm_scale_set_name [String] The name of the VM scale set.
543
543
  # @param instance_id [String] The instance ID of the virtual machine.
544
544
  # @param vm_extension_name [String] The name of the virtual machine extension.
545
- # @param extension_parameters [VirtualMachineExtensionUpdate] Parameters
546
- # supplied to the Update Virtual Machine Extension operation.
545
+ # @param extension_parameters [VirtualMachineScaleSetVMExtensionUpdate]
546
+ # Parameters supplied to the Update Virtual Machine Extension operation.
547
547
  # @param [Hash{String => String}] A hash of custom headers that will be added
548
548
  # to the HTTP request.
549
549
  #
@@ -567,7 +567,7 @@ module Azure::Compute::Mgmt::V2020_06_01
567
567
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
568
568
 
569
569
  # Serialize Request
570
- request_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtensionUpdate.mapper()
570
+ request_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtensionUpdate.mapper()
571
571
  request_content = @client.serialize(request_mapper, extension_parameters)
572
572
  request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
573
573
 
@@ -601,7 +601,7 @@ module Azure::Compute::Mgmt::V2020_06_01
601
601
  if status_code == 200
602
602
  begin
603
603
  parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
604
- result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineExtension.mapper()
604
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineScaleSetVMExtension.mapper()
605
605
  result.body = @client.deserialize(result_mapper, parsed_response)
606
606
  rescue Exception => e
607
607
  fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
@@ -0,0 +1,827 @@
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::Compute::Mgmt::V2020_06_01
7
+ #
8
+ # Compute Client
9
+ #
10
+ class VirtualMachineScaleSetVMRunCommands
11
+ include MsRestAzure
12
+
13
+ #
14
+ # Creates and initializes a new instance of the VirtualMachineScaleSetVMRunCommands class.
15
+ # @param client service class for accessing basic functionality.
16
+ #
17
+ def initialize(client)
18
+ @client = client
19
+ end
20
+
21
+ # @return [ComputeManagementClient] reference to the ComputeManagementClient
22
+ attr_reader :client
23
+
24
+ #
25
+ # The operation to create or update the VMSS VM run command.
26
+ #
27
+ # @param resource_group_name [String] The name of the resource group.
28
+ # @param vm_scale_set_name [String] The name of the VM scale set.
29
+ # @param instance_id [String] The instance ID of the virtual machine.
30
+ # @param run_command_name [String] The name of the virtual machine run command.
31
+ # @param run_command [VirtualMachineRunCommand] Parameters supplied to the
32
+ # Create Virtual Machine RunCommand operation.
33
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
34
+ # will be added to the HTTP request.
35
+ #
36
+ # @return [VirtualMachineRunCommand] operation results.
37
+ #
38
+ def create_or_update(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
39
+ response = create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers).value!
40
+ response.body unless response.nil?
41
+ end
42
+
43
+ #
44
+ # @param resource_group_name [String] The name of the resource group.
45
+ # @param vm_scale_set_name [String] The name of the VM scale set.
46
+ # @param instance_id [String] The instance ID of the virtual machine.
47
+ # @param run_command_name [String] The name of the virtual machine run command.
48
+ # @param run_command [VirtualMachineRunCommand] Parameters supplied to the
49
+ # Create Virtual Machine RunCommand operation.
50
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
51
+ # will be added to the HTTP request.
52
+ #
53
+ # @return [Concurrent::Promise] promise which provides async access to http
54
+ # response.
55
+ #
56
+ def create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
57
+ # Send request
58
+ promise = begin_create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers)
59
+
60
+ promise = promise.then do |response|
61
+ # Defining deserialization method.
62
+ deserialize_method = lambda do |parsed_response|
63
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommand.mapper()
64
+ parsed_response = @client.deserialize(result_mapper, parsed_response)
65
+ end
66
+
67
+ # Waiting for response.
68
+ @client.get_long_running_operation_result(response, deserialize_method)
69
+ end
70
+
71
+ promise
72
+ end
73
+
74
+ #
75
+ # The operation to update the VMSS VM run command.
76
+ #
77
+ # @param resource_group_name [String] The name of the resource group.
78
+ # @param vm_scale_set_name [String] The name of the VM scale set.
79
+ # @param instance_id [String] The instance ID of the virtual machine.
80
+ # @param run_command_name [String] The name of the virtual machine run command.
81
+ # @param run_command [VirtualMachineRunCommandUpdate] Parameters supplied to
82
+ # the Update Virtual Machine RunCommand operation.
83
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
84
+ # will be added to the HTTP request.
85
+ #
86
+ # @return [VirtualMachineRunCommand] operation results.
87
+ #
88
+ def update(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
89
+ response = update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers).value!
90
+ response.body unless response.nil?
91
+ end
92
+
93
+ #
94
+ # @param resource_group_name [String] The name of the resource group.
95
+ # @param vm_scale_set_name [String] The name of the VM scale set.
96
+ # @param instance_id [String] The instance ID of the virtual machine.
97
+ # @param run_command_name [String] The name of the virtual machine run command.
98
+ # @param run_command [VirtualMachineRunCommandUpdate] Parameters supplied to
99
+ # the Update Virtual Machine RunCommand operation.
100
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
101
+ # will be added to the HTTP request.
102
+ #
103
+ # @return [Concurrent::Promise] promise which provides async access to http
104
+ # response.
105
+ #
106
+ def update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
107
+ # Send request
108
+ promise = begin_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers)
109
+
110
+ promise = promise.then do |response|
111
+ # Defining deserialization method.
112
+ deserialize_method = lambda do |parsed_response|
113
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommand.mapper()
114
+ parsed_response = @client.deserialize(result_mapper, parsed_response)
115
+ end
116
+
117
+ # Waiting for response.
118
+ @client.get_long_running_operation_result(response, deserialize_method)
119
+ end
120
+
121
+ promise
122
+ end
123
+
124
+ #
125
+ # The operation to delete the VMSS VM run command.
126
+ #
127
+ # @param resource_group_name [String] The name of the resource group.
128
+ # @param vm_scale_set_name [String] The name of the VM scale set.
129
+ # @param instance_id [String] The instance ID of the virtual machine.
130
+ # @param run_command_name [String] The name of the virtual machine run command.
131
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
132
+ # will be added to the HTTP request.
133
+ #
134
+ def delete(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:nil)
135
+ response = delete_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:custom_headers).value!
136
+ nil
137
+ end
138
+
139
+ #
140
+ # @param resource_group_name [String] The name of the resource group.
141
+ # @param vm_scale_set_name [String] The name of the VM scale set.
142
+ # @param instance_id [String] The instance ID of the virtual machine.
143
+ # @param run_command_name [String] The name of the virtual machine run command.
144
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
145
+ # will be added to the HTTP request.
146
+ #
147
+ # @return [Concurrent::Promise] promise which provides async access to http
148
+ # response.
149
+ #
150
+ def delete_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:nil)
151
+ # Send request
152
+ promise = begin_delete_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:custom_headers)
153
+
154
+ promise = promise.then do |response|
155
+ # Defining deserialization method.
156
+ deserialize_method = lambda do |parsed_response|
157
+ end
158
+
159
+ # Waiting for response.
160
+ @client.get_long_running_operation_result(response, deserialize_method)
161
+ end
162
+
163
+ promise
164
+ end
165
+
166
+ #
167
+ # The operation to get the VMSS VM run command.
168
+ #
169
+ # @param resource_group_name [String] The name of the resource group.
170
+ # @param vm_scale_set_name [String] The name of the VM scale set.
171
+ # @param instance_id [String] The instance ID of the virtual machine.
172
+ # @param run_command_name [String] The name of the virtual machine run command.
173
+ # @param expand [String] The expand expression to apply on the operation.
174
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
175
+ # will be added to the HTTP request.
176
+ #
177
+ # @return [VirtualMachineRunCommand] operation results.
178
+ #
179
+ def get(resource_group_name, vm_scale_set_name, instance_id, run_command_name, expand:nil, custom_headers:nil)
180
+ response = get_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, expand:expand, custom_headers:custom_headers).value!
181
+ response.body unless response.nil?
182
+ end
183
+
184
+ #
185
+ # The operation to get the VMSS VM run command.
186
+ #
187
+ # @param resource_group_name [String] The name of the resource group.
188
+ # @param vm_scale_set_name [String] The name of the VM scale set.
189
+ # @param instance_id [String] The instance ID of the virtual machine.
190
+ # @param run_command_name [String] The name of the virtual machine run command.
191
+ # @param expand [String] The expand expression to apply on the operation.
192
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
193
+ # will be added to the HTTP request.
194
+ #
195
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
196
+ #
197
+ def get_with_http_info(resource_group_name, vm_scale_set_name, instance_id, run_command_name, expand:nil, custom_headers:nil)
198
+ get_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, expand:expand, custom_headers:custom_headers).value!
199
+ end
200
+
201
+ #
202
+ # The operation to get the VMSS VM run command.
203
+ #
204
+ # @param resource_group_name [String] The name of the resource group.
205
+ # @param vm_scale_set_name [String] The name of the VM scale set.
206
+ # @param instance_id [String] The instance ID of the virtual machine.
207
+ # @param run_command_name [String] The name of the virtual machine run command.
208
+ # @param expand [String] The expand expression to apply on the operation.
209
+ # @param [Hash{String => String}] A hash of custom headers that will be added
210
+ # to the HTTP request.
211
+ #
212
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
213
+ #
214
+ def get_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, expand:nil, custom_headers:nil)
215
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
216
+ fail ArgumentError, 'vm_scale_set_name is nil' if vm_scale_set_name.nil?
217
+ fail ArgumentError, 'instance_id is nil' if instance_id.nil?
218
+ fail ArgumentError, 'run_command_name is nil' if run_command_name.nil?
219
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
220
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
221
+
222
+
223
+ request_headers = {}
224
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
225
+
226
+ # Set Headers
227
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
228
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
229
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/runCommands/{runCommandName}'
230
+
231
+ request_url = @base_url || @client.base_url
232
+
233
+ options = {
234
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
235
+ path_params: {'resourceGroupName' => resource_group_name,'vmScaleSetName' => vm_scale_set_name,'instanceId' => instance_id,'runCommandName' => run_command_name,'subscriptionId' => @client.subscription_id},
236
+ query_params: {'$expand' => expand,'api-version' => @client.api_version},
237
+ headers: request_headers.merge(custom_headers || {}),
238
+ base_url: request_url
239
+ }
240
+ promise = @client.make_request_async(:get, path_template, options)
241
+
242
+ promise = promise.then do |result|
243
+ http_response = result.response
244
+ status_code = http_response.status
245
+ response_content = http_response.body
246
+ unless status_code == 200
247
+ error_model = JSON.load(response_content)
248
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
249
+ end
250
+
251
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
252
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
253
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
254
+ # Deserialize Response
255
+ if status_code == 200
256
+ begin
257
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
258
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommand.mapper()
259
+ result.body = @client.deserialize(result_mapper, parsed_response)
260
+ rescue Exception => e
261
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
262
+ end
263
+ end
264
+
265
+ result
266
+ end
267
+
268
+ promise.execute
269
+ end
270
+
271
+ #
272
+ # The operation to get all run commands of an instance in Virtual Machine
273
+ # Scaleset.
274
+ #
275
+ # @param resource_group_name [String] The name of the resource group.
276
+ # @param vm_scale_set_name [String] The name of the VM scale set.
277
+ # @param instance_id [String] The instance ID of the virtual machine.
278
+ # @param expand [String] The expand expression to apply on the operation.
279
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
280
+ # will be added to the HTTP request.
281
+ #
282
+ # @return [Array<VirtualMachineRunCommand>] operation results.
283
+ #
284
+ def list(resource_group_name, vm_scale_set_name, instance_id, expand:nil, custom_headers:nil)
285
+ first_page = list_as_lazy(resource_group_name, vm_scale_set_name, instance_id, expand:expand, custom_headers:custom_headers)
286
+ first_page.get_all_items
287
+ end
288
+
289
+ #
290
+ # The operation to get all run commands of an instance in Virtual Machine
291
+ # Scaleset.
292
+ #
293
+ # @param resource_group_name [String] The name of the resource group.
294
+ # @param vm_scale_set_name [String] The name of the VM scale set.
295
+ # @param instance_id [String] The instance ID of the virtual machine.
296
+ # @param expand [String] The expand expression to apply on the operation.
297
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
298
+ # will be added to the HTTP request.
299
+ #
300
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
301
+ #
302
+ def list_with_http_info(resource_group_name, vm_scale_set_name, instance_id, expand:nil, custom_headers:nil)
303
+ list_async(resource_group_name, vm_scale_set_name, instance_id, expand:expand, custom_headers:custom_headers).value!
304
+ end
305
+
306
+ #
307
+ # The operation to get all run commands of an instance in Virtual Machine
308
+ # Scaleset.
309
+ #
310
+ # @param resource_group_name [String] The name of the resource group.
311
+ # @param vm_scale_set_name [String] The name of the VM scale set.
312
+ # @param instance_id [String] The instance ID of the virtual machine.
313
+ # @param expand [String] The expand expression to apply on the operation.
314
+ # @param [Hash{String => String}] A hash of custom headers that will be added
315
+ # to the HTTP request.
316
+ #
317
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
318
+ #
319
+ def list_async(resource_group_name, vm_scale_set_name, instance_id, expand:nil, custom_headers:nil)
320
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
321
+ fail ArgumentError, 'vm_scale_set_name is nil' if vm_scale_set_name.nil?
322
+ fail ArgumentError, 'instance_id is nil' if instance_id.nil?
323
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
324
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
325
+
326
+
327
+ request_headers = {}
328
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
329
+
330
+ # Set Headers
331
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
332
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
333
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/runCommands'
334
+
335
+ request_url = @base_url || @client.base_url
336
+
337
+ options = {
338
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
339
+ path_params: {'resourceGroupName' => resource_group_name,'vmScaleSetName' => vm_scale_set_name,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id},
340
+ query_params: {'$expand' => expand,'api-version' => @client.api_version},
341
+ headers: request_headers.merge(custom_headers || {}),
342
+ base_url: request_url
343
+ }
344
+ promise = @client.make_request_async(:get, path_template, options)
345
+
346
+ promise = promise.then do |result|
347
+ http_response = result.response
348
+ status_code = http_response.status
349
+ response_content = http_response.body
350
+ unless status_code == 200
351
+ error_model = JSON.load(response_content)
352
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
353
+ end
354
+
355
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
356
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
357
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
358
+ # Deserialize Response
359
+ if status_code == 200
360
+ begin
361
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
362
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommandsListResult.mapper()
363
+ result.body = @client.deserialize(result_mapper, parsed_response)
364
+ rescue Exception => e
365
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
366
+ end
367
+ end
368
+
369
+ result
370
+ end
371
+
372
+ promise.execute
373
+ end
374
+
375
+ #
376
+ # The operation to create or update the VMSS VM run command.
377
+ #
378
+ # @param resource_group_name [String] The name of the resource group.
379
+ # @param vm_scale_set_name [String] The name of the VM scale set.
380
+ # @param instance_id [String] The instance ID of the virtual machine.
381
+ # @param run_command_name [String] The name of the virtual machine run command.
382
+ # @param run_command [VirtualMachineRunCommand] Parameters supplied to the
383
+ # Create Virtual Machine RunCommand operation.
384
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
385
+ # will be added to the HTTP request.
386
+ #
387
+ # @return [VirtualMachineRunCommand] operation results.
388
+ #
389
+ def begin_create_or_update(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
390
+ response = begin_create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers).value!
391
+ response.body unless response.nil?
392
+ end
393
+
394
+ #
395
+ # The operation to create or update the VMSS VM run command.
396
+ #
397
+ # @param resource_group_name [String] The name of the resource group.
398
+ # @param vm_scale_set_name [String] The name of the VM scale set.
399
+ # @param instance_id [String] The instance ID of the virtual machine.
400
+ # @param run_command_name [String] The name of the virtual machine run command.
401
+ # @param run_command [VirtualMachineRunCommand] Parameters supplied to the
402
+ # Create Virtual Machine RunCommand operation.
403
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
404
+ # will be added to the HTTP request.
405
+ #
406
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
407
+ #
408
+ def begin_create_or_update_with_http_info(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
409
+ begin_create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers).value!
410
+ end
411
+
412
+ #
413
+ # The operation to create or update the VMSS VM run command.
414
+ #
415
+ # @param resource_group_name [String] The name of the resource group.
416
+ # @param vm_scale_set_name [String] The name of the VM scale set.
417
+ # @param instance_id [String] The instance ID of the virtual machine.
418
+ # @param run_command_name [String] The name of the virtual machine run command.
419
+ # @param run_command [VirtualMachineRunCommand] Parameters supplied to the
420
+ # Create Virtual Machine RunCommand operation.
421
+ # @param [Hash{String => String}] A hash of custom headers that will be added
422
+ # to the HTTP request.
423
+ #
424
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
425
+ #
426
+ def begin_create_or_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
427
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
428
+ fail ArgumentError, 'vm_scale_set_name is nil' if vm_scale_set_name.nil?
429
+ fail ArgumentError, 'instance_id is nil' if instance_id.nil?
430
+ fail ArgumentError, 'run_command_name is nil' if run_command_name.nil?
431
+ fail ArgumentError, 'run_command is nil' if run_command.nil?
432
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
433
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
434
+
435
+
436
+ request_headers = {}
437
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
438
+
439
+ # Set Headers
440
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
441
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
442
+
443
+ # Serialize Request
444
+ request_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommand.mapper()
445
+ request_content = @client.serialize(request_mapper, run_command)
446
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
447
+
448
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/runCommands/{runCommandName}'
449
+
450
+ request_url = @base_url || @client.base_url
451
+
452
+ options = {
453
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
454
+ path_params: {'resourceGroupName' => resource_group_name,'vmScaleSetName' => vm_scale_set_name,'instanceId' => instance_id,'runCommandName' => run_command_name,'subscriptionId' => @client.subscription_id},
455
+ query_params: {'api-version' => @client.api_version},
456
+ body: request_content,
457
+ headers: request_headers.merge(custom_headers || {}),
458
+ base_url: request_url
459
+ }
460
+ promise = @client.make_request_async(:put, path_template, options)
461
+
462
+ promise = promise.then do |result|
463
+ http_response = result.response
464
+ status_code = http_response.status
465
+ response_content = http_response.body
466
+ unless status_code == 200 || status_code == 201
467
+ error_model = JSON.load(response_content)
468
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
469
+ end
470
+
471
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
472
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
473
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
474
+ # Deserialize Response
475
+ if status_code == 200
476
+ begin
477
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
478
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommand.mapper()
479
+ result.body = @client.deserialize(result_mapper, parsed_response)
480
+ rescue Exception => e
481
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
482
+ end
483
+ end
484
+ # Deserialize Response
485
+ if status_code == 201
486
+ begin
487
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
488
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommand.mapper()
489
+ result.body = @client.deserialize(result_mapper, parsed_response)
490
+ rescue Exception => e
491
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
492
+ end
493
+ end
494
+
495
+ result
496
+ end
497
+
498
+ promise.execute
499
+ end
500
+
501
+ #
502
+ # The operation to update the VMSS VM run command.
503
+ #
504
+ # @param resource_group_name [String] The name of the resource group.
505
+ # @param vm_scale_set_name [String] The name of the VM scale set.
506
+ # @param instance_id [String] The instance ID of the virtual machine.
507
+ # @param run_command_name [String] The name of the virtual machine run command.
508
+ # @param run_command [VirtualMachineRunCommandUpdate] Parameters supplied to
509
+ # the Update Virtual Machine RunCommand operation.
510
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
511
+ # will be added to the HTTP request.
512
+ #
513
+ # @return [VirtualMachineRunCommand] operation results.
514
+ #
515
+ def begin_update(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
516
+ response = begin_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers).value!
517
+ response.body unless response.nil?
518
+ end
519
+
520
+ #
521
+ # The operation to update the VMSS VM run command.
522
+ #
523
+ # @param resource_group_name [String] The name of the resource group.
524
+ # @param vm_scale_set_name [String] The name of the VM scale set.
525
+ # @param instance_id [String] The instance ID of the virtual machine.
526
+ # @param run_command_name [String] The name of the virtual machine run command.
527
+ # @param run_command [VirtualMachineRunCommandUpdate] Parameters supplied to
528
+ # the Update Virtual Machine RunCommand operation.
529
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
530
+ # will be added to the HTTP request.
531
+ #
532
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
533
+ #
534
+ def begin_update_with_http_info(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
535
+ begin_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:custom_headers).value!
536
+ end
537
+
538
+ #
539
+ # The operation to update the VMSS VM run command.
540
+ #
541
+ # @param resource_group_name [String] The name of the resource group.
542
+ # @param vm_scale_set_name [String] The name of the VM scale set.
543
+ # @param instance_id [String] The instance ID of the virtual machine.
544
+ # @param run_command_name [String] The name of the virtual machine run command.
545
+ # @param run_command [VirtualMachineRunCommandUpdate] Parameters supplied to
546
+ # the Update Virtual Machine RunCommand operation.
547
+ # @param [Hash{String => String}] A hash of custom headers that will be added
548
+ # to the HTTP request.
549
+ #
550
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
551
+ #
552
+ def begin_update_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, run_command, custom_headers:nil)
553
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
554
+ fail ArgumentError, 'vm_scale_set_name is nil' if vm_scale_set_name.nil?
555
+ fail ArgumentError, 'instance_id is nil' if instance_id.nil?
556
+ fail ArgumentError, 'run_command_name is nil' if run_command_name.nil?
557
+ fail ArgumentError, 'run_command is nil' if run_command.nil?
558
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
559
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
560
+
561
+
562
+ request_headers = {}
563
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
564
+
565
+ # Set Headers
566
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
567
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
568
+
569
+ # Serialize Request
570
+ request_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommandUpdate.mapper()
571
+ request_content = @client.serialize(request_mapper, run_command)
572
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
573
+
574
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/runCommands/{runCommandName}'
575
+
576
+ request_url = @base_url || @client.base_url
577
+
578
+ options = {
579
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
580
+ path_params: {'resourceGroupName' => resource_group_name,'vmScaleSetName' => vm_scale_set_name,'instanceId' => instance_id,'runCommandName' => run_command_name,'subscriptionId' => @client.subscription_id},
581
+ query_params: {'api-version' => @client.api_version},
582
+ body: request_content,
583
+ headers: request_headers.merge(custom_headers || {}),
584
+ base_url: request_url
585
+ }
586
+ promise = @client.make_request_async(:patch, path_template, options)
587
+
588
+ promise = promise.then do |result|
589
+ http_response = result.response
590
+ status_code = http_response.status
591
+ response_content = http_response.body
592
+ unless status_code == 200
593
+ error_model = JSON.load(response_content)
594
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
595
+ end
596
+
597
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
598
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
599
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
600
+ # Deserialize Response
601
+ if status_code == 200
602
+ begin
603
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
604
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommand.mapper()
605
+ result.body = @client.deserialize(result_mapper, parsed_response)
606
+ rescue Exception => e
607
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
608
+ end
609
+ end
610
+
611
+ result
612
+ end
613
+
614
+ promise.execute
615
+ end
616
+
617
+ #
618
+ # The operation to delete the VMSS VM run command.
619
+ #
620
+ # @param resource_group_name [String] The name of the resource group.
621
+ # @param vm_scale_set_name [String] The name of the VM scale set.
622
+ # @param instance_id [String] The instance ID of the virtual machine.
623
+ # @param run_command_name [String] The name of the virtual machine run command.
624
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
625
+ # will be added to the HTTP request.
626
+ #
627
+ #
628
+ def begin_delete(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:nil)
629
+ response = begin_delete_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:custom_headers).value!
630
+ nil
631
+ end
632
+
633
+ #
634
+ # The operation to delete the VMSS VM run command.
635
+ #
636
+ # @param resource_group_name [String] The name of the resource group.
637
+ # @param vm_scale_set_name [String] The name of the VM scale set.
638
+ # @param instance_id [String] The instance ID of the virtual machine.
639
+ # @param run_command_name [String] The name of the virtual machine run command.
640
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
641
+ # will be added to the HTTP request.
642
+ #
643
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
644
+ #
645
+ def begin_delete_with_http_info(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:nil)
646
+ begin_delete_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:custom_headers).value!
647
+ end
648
+
649
+ #
650
+ # The operation to delete the VMSS VM run command.
651
+ #
652
+ # @param resource_group_name [String] The name of the resource group.
653
+ # @param vm_scale_set_name [String] The name of the VM scale set.
654
+ # @param instance_id [String] The instance ID of the virtual machine.
655
+ # @param run_command_name [String] The name of the virtual machine run command.
656
+ # @param [Hash{String => String}] A hash of custom headers that will be added
657
+ # to the HTTP request.
658
+ #
659
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
660
+ #
661
+ def begin_delete_async(resource_group_name, vm_scale_set_name, instance_id, run_command_name, custom_headers:nil)
662
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
663
+ fail ArgumentError, 'vm_scale_set_name is nil' if vm_scale_set_name.nil?
664
+ fail ArgumentError, 'instance_id is nil' if instance_id.nil?
665
+ fail ArgumentError, 'run_command_name is nil' if run_command_name.nil?
666
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
667
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
668
+
669
+
670
+ request_headers = {}
671
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
672
+
673
+ # Set Headers
674
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
675
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
676
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/runCommands/{runCommandName}'
677
+
678
+ request_url = @base_url || @client.base_url
679
+
680
+ options = {
681
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
682
+ path_params: {'resourceGroupName' => resource_group_name,'vmScaleSetName' => vm_scale_set_name,'instanceId' => instance_id,'runCommandName' => run_command_name,'subscriptionId' => @client.subscription_id},
683
+ query_params: {'api-version' => @client.api_version},
684
+ headers: request_headers.merge(custom_headers || {}),
685
+ base_url: request_url
686
+ }
687
+ promise = @client.make_request_async(:delete, path_template, options)
688
+
689
+ promise = promise.then do |result|
690
+ http_response = result.response
691
+ status_code = http_response.status
692
+ response_content = http_response.body
693
+ unless status_code == 200 || status_code == 202 || status_code == 204
694
+ error_model = JSON.load(response_content)
695
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
696
+ end
697
+
698
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
699
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
700
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
701
+
702
+ result
703
+ end
704
+
705
+ promise.execute
706
+ end
707
+
708
+ #
709
+ # The operation to get all run commands of an instance in Virtual Machine
710
+ # Scaleset.
711
+ #
712
+ # @param next_page_link [String] The NextLink from the previous successful call
713
+ # to List operation.
714
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
715
+ # will be added to the HTTP request.
716
+ #
717
+ # @return [VirtualMachineRunCommandsListResult] operation results.
718
+ #
719
+ def list_next(next_page_link, custom_headers:nil)
720
+ response = list_next_async(next_page_link, custom_headers:custom_headers).value!
721
+ response.body unless response.nil?
722
+ end
723
+
724
+ #
725
+ # The operation to get all run commands of an instance in Virtual Machine
726
+ # Scaleset.
727
+ #
728
+ # @param next_page_link [String] The NextLink from the previous successful call
729
+ # to List operation.
730
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
731
+ # will be added to the HTTP request.
732
+ #
733
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
734
+ #
735
+ def list_next_with_http_info(next_page_link, custom_headers:nil)
736
+ list_next_async(next_page_link, custom_headers:custom_headers).value!
737
+ end
738
+
739
+ #
740
+ # The operation to get all run commands of an instance in Virtual Machine
741
+ # Scaleset.
742
+ #
743
+ # @param next_page_link [String] The NextLink from the previous successful call
744
+ # to List operation.
745
+ # @param [Hash{String => String}] A hash of custom headers that will be added
746
+ # to the HTTP request.
747
+ #
748
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
749
+ #
750
+ def list_next_async(next_page_link, custom_headers:nil)
751
+ fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
752
+
753
+
754
+ request_headers = {}
755
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
756
+
757
+ # Set Headers
758
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
759
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
760
+ path_template = '{nextLink}'
761
+
762
+ request_url = @base_url || @client.base_url
763
+
764
+ options = {
765
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
766
+ skip_encoding_path_params: {'nextLink' => next_page_link},
767
+ headers: request_headers.merge(custom_headers || {}),
768
+ base_url: request_url
769
+ }
770
+ promise = @client.make_request_async(:get, path_template, options)
771
+
772
+ promise = promise.then do |result|
773
+ http_response = result.response
774
+ status_code = http_response.status
775
+ response_content = http_response.body
776
+ unless status_code == 200
777
+ error_model = JSON.load(response_content)
778
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
779
+ end
780
+
781
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
782
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
783
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
784
+ # Deserialize Response
785
+ if status_code == 200
786
+ begin
787
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
788
+ result_mapper = Azure::Compute::Mgmt::V2020_06_01::Models::VirtualMachineRunCommandsListResult.mapper()
789
+ result.body = @client.deserialize(result_mapper, parsed_response)
790
+ rescue Exception => e
791
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
792
+ end
793
+ end
794
+
795
+ result
796
+ end
797
+
798
+ promise.execute
799
+ end
800
+
801
+ #
802
+ # The operation to get all run commands of an instance in Virtual Machine
803
+ # Scaleset.
804
+ #
805
+ # @param resource_group_name [String] The name of the resource group.
806
+ # @param vm_scale_set_name [String] The name of the VM scale set.
807
+ # @param instance_id [String] The instance ID of the virtual machine.
808
+ # @param expand [String] The expand expression to apply on the operation.
809
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
810
+ # will be added to the HTTP request.
811
+ #
812
+ # @return [VirtualMachineRunCommandsListResult] which provide lazy access to
813
+ # pages of the response.
814
+ #
815
+ def list_as_lazy(resource_group_name, vm_scale_set_name, instance_id, expand:nil, custom_headers:nil)
816
+ response = list_async(resource_group_name, vm_scale_set_name, instance_id, expand:expand, custom_headers:custom_headers).value!
817
+ unless response.nil?
818
+ page = response.body
819
+ page.next_method = Proc.new do |next_page_link|
820
+ list_next_async(next_page_link, custom_headers:custom_headers)
821
+ end
822
+ page
823
+ end
824
+ end
825
+
826
+ end
827
+ end