From ab764aed138fac80656901e03a74d5285e1d44da Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Tue, 6 Feb 2018 06:48:24 +0000 Subject: [PATCH] Generated from 9433e424101ce63ff084cda49c706fd354f73724 added missing Swagger --- .../operations/disks_operations.py | 36 ++- .../operations/disks_operations.py | 36 ++- .../operations/snapshots_operations.py | 36 ++- .../v2017_12_01/compute_management_client.py | 10 + .../compute/v2017_12_01/models/__init__.py | 18 ++ .../models/compute_management_client_enums.py | 77 +++++ .../models/compute_operation_list_result.py | 29 ++ .../models/compute_operation_value.py | 58 ++++ .../compute/v2017_12_01/models/data_disk.py | 7 +- .../v2017_12_01/models/hardware_profile.py | 80 +++-- .../models/log_analytics_input_base.py | 56 ++++ .../models/log_analytics_operation_result.py | 56 ++++ .../models/log_analytics_output.py | 35 +++ .../compute/v2017_12_01/models/os_disk.py | 7 +- .../models/recovery_walk_response.py | 41 +++ .../models/request_rate_by_interval_input.py | 58 ++++ .../models/throttled_requests_input.py | 41 +++ .../models/virtual_machine_instance_view.py | 15 +- .../virtual_machine_scale_set_data_disk.py | 7 +- .../virtual_machine_scale_set_os_disk.py | 7 +- ...irtual_machine_scale_set_update_os_disk.py | 7 +- .../v2017_12_01/operations/__init__.py | 4 + .../availability_sets_operations.py | 69 +++++ .../operations/compute_operations.py | 90 ++++++ .../operations/images_operations.py | 119 ++++++++ .../operations/log_analytics_operations.py | 274 ++++++++++++++++++ .../virtual_machine_scale_sets_operations.py | 66 +++++ .../operations/virtual_machines_operations.py | 121 ++++++++ 28 files changed, 1389 insertions(+), 71 deletions(-) create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_list_result.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_value.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_input_base.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_operation_result.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_output.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/recovery_walk_response.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/request_rate_by_interval_input.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/throttled_requests_input.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/compute_operations.py create mode 100644 azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/log_analytics_operations.py diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2016_04_30_preview/operations/disks_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2016_04_30_preview/operations/disks_operations.py index 3ee227fe67e8..2293337205e8 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2016_04_30_preview/operations/disks_operations.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2016_04_30_preview/operations/disks_operations.py @@ -97,8 +97,10 @@ def create_or_update( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param disk: Disk object supplied in the body of the Put disk operation. @@ -218,8 +220,10 @@ def update( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param disk: Disk object supplied in the body of the Patch disk operation. @@ -287,8 +291,10 @@ def get( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -395,8 +401,10 @@ def delete( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -643,8 +651,10 @@ def grant_access( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param access: Possible values include: 'None', 'Read' :type access: str or @@ -762,8 +772,10 @@ def revoke_access( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/disks_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/disks_operations.py index bb16a26d1707..65a50ecf6902 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/disks_operations.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/disks_operations.py @@ -97,8 +97,10 @@ def create_or_update( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param disk: Disk object supplied in the body of the Put disk operation. @@ -218,8 +220,10 @@ def update( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param disk: Disk object supplied in the body of the Patch disk operation. @@ -287,8 +291,10 @@ def get( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -395,8 +401,10 @@ def delete( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -643,8 +651,10 @@ def grant_access( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param access: Possible values include: 'None', 'Read' :type access: str or @@ -762,8 +772,10 @@ def revoke_access( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param disk_name: The name of the disk within the given subscription - and resource group. + :param disk_name: The name of the managed disk that is being created. + The name can't be changed after the disk is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The maximum name + length is 80 characters. :type disk_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/snapshots_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/snapshots_operations.py index ad0291d164ff..3a1e8eeb85d3 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/snapshots_operations.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_03_30/operations/snapshots_operations.py @@ -97,8 +97,10 @@ def create_or_update( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param snapshot_name: The name of the snapshot within the given - subscription and resource group. + :param snapshot_name: The name of the snapshot that is being created. + The name can't be changed after the snapshot is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The max name length + is 80 characters. :type snapshot_name: str :param snapshot: Snapshot object supplied in the body of the Put disk operation. @@ -218,8 +220,10 @@ def update( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param snapshot_name: The name of the snapshot within the given - subscription and resource group. + :param snapshot_name: The name of the snapshot that is being created. + The name can't be changed after the snapshot is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The max name length + is 80 characters. :type snapshot_name: str :param snapshot: Snapshot object supplied in the body of the Patch snapshot operation. @@ -287,8 +291,10 @@ def get( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param snapshot_name: The name of the snapshot within the given - subscription and resource group. + :param snapshot_name: The name of the snapshot that is being created. + The name can't be changed after the snapshot is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The max name length + is 80 characters. :type snapshot_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -395,8 +401,10 @@ def delete( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param snapshot_name: The name of the snapshot within the given - subscription and resource group. + :param snapshot_name: The name of the snapshot that is being created. + The name can't be changed after the snapshot is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The max name length + is 80 characters. :type snapshot_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -643,8 +651,10 @@ def grant_access( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param snapshot_name: The name of the snapshot within the given - subscription and resource group. + :param snapshot_name: The name of the snapshot that is being created. + The name can't be changed after the snapshot is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The max name length + is 80 characters. :type snapshot_name: str :param access: Possible values include: 'None', 'Read' :type access: str or @@ -762,8 +772,10 @@ def revoke_access( :param resource_group_name: The name of the resource group. :type resource_group_name: str - :param snapshot_name: The name of the snapshot within the given - subscription and resource group. + :param snapshot_name: The name of the snapshot that is being created. + The name can't be changed after the snapshot is created. Supported + characters for the name are a-z, A-Z, 0-9 and _. The max name length + is 80 characters. :type snapshot_name: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/compute_management_client.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/compute_management_client.py index c15fc468573e..d4cfcfdf4c1d 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/compute_management_client.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/compute_management_client.py @@ -13,6 +13,7 @@ from msrest import Serializer, Deserializer from msrestazure import AzureConfiguration from .version import VERSION +from .operations.compute_operations import ComputeOperations from .operations.availability_sets_operations import AvailabilitySetsOperations from .operations.virtual_machine_extension_images_operations import VirtualMachineExtensionImagesOperations from .operations.virtual_machine_extensions_operations import VirtualMachineExtensionsOperations @@ -25,6 +26,7 @@ from .operations.virtual_machine_scale_set_extensions_operations import VirtualMachineScaleSetExtensionsOperations from .operations.virtual_machine_scale_set_rolling_upgrades_operations import VirtualMachineScaleSetRollingUpgradesOperations from .operations.virtual_machine_scale_set_vms_operations import VirtualMachineScaleSetVMsOperations +from .operations.log_analytics_operations import LogAnalyticsOperations from .operations.virtual_machine_run_commands_operations import VirtualMachineRunCommandsOperations from . import models @@ -69,6 +71,8 @@ class ComputeManagementClient(object): :ivar config: Configuration for client. :vartype config: ComputeManagementClientConfiguration + :ivar compute_operations: ComputeOperations operations + :vartype compute_operations: azure.mgmt.compute.v2017_12_01.operations.ComputeOperations :ivar availability_sets: AvailabilitySets operations :vartype availability_sets: azure.mgmt.compute.v2017_12_01.operations.AvailabilitySetsOperations :ivar virtual_machine_extension_images: VirtualMachineExtensionImages operations @@ -93,6 +97,8 @@ class ComputeManagementClient(object): :vartype virtual_machine_scale_set_rolling_upgrades: azure.mgmt.compute.v2017_12_01.operations.VirtualMachineScaleSetRollingUpgradesOperations :ivar virtual_machine_scale_set_vms: VirtualMachineScaleSetVMs operations :vartype virtual_machine_scale_set_vms: azure.mgmt.compute.v2017_12_01.operations.VirtualMachineScaleSetVMsOperations + :ivar log_analytics: LogAnalytics operations + :vartype log_analytics: azure.mgmt.compute.v2017_12_01.operations.LogAnalyticsOperations :ivar virtual_machine_run_commands: VirtualMachineRunCommands operations :vartype virtual_machine_run_commands: azure.mgmt.compute.v2017_12_01.operations.VirtualMachineRunCommandsOperations @@ -117,6 +123,8 @@ def __init__( self._serialize = Serializer(client_models) self._deserialize = Deserializer(client_models) + self.compute_operations = ComputeOperations( + self._client, self.config, self._serialize, self._deserialize) self.availability_sets = AvailabilitySetsOperations( self._client, self.config, self._serialize, self._deserialize) self.virtual_machine_extension_images = VirtualMachineExtensionImagesOperations( @@ -141,5 +149,7 @@ def __init__( self._client, self.config, self._serialize, self._deserialize) self.virtual_machine_scale_set_vms = VirtualMachineScaleSetVMsOperations( self._client, self.config, self._serialize, self._deserialize) + self.log_analytics = LogAnalyticsOperations( + self._client, self.config, self._serialize, self._deserialize) self.virtual_machine_run_commands = VirtualMachineRunCommandsOperations( self._client, self.config, self._serialize, self._deserialize) diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/__init__.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/__init__.py index 3d6e82bd216d..88e20bcb2f6c 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/__init__.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/__init__.py @@ -9,6 +9,8 @@ # regenerated. # -------------------------------------------------------------------------- +from .compute_operation_value import ComputeOperationValue +from .compute_operation_list_result import ComputeOperationListResult from .instance_view_status import InstanceViewStatus from .sub_resource import SubResource from .sku import Sku @@ -112,7 +114,13 @@ from .resource import Resource from .update_resource import UpdateResource from .sub_resource_read_only import SubResourceReadOnly +from .recovery_walk_response import RecoveryWalkResponse from .operation_status_response import OperationStatusResponse +from .request_rate_by_interval_input import RequestRateByIntervalInput +from .throttled_requests_input import ThrottledRequestsInput +from .log_analytics_input_base import LogAnalyticsInputBase +from .log_analytics_output import LogAnalyticsOutput +from .log_analytics_operation_result import LogAnalyticsOperationResult from .run_command_input_parameter import RunCommandInputParameter from .run_command_input import RunCommandInput from .run_command_parameter_definition import RunCommandParameterDefinition @@ -149,10 +157,13 @@ VirtualMachineScaleSetSkuScaleType, RollingUpgradeStatusCode, RollingUpgradeActionType, + IntervalInMins, InstanceViewTypes, ) __all__ = [ + 'ComputeOperationValue', + 'ComputeOperationListResult', 'InstanceViewStatus', 'SubResource', 'Sku', @@ -256,7 +267,13 @@ 'Resource', 'UpdateResource', 'SubResourceReadOnly', + 'RecoveryWalkResponse', 'OperationStatusResponse', + 'RequestRateByIntervalInput', + 'ThrottledRequestsInput', + 'LogAnalyticsInputBase', + 'LogAnalyticsOutput', + 'LogAnalyticsOperationResult', 'RunCommandInputParameter', 'RunCommandInput', 'RunCommandParameterDefinition', @@ -292,5 +309,6 @@ 'VirtualMachineScaleSetSkuScaleType', 'RollingUpgradeStatusCode', 'RollingUpgradeActionType', + 'IntervalInMins', 'InstanceViewTypes', ] diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_management_client_enums.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_management_client_enums.py index c143eed1080b..65202d80c83a 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_management_client_enums.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_management_client_enums.py @@ -51,6 +51,12 @@ class VirtualMachineSizeTypes(Enum): standard_a2m_v2 = "Standard_A2m_v2" standard_a4m_v2 = "Standard_A4m_v2" standard_a8m_v2 = "Standard_A8m_v2" + standard_b1s = "Standard_B1s" + standard_b1ms = "Standard_B1ms" + standard_b2s = "Standard_B2s" + standard_b2ms = "Standard_B2ms" + standard_b4ms = "Standard_B4ms" + standard_b8ms = "Standard_B8ms" standard_d1 = "Standard_D1" standard_d2 = "Standard_D2" standard_d3 = "Standard_D3" @@ -64,6 +70,18 @@ class VirtualMachineSizeTypes(Enum): standard_d3_v2 = "Standard_D3_v2" standard_d4_v2 = "Standard_D4_v2" standard_d5_v2 = "Standard_D5_v2" + standard_d2_v3 = "Standard_D2_v3" + standard_d4_v3 = "Standard_D4_v3" + standard_d8_v3 = "Standard_D8_v3" + standard_d16_v3 = "Standard_D16_v3" + standard_d32_v3 = "Standard_D32_v3" + standard_d64_v3 = "Standard_D64_v3" + standard_d2s_v3 = "Standard_D2s_v3" + standard_d4s_v3 = "Standard_D4s_v3" + standard_d8s_v3 = "Standard_D8s_v3" + standard_d16s_v3 = "Standard_D16s_v3" + standard_d32s_v3 = "Standard_D32s_v3" + standard_d64s_v3 = "Standard_D64s_v3" standard_d11_v2 = "Standard_D11_v2" standard_d12_v2 = "Standard_D12_v2" standard_d13_v2 = "Standard_D13_v2" @@ -87,6 +105,26 @@ class VirtualMachineSizeTypes(Enum): standard_ds13_v2 = "Standard_DS13_v2" standard_ds14_v2 = "Standard_DS14_v2" standard_ds15_v2 = "Standard_DS15_v2" + standard_ds13_4_v2 = "Standard_DS13-4_v2" + standard_ds13_2_v2 = "Standard_DS13-2_v2" + standard_ds14_8_v2 = "Standard_DS14-8_v2" + standard_ds14_4_v2 = "Standard_DS14-4_v2" + standard_e2_v3 = "Standard_E2_v3" + standard_e4_v3 = "Standard_E4_v3" + standard_e8_v3 = "Standard_E8_v3" + standard_e16_v3 = "Standard_E16_v3" + standard_e32_v3 = "Standard_E32_v3" + standard_e64_v3 = "Standard_E64_v3" + standard_e2s_v3 = "Standard_E2s_v3" + standard_e4s_v3 = "Standard_E4s_v3" + standard_e8s_v3 = "Standard_E8s_v3" + standard_e16s_v3 = "Standard_E16s_v3" + standard_e32s_v3 = "Standard_E32s_v3" + standard_e64s_v3 = "Standard_E64s_v3" + standard_e32_16_v3 = "Standard_E32-16_v3" + standard_e32_8s_v3 = "Standard_E32-8s_v3" + standard_e64_32s_v3 = "Standard_E64-32s_v3" + standard_e64_16s_v3 = "Standard_E64-16s_v3" standard_f1 = "Standard_F1" standard_f2 = "Standard_F2" standard_f4 = "Standard_F4" @@ -97,6 +135,13 @@ class VirtualMachineSizeTypes(Enum): standard_f4s = "Standard_F4s" standard_f8s = "Standard_F8s" standard_f16s = "Standard_F16s" + standard_f2s_v2 = "Standard_F2s_v2" + standard_f4s_v2 = "Standard_F4s_v2" + standard_f8s_v2 = "Standard_F8s_v2" + standard_f16s_v2 = "Standard_F16s_v2" + standard_f32s_v2 = "Standard_F32s_v2" + standard_f64s_v2 = "Standard_F64s_v2" + standard_f72s_v2 = "Standard_F72s_v2" standard_g1 = "Standard_G1" standard_g2 = "Standard_G2" standard_g3 = "Standard_G3" @@ -107,6 +152,10 @@ class VirtualMachineSizeTypes(Enum): standard_gs3 = "Standard_GS3" standard_gs4 = "Standard_GS4" standard_gs5 = "Standard_GS5" + standard_gs4_8 = "Standard_GS4-8" + standard_gs4_4 = "Standard_GS4-4" + standard_gs5_16 = "Standard_GS5-16" + standard_gs5_8 = "Standard_GS5-8" standard_h8 = "Standard_H8" standard_h16 = "Standard_H16" standard_h8m = "Standard_H8m" @@ -117,10 +166,30 @@ class VirtualMachineSizeTypes(Enum): standard_l8s = "Standard_L8s" standard_l16s = "Standard_L16s" standard_l32s = "Standard_L32s" + standard_m64s = "Standard_M64s" + standard_m64ms = "Standard_M64ms" + standard_m128s = "Standard_M128s" + standard_m128ms = "Standard_M128ms" + standard_m64_32ms = "Standard_M64-32ms" + standard_m64_16ms = "Standard_M64-16ms" + standard_m128_64ms = "Standard_M128-64ms" + standard_m128_32ms = "Standard_M128-32ms" standard_nc6 = "Standard_NC6" standard_nc12 = "Standard_NC12" standard_nc24 = "Standard_NC24" standard_nc24r = "Standard_NC24r" + standard_nc6s_v2 = "Standard_NC6s_v2" + standard_nc12s_v2 = "Standard_NC12s_v2" + standard_nc24s_v2 = "Standard_NC24s_v2" + standard_nc24rs_v2 = "Standard_NC24rs_v2" + standard_nc6s_v3 = "Standard_NC6s_v3" + standard_nc12s_v3 = "Standard_NC12s_v3" + standard_nc24s_v3 = "Standard_NC24s_v3" + standard_nc24rs_v3 = "Standard_NC24rs_v3" + standard_nd6s = "Standard_ND6s" + standard_nd12s = "Standard_ND12s" + standard_nd24s = "Standard_ND24s" + standard_nd24rs = "Standard_ND24rs" standard_nv6 = "Standard_NV6" standard_nv12 = "Standard_NV12" standard_nv24 = "Standard_NV24" @@ -229,6 +298,14 @@ class RollingUpgradeActionType(Enum): cancel = "Cancel" +class IntervalInMins(Enum): + + three_mins = "ThreeMins" + five_mins = "FiveMins" + thirty_mins = "ThirtyMins" + sixty_mins = "SixtyMins" + + class InstanceViewTypes(Enum): instance_view = "instanceView" diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_list_result.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_list_result.py new file mode 100644 index 000000000000..98349ea11d03 --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_list_result.py @@ -0,0 +1,29 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ComputeOperationListResult(Model): + """The List Compute Operation operation response. + + :param value: The list of compute operations + :type value: + list[~azure.mgmt.compute.v2017_12_01.models.ComputeOperationValue] + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': '[ComputeOperationValue]'}, + } + + def __init__(self, value=None): + super(ComputeOperationListResult, self).__init__() + self.value = value diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_value.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_value.py new file mode 100644 index 000000000000..3cd4bcbe7e0c --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/compute_operation_value.py @@ -0,0 +1,58 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ComputeOperationValue(Model): + """Describes the properties of a Compute Operation value. + + :param origin: The origin of the compute operation. + :type origin: str + :param name: The name of the compute operation. + :type name: str + :param operation: The display name of the compute operation. + :type operation: str + :param resource: The display name of the resource the operation applies + to. + :type resource: str + :param description: The description of the operation. + :type description: str + :param provider: The resource provider for the operation. + :type provider: str + """ + + _validation = { + 'origin': {'required': True}, + 'name': {'required': True}, + 'operation': {'required': True}, + 'resource': {'required': True}, + 'description': {'required': True}, + 'provider': {'required': True}, + } + + _attribute_map = { + 'origin': {'key': 'origin', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'operation': {'key': 'display.operation', 'type': 'str'}, + 'resource': {'key': 'display.resource', 'type': 'str'}, + 'description': {'key': 'display.description', 'type': 'str'}, + 'provider': {'key': 'display.provider', 'type': 'str'}, + } + + def __init__(self, origin, name, operation, resource, description, provider): + super(ComputeOperationValue, self).__init__() + self.origin = origin + self.name = name + self.operation = operation + self.resource = resource + self.description = description + self.provider = provider diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/data_disk.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/data_disk.py index d74f48cca017..9e1041fbdb73 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/data_disk.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/data_disk.py @@ -33,6 +33,9 @@ class DataDisk(Model):

Default: **None for Standard storage. ReadOnly for Premium storage**. Possible values include: 'None', 'ReadOnly', 'ReadWrite' :type caching: str or ~azure.mgmt.compute.v2017_12_01.models.CachingTypes + :param write_accelerator_enabled: Specifies whether writeAccelerator + should be enabled or disabled on the disk. + :type write_accelerator_enabled: bool :param create_option: Specifies how the virtual machine should be created.

Possible values are:

**Attach** \\u2013 This value is used when you are using a specialized disk to create the virtual @@ -63,18 +66,20 @@ class DataDisk(Model): 'vhd': {'key': 'vhd', 'type': 'VirtualHardDisk'}, 'image': {'key': 'image', 'type': 'VirtualHardDisk'}, 'caching': {'key': 'caching', 'type': 'CachingTypes'}, + 'write_accelerator_enabled': {'key': 'writeAcceleratorEnabled', 'type': 'bool'}, 'create_option': {'key': 'createOption', 'type': 'DiskCreateOptionTypes'}, 'disk_size_gb': {'key': 'diskSizeGB', 'type': 'int'}, 'managed_disk': {'key': 'managedDisk', 'type': 'ManagedDiskParameters'}, } - def __init__(self, lun, create_option, name=None, vhd=None, image=None, caching=None, disk_size_gb=None, managed_disk=None): + def __init__(self, lun, create_option, name=None, vhd=None, image=None, caching=None, write_accelerator_enabled=None, disk_size_gb=None, managed_disk=None): super(DataDisk, self).__init__() self.lun = lun self.name = name self.vhd = vhd self.image = image self.caching = caching + self.write_accelerator_enabled = write_accelerator_enabled self.create_option = create_option self.disk_size_gb = disk_size_gb self.managed_disk = managed_disk diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/hardware_profile.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/hardware_profile.py index 8a09b0659ec3..10cf684677e7 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/hardware_profile.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/hardware_profile.py @@ -21,35 +21,57 @@ class HardwareProfile(Model):

The available VM sizes depend on region and availability set. For a list of available sizes use these APIs:

[List all available virtual machine sizes in an availability - set](virtualmachines-list-sizes-availability-set.md)

[List all - available virtual machine sizes in a - region](virtualmachines-list-sizes-region.md)

[List all available - virtual machine sizes for - resizing](virtualmachines-list-sizes-for-resizing.md). Possible values - include: 'Basic_A0', 'Basic_A1', 'Basic_A2', 'Basic_A3', 'Basic_A4', - 'Standard_A0', 'Standard_A1', 'Standard_A2', 'Standard_A3', 'Standard_A4', - 'Standard_A5', 'Standard_A6', 'Standard_A7', 'Standard_A8', 'Standard_A9', - 'Standard_A10', 'Standard_A11', 'Standard_A1_v2', 'Standard_A2_v2', - 'Standard_A4_v2', 'Standard_A8_v2', 'Standard_A2m_v2', 'Standard_A4m_v2', - 'Standard_A8m_v2', 'Standard_D1', 'Standard_D2', 'Standard_D3', - 'Standard_D4', 'Standard_D11', 'Standard_D12', 'Standard_D13', - 'Standard_D14', 'Standard_D1_v2', 'Standard_D2_v2', 'Standard_D3_v2', - 'Standard_D4_v2', 'Standard_D5_v2', 'Standard_D11_v2', 'Standard_D12_v2', - 'Standard_D13_v2', 'Standard_D14_v2', 'Standard_D15_v2', 'Standard_DS1', - 'Standard_DS2', 'Standard_DS3', 'Standard_DS4', 'Standard_DS11', - 'Standard_DS12', 'Standard_DS13', 'Standard_DS14', 'Standard_DS1_v2', - 'Standard_DS2_v2', 'Standard_DS3_v2', 'Standard_DS4_v2', - 'Standard_DS5_v2', 'Standard_DS11_v2', 'Standard_DS12_v2', - 'Standard_DS13_v2', 'Standard_DS14_v2', 'Standard_DS15_v2', 'Standard_F1', - 'Standard_F2', 'Standard_F4', 'Standard_F8', 'Standard_F16', - 'Standard_F1s', 'Standard_F2s', 'Standard_F4s', 'Standard_F8s', - 'Standard_F16s', 'Standard_G1', 'Standard_G2', 'Standard_G3', - 'Standard_G4', 'Standard_G5', 'Standard_GS1', 'Standard_GS2', - 'Standard_GS3', 'Standard_GS4', 'Standard_GS5', 'Standard_H8', - 'Standard_H16', 'Standard_H8m', 'Standard_H16m', 'Standard_H16r', - 'Standard_H16mr', 'Standard_L4s', 'Standard_L8s', 'Standard_L16s', - 'Standard_L32s', 'Standard_NC6', 'Standard_NC12', 'Standard_NC24', - 'Standard_NC24r', 'Standard_NV6', 'Standard_NV12', 'Standard_NV24' + set](https://docs.microsoft.com/rest/api/compute/availabilitysets/listavailablesizes) +

[List all available virtual machine sizes in a + region](https://docs.microsoft.com/rest/api/compute/virtualmachinesizes/list) +

[List all available virtual machine sizes for + resizing](https://docs.microsoft.com/rest/api/compute/virtualmachines/listavailablesizes). + Possible values include: 'Basic_A0', 'Basic_A1', 'Basic_A2', 'Basic_A3', + 'Basic_A4', 'Standard_A0', 'Standard_A1', 'Standard_A2', 'Standard_A3', + 'Standard_A4', 'Standard_A5', 'Standard_A6', 'Standard_A7', 'Standard_A8', + 'Standard_A9', 'Standard_A10', 'Standard_A11', 'Standard_A1_v2', + 'Standard_A2_v2', 'Standard_A4_v2', 'Standard_A8_v2', 'Standard_A2m_v2', + 'Standard_A4m_v2', 'Standard_A8m_v2', 'Standard_B1s', 'Standard_B1ms', + 'Standard_B2s', 'Standard_B2ms', 'Standard_B4ms', 'Standard_B8ms', + 'Standard_D1', 'Standard_D2', 'Standard_D3', 'Standard_D4', + 'Standard_D11', 'Standard_D12', 'Standard_D13', 'Standard_D14', + 'Standard_D1_v2', 'Standard_D2_v2', 'Standard_D3_v2', 'Standard_D4_v2', + 'Standard_D5_v2', 'Standard_D2_v3', 'Standard_D4_v3', 'Standard_D8_v3', + 'Standard_D16_v3', 'Standard_D32_v3', 'Standard_D64_v3', + 'Standard_D2s_v3', 'Standard_D4s_v3', 'Standard_D8s_v3', + 'Standard_D16s_v3', 'Standard_D32s_v3', 'Standard_D64s_v3', + 'Standard_D11_v2', 'Standard_D12_v2', 'Standard_D13_v2', + 'Standard_D14_v2', 'Standard_D15_v2', 'Standard_DS1', 'Standard_DS2', + 'Standard_DS3', 'Standard_DS4', 'Standard_DS11', 'Standard_DS12', + 'Standard_DS13', 'Standard_DS14', 'Standard_DS1_v2', 'Standard_DS2_v2', + 'Standard_DS3_v2', 'Standard_DS4_v2', 'Standard_DS5_v2', + 'Standard_DS11_v2', 'Standard_DS12_v2', 'Standard_DS13_v2', + 'Standard_DS14_v2', 'Standard_DS15_v2', 'Standard_DS13-4_v2', + 'Standard_DS13-2_v2', 'Standard_DS14-8_v2', 'Standard_DS14-4_v2', + 'Standard_E2_v3', 'Standard_E4_v3', 'Standard_E8_v3', 'Standard_E16_v3', + 'Standard_E32_v3', 'Standard_E64_v3', 'Standard_E2s_v3', + 'Standard_E4s_v3', 'Standard_E8s_v3', 'Standard_E16s_v3', + 'Standard_E32s_v3', 'Standard_E64s_v3', 'Standard_E32-16_v3', + 'Standard_E32-8s_v3', 'Standard_E64-32s_v3', 'Standard_E64-16s_v3', + 'Standard_F1', 'Standard_F2', 'Standard_F4', 'Standard_F8', + 'Standard_F16', 'Standard_F1s', 'Standard_F2s', 'Standard_F4s', + 'Standard_F8s', 'Standard_F16s', 'Standard_F2s_v2', 'Standard_F4s_v2', + 'Standard_F8s_v2', 'Standard_F16s_v2', 'Standard_F32s_v2', + 'Standard_F64s_v2', 'Standard_F72s_v2', 'Standard_G1', 'Standard_G2', + 'Standard_G3', 'Standard_G4', 'Standard_G5', 'Standard_GS1', + 'Standard_GS2', 'Standard_GS3', 'Standard_GS4', 'Standard_GS5', + 'Standard_GS4-8', 'Standard_GS4-4', 'Standard_GS5-16', 'Standard_GS5-8', + 'Standard_H8', 'Standard_H16', 'Standard_H8m', 'Standard_H16m', + 'Standard_H16r', 'Standard_H16mr', 'Standard_L4s', 'Standard_L8s', + 'Standard_L16s', 'Standard_L32s', 'Standard_M64s', 'Standard_M64ms', + 'Standard_M128s', 'Standard_M128ms', 'Standard_M64-32ms', + 'Standard_M64-16ms', 'Standard_M128-64ms', 'Standard_M128-32ms', + 'Standard_NC6', 'Standard_NC12', 'Standard_NC24', 'Standard_NC24r', + 'Standard_NC6s_v2', 'Standard_NC12s_v2', 'Standard_NC24s_v2', + 'Standard_NC24rs_v2', 'Standard_NC6s_v3', 'Standard_NC12s_v3', + 'Standard_NC24s_v3', 'Standard_NC24rs_v3', 'Standard_ND6s', + 'Standard_ND12s', 'Standard_ND24s', 'Standard_ND24rs', 'Standard_NV6', + 'Standard_NV12', 'Standard_NV24' :type vm_size: str or ~azure.mgmt.compute.v2017_12_01.models.VirtualMachineSizeTypes """ diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_input_base.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_input_base.py new file mode 100644 index 000000000000..828590e88883 --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_input_base.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class LogAnalyticsInputBase(Model): + """Api input base class for LogAnalytics Api. + + :param blob_container_sas_uri: SAS Uri of the logging blob container to + which LogAnalytics Api writes output logs to. + :type blob_container_sas_uri: str + :param from_time: From time of the query + :type from_time: datetime + :param to_time: To time of the query + :type to_time: datetime + :param group_by_throttle_policy: Group query result by Throttle Policy + applied. + :type group_by_throttle_policy: bool + :param group_by_operation_name: Group query result by by Operation Name. + :type group_by_operation_name: bool + :param group_by_resource_name: Group query result by Resource Name. + :type group_by_resource_name: bool + """ + + _validation = { + 'blob_container_sas_uri': {'required': True}, + 'from_time': {'required': True}, + 'to_time': {'required': True}, + } + + _attribute_map = { + 'blob_container_sas_uri': {'key': 'blobContainerSasUri', 'type': 'str'}, + 'from_time': {'key': 'fromTime', 'type': 'iso-8601'}, + 'to_time': {'key': 'toTime', 'type': 'iso-8601'}, + 'group_by_throttle_policy': {'key': 'groupByThrottlePolicy', 'type': 'bool'}, + 'group_by_operation_name': {'key': 'groupByOperationName', 'type': 'bool'}, + 'group_by_resource_name': {'key': 'groupByResourceName', 'type': 'bool'}, + } + + def __init__(self, blob_container_sas_uri, from_time, to_time, group_by_throttle_policy=None, group_by_operation_name=None, group_by_resource_name=None): + super(LogAnalyticsInputBase, self).__init__() + self.blob_container_sas_uri = blob_container_sas_uri + self.from_time = from_time + self.to_time = to_time + self.group_by_throttle_policy = group_by_throttle_policy + self.group_by_operation_name = group_by_operation_name + self.group_by_resource_name = group_by_resource_name diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_operation_result.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_operation_result.py new file mode 100644 index 000000000000..9ab2c2a0d736 --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_operation_result.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .operation_status_response import OperationStatusResponse + + +class LogAnalyticsOperationResult(OperationStatusResponse): + """LogAnalytics operation status response. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar name: Operation ID + :vartype name: str + :ivar status: Operation status + :vartype status: str + :ivar start_time: Start time of the operation + :vartype start_time: datetime + :ivar end_time: End time of the operation + :vartype end_time: datetime + :ivar error: Api error + :vartype error: ~azure.mgmt.compute.v2017_12_01.models.ApiError + :ivar properties: LogAnalyticsOutput + :vartype properties: + ~azure.mgmt.compute.v2017_12_01.models.LogAnalyticsOutput + """ + + _validation = { + 'name': {'readonly': True}, + 'status': {'readonly': True}, + 'start_time': {'readonly': True}, + 'end_time': {'readonly': True}, + 'error': {'readonly': True}, + 'properties': {'readonly': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'str'}, + 'start_time': {'key': 'startTime', 'type': 'iso-8601'}, + 'end_time': {'key': 'endTime', 'type': 'iso-8601'}, + 'error': {'key': 'error', 'type': 'ApiError'}, + 'properties': {'key': 'properties', 'type': 'LogAnalyticsOutput'}, + } + + def __init__(self): + super(LogAnalyticsOperationResult, self).__init__() + self.properties = None diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_output.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_output.py new file mode 100644 index 000000000000..8cf3ab94d19e --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/log_analytics_output.py @@ -0,0 +1,35 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class LogAnalyticsOutput(Model): + """LogAnalytics output properties. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar output: Output file Uri path to blob container. + :vartype output: str + """ + + _validation = { + 'output': {'readonly': True}, + } + + _attribute_map = { + 'output': {'key': 'output', 'type': 'str'}, + } + + def __init__(self): + super(LogAnalyticsOutput, self).__init__() + self.output = None diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/os_disk.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/os_disk.py index dbd6011b4310..2e527291882b 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/os_disk.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/os_disk.py @@ -42,6 +42,9 @@ class OSDisk(Model):

Default: **None for Standard storage. ReadOnly for Premium storage**. Possible values include: 'None', 'ReadOnly', 'ReadWrite' :type caching: str or ~azure.mgmt.compute.v2017_12_01.models.CachingTypes + :param write_accelerator_enabled: Specifies whether writeAccelerator + should be enabled or disabled on the disk. + :type write_accelerator_enabled: bool :param create_option: Specifies how the virtual machine should be created.

Possible values are:

**Attach** \\u2013 This value is used when you are using a specialized disk to create the virtual @@ -72,12 +75,13 @@ class OSDisk(Model): 'vhd': {'key': 'vhd', 'type': 'VirtualHardDisk'}, 'image': {'key': 'image', 'type': 'VirtualHardDisk'}, 'caching': {'key': 'caching', 'type': 'CachingTypes'}, + 'write_accelerator_enabled': {'key': 'writeAcceleratorEnabled', 'type': 'bool'}, 'create_option': {'key': 'createOption', 'type': 'DiskCreateOptionTypes'}, 'disk_size_gb': {'key': 'diskSizeGB', 'type': 'int'}, 'managed_disk': {'key': 'managedDisk', 'type': 'ManagedDiskParameters'}, } - def __init__(self, create_option, os_type=None, encryption_settings=None, name=None, vhd=None, image=None, caching=None, disk_size_gb=None, managed_disk=None): + def __init__(self, create_option, os_type=None, encryption_settings=None, name=None, vhd=None, image=None, caching=None, write_accelerator_enabled=None, disk_size_gb=None, managed_disk=None): super(OSDisk, self).__init__() self.os_type = os_type self.encryption_settings = encryption_settings @@ -85,6 +89,7 @@ def __init__(self, create_option, os_type=None, encryption_settings=None, name=N self.vhd = vhd self.image = image self.caching = caching + self.write_accelerator_enabled = write_accelerator_enabled self.create_option = create_option self.disk_size_gb = disk_size_gb self.managed_disk = managed_disk diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/recovery_walk_response.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/recovery_walk_response.py new file mode 100644 index 000000000000..28e8b6af21fc --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/recovery_walk_response.py @@ -0,0 +1,41 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class RecoveryWalkResponse(Model): + """Response after calling a manual recovery walk. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar walk_performed: Whether the recovery walk was performed + :vartype walk_performed: bool + :ivar next_platform_update_domain: The next update domain that needs to be + walked. Null means walk spanning all update domains has been completed + :vartype next_platform_update_domain: int + """ + + _validation = { + 'walk_performed': {'readonly': True}, + 'next_platform_update_domain': {'readonly': True}, + } + + _attribute_map = { + 'walk_performed': {'key': 'walkPerformed', 'type': 'bool'}, + 'next_platform_update_domain': {'key': 'nextPlatformUpdateDomain', 'type': 'int'}, + } + + def __init__(self): + super(RecoveryWalkResponse, self).__init__() + self.walk_performed = None + self.next_platform_update_domain = None diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/request_rate_by_interval_input.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/request_rate_by_interval_input.py new file mode 100644 index 000000000000..d31abf8c3f44 --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/request_rate_by_interval_input.py @@ -0,0 +1,58 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .log_analytics_input_base import LogAnalyticsInputBase + + +class RequestRateByIntervalInput(LogAnalyticsInputBase): + """Api request input for LogAnalytics getRequestRateByInterval Api. + + :param blob_container_sas_uri: SAS Uri of the logging blob container to + which LogAnalytics Api writes output logs to. + :type blob_container_sas_uri: str + :param from_time: From time of the query + :type from_time: datetime + :param to_time: To time of the query + :type to_time: datetime + :param group_by_throttle_policy: Group query result by Throttle Policy + applied. + :type group_by_throttle_policy: bool + :param group_by_operation_name: Group query result by by Operation Name. + :type group_by_operation_name: bool + :param group_by_resource_name: Group query result by Resource Name. + :type group_by_resource_name: bool + :param interval_length: Interval value in minutes used to create + LogAnalytics call rate logs. Possible values include: 'ThreeMins', + 'FiveMins', 'ThirtyMins', 'SixtyMins' + :type interval_length: str or + ~azure.mgmt.compute.v2017_12_01.models.IntervalInMins + """ + + _validation = { + 'blob_container_sas_uri': {'required': True}, + 'from_time': {'required': True}, + 'to_time': {'required': True}, + 'interval_length': {'required': True}, + } + + _attribute_map = { + 'blob_container_sas_uri': {'key': 'blobContainerSasUri', 'type': 'str'}, + 'from_time': {'key': 'fromTime', 'type': 'iso-8601'}, + 'to_time': {'key': 'toTime', 'type': 'iso-8601'}, + 'group_by_throttle_policy': {'key': 'groupByThrottlePolicy', 'type': 'bool'}, + 'group_by_operation_name': {'key': 'groupByOperationName', 'type': 'bool'}, + 'group_by_resource_name': {'key': 'groupByResourceName', 'type': 'bool'}, + 'interval_length': {'key': 'intervalLength', 'type': 'IntervalInMins'}, + } + + def __init__(self, blob_container_sas_uri, from_time, to_time, interval_length, group_by_throttle_policy=None, group_by_operation_name=None, group_by_resource_name=None): + super(RequestRateByIntervalInput, self).__init__(blob_container_sas_uri=blob_container_sas_uri, from_time=from_time, to_time=to_time, group_by_throttle_policy=group_by_throttle_policy, group_by_operation_name=group_by_operation_name, group_by_resource_name=group_by_resource_name) + self.interval_length = interval_length diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/throttled_requests_input.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/throttled_requests_input.py new file mode 100644 index 000000000000..c0586c7c32a2 --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/throttled_requests_input.py @@ -0,0 +1,41 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .log_analytics_input_base import LogAnalyticsInputBase + + +class ThrottledRequestsInput(LogAnalyticsInputBase): + """Api request input for LogAnalytics getThrottledRequests Api. + + :param blob_container_sas_uri: SAS Uri of the logging blob container to + which LogAnalytics Api writes output logs to. + :type blob_container_sas_uri: str + :param from_time: From time of the query + :type from_time: datetime + :param to_time: To time of the query + :type to_time: datetime + :param group_by_throttle_policy: Group query result by Throttle Policy + applied. + :type group_by_throttle_policy: bool + :param group_by_operation_name: Group query result by by Operation Name. + :type group_by_operation_name: bool + :param group_by_resource_name: Group query result by Resource Name. + :type group_by_resource_name: bool + """ + + _validation = { + 'blob_container_sas_uri': {'required': True}, + 'from_time': {'required': True}, + 'to_time': {'required': True}, + } + + def __init__(self, blob_container_sas_uri, from_time, to_time, group_by_throttle_policy=None, group_by_operation_name=None, group_by_resource_name=None): + super(ThrottledRequestsInput, self).__init__(blob_container_sas_uri=blob_container_sas_uri, from_time=from_time, to_time=to_time, group_by_throttle_policy=group_by_throttle_policy, group_by_operation_name=group_by_operation_name, group_by_resource_name=group_by_resource_name) diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_instance_view.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_instance_view.py index de4790894f34..ef75449227cd 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_instance_view.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_instance_view.py @@ -21,6 +21,13 @@ class VirtualMachineInstanceView(Model): :param platform_fault_domain: Specifies the fault domain of the virtual machine. :type platform_fault_domain: int + :param computer_name: The computer name assigned to the virtual machine. + :type computer_name: str + :param os_name: The Operating System running on the virtual machine. + :type os_name: str + :param os_version: The version of Operating System running on the virtual + machine. + :type os_version: str :param rdp_thumb_print: The Remote desktop certificate thumbprint. :type rdp_thumb_print: str :param vm_agent: The VM Agent running on the virtual machine. @@ -50,6 +57,9 @@ class VirtualMachineInstanceView(Model): _attribute_map = { 'platform_update_domain': {'key': 'platformUpdateDomain', 'type': 'int'}, 'platform_fault_domain': {'key': 'platformFaultDomain', 'type': 'int'}, + 'computer_name': {'key': 'computerName', 'type': 'str'}, + 'os_name': {'key': 'osName', 'type': 'str'}, + 'os_version': {'key': 'osVersion', 'type': 'str'}, 'rdp_thumb_print': {'key': 'rdpThumbPrint', 'type': 'str'}, 'vm_agent': {'key': 'vmAgent', 'type': 'VirtualMachineAgentInstanceView'}, 'maintenance_redeploy_status': {'key': 'maintenanceRedeployStatus', 'type': 'MaintenanceRedeployStatus'}, @@ -59,10 +69,13 @@ class VirtualMachineInstanceView(Model): 'statuses': {'key': 'statuses', 'type': '[InstanceViewStatus]'}, } - def __init__(self, platform_update_domain=None, platform_fault_domain=None, rdp_thumb_print=None, vm_agent=None, maintenance_redeploy_status=None, disks=None, extensions=None, boot_diagnostics=None, statuses=None): + def __init__(self, platform_update_domain=None, platform_fault_domain=None, computer_name=None, os_name=None, os_version=None, rdp_thumb_print=None, vm_agent=None, maintenance_redeploy_status=None, disks=None, extensions=None, boot_diagnostics=None, statuses=None): super(VirtualMachineInstanceView, self).__init__() self.platform_update_domain = platform_update_domain self.platform_fault_domain = platform_fault_domain + self.computer_name = computer_name + self.os_name = os_name + self.os_version = os_version self.rdp_thumb_print = rdp_thumb_print self.vm_agent = vm_agent self.maintenance_redeploy_status = maintenance_redeploy_status diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_data_disk.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_data_disk.py index f0d8872c4f9a..44aa4ac44cc3 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_data_disk.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_data_disk.py @@ -26,6 +26,9 @@ class VirtualMachineScaleSetDataDisk(Model):

Default: **None for Standard storage. ReadOnly for Premium storage**. Possible values include: 'None', 'ReadOnly', 'ReadWrite' :type caching: str or ~azure.mgmt.compute.v2017_12_01.models.CachingTypes + :param write_accelerator_enabled: Specifies whether writeAccelerator + should be enabled or disabled on the disk. + :type write_accelerator_enabled: bool :param create_option: The create option. Possible values include: 'FromImage', 'Empty', 'Attach' :type create_option: str or @@ -48,16 +51,18 @@ class VirtualMachineScaleSetDataDisk(Model): 'name': {'key': 'name', 'type': 'str'}, 'lun': {'key': 'lun', 'type': 'int'}, 'caching': {'key': 'caching', 'type': 'CachingTypes'}, + 'write_accelerator_enabled': {'key': 'writeAcceleratorEnabled', 'type': 'bool'}, 'create_option': {'key': 'createOption', 'type': 'DiskCreateOptionTypes'}, 'disk_size_gb': {'key': 'diskSizeGB', 'type': 'int'}, 'managed_disk': {'key': 'managedDisk', 'type': 'VirtualMachineScaleSetManagedDiskParameters'}, } - def __init__(self, lun, create_option, name=None, caching=None, disk_size_gb=None, managed_disk=None): + def __init__(self, lun, create_option, name=None, caching=None, write_accelerator_enabled=None, disk_size_gb=None, managed_disk=None): super(VirtualMachineScaleSetDataDisk, self).__init__() self.name = name self.lun = lun self.caching = caching + self.write_accelerator_enabled = write_accelerator_enabled self.create_option = create_option self.disk_size_gb = disk_size_gb self.managed_disk = managed_disk diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_os_disk.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_os_disk.py index 9e3448b6f8c9..e7be6a670c83 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_os_disk.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_os_disk.py @@ -22,6 +22,9 @@ class VirtualMachineScaleSetOSDisk(Model):

Default: **None for Standard storage. ReadOnly for Premium storage**. Possible values include: 'None', 'ReadOnly', 'ReadWrite' :type caching: str or ~azure.mgmt.compute.v2017_12_01.models.CachingTypes + :param write_accelerator_enabled: Specifies whether writeAccelerator + should be enabled or disabled on the disk. + :type write_accelerator_enabled: bool :param create_option: Specifies how the virtual machines in the scale set should be created.

The only allowed value is: **FromImage** \\u2013 This value is used when you are using an image to create the @@ -55,6 +58,7 @@ class VirtualMachineScaleSetOSDisk(Model): _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'caching': {'key': 'caching', 'type': 'CachingTypes'}, + 'write_accelerator_enabled': {'key': 'writeAcceleratorEnabled', 'type': 'bool'}, 'create_option': {'key': 'createOption', 'type': 'DiskCreateOptionTypes'}, 'os_type': {'key': 'osType', 'type': 'OperatingSystemTypes'}, 'image': {'key': 'image', 'type': 'VirtualHardDisk'}, @@ -62,10 +66,11 @@ class VirtualMachineScaleSetOSDisk(Model): 'managed_disk': {'key': 'managedDisk', 'type': 'VirtualMachineScaleSetManagedDiskParameters'}, } - def __init__(self, create_option, name=None, caching=None, os_type=None, image=None, vhd_containers=None, managed_disk=None): + def __init__(self, create_option, name=None, caching=None, write_accelerator_enabled=None, os_type=None, image=None, vhd_containers=None, managed_disk=None): super(VirtualMachineScaleSetOSDisk, self).__init__() self.name = name self.caching = caching + self.write_accelerator_enabled = write_accelerator_enabled self.create_option = create_option self.os_type = os_type self.image = image diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_update_os_disk.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_update_os_disk.py index 406be35982ff..b9c2cfe8c1dd 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_update_os_disk.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/virtual_machine_scale_set_update_os_disk.py @@ -19,6 +19,9 @@ class VirtualMachineScaleSetUpdateOSDisk(Model): :param caching: The caching type. Possible values include: 'None', 'ReadOnly', 'ReadWrite' :type caching: str or ~azure.mgmt.compute.v2017_12_01.models.CachingTypes + :param write_accelerator_enabled: Specifies whether writeAccelerator + should be enabled or disabled on the disk. + :type write_accelerator_enabled: bool :param image: The Source User Image VirtualHardDisk. This VirtualHardDisk will be copied before using it to attach to the Virtual Machine. If SourceImage is provided, the destination VirtualHardDisk should not exist. @@ -32,14 +35,16 @@ class VirtualMachineScaleSetUpdateOSDisk(Model): _attribute_map = { 'caching': {'key': 'caching', 'type': 'CachingTypes'}, + 'write_accelerator_enabled': {'key': 'writeAcceleratorEnabled', 'type': 'bool'}, 'image': {'key': 'image', 'type': 'VirtualHardDisk'}, 'vhd_containers': {'key': 'vhdContainers', 'type': '[str]'}, 'managed_disk': {'key': 'managedDisk', 'type': 'VirtualMachineScaleSetManagedDiskParameters'}, } - def __init__(self, caching=None, image=None, vhd_containers=None, managed_disk=None): + def __init__(self, caching=None, write_accelerator_enabled=None, image=None, vhd_containers=None, managed_disk=None): super(VirtualMachineScaleSetUpdateOSDisk, self).__init__() self.caching = caching + self.write_accelerator_enabled = write_accelerator_enabled self.image = image self.vhd_containers = vhd_containers self.managed_disk = managed_disk diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/__init__.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/__init__.py index a60ef67c1486..8e3036ad1c13 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/__init__.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/__init__.py @@ -9,6 +9,7 @@ # regenerated. # -------------------------------------------------------------------------- +from .compute_operations import ComputeOperations from .availability_sets_operations import AvailabilitySetsOperations from .virtual_machine_extension_images_operations import VirtualMachineExtensionImagesOperations from .virtual_machine_extensions_operations import VirtualMachineExtensionsOperations @@ -21,9 +22,11 @@ from .virtual_machine_scale_set_extensions_operations import VirtualMachineScaleSetExtensionsOperations from .virtual_machine_scale_set_rolling_upgrades_operations import VirtualMachineScaleSetRollingUpgradesOperations from .virtual_machine_scale_set_vms_operations import VirtualMachineScaleSetVMsOperations +from .log_analytics_operations import LogAnalyticsOperations from .virtual_machine_run_commands_operations import VirtualMachineRunCommandsOperations __all__ = [ + 'ComputeOperations', 'AvailabilitySetsOperations', 'VirtualMachineExtensionImagesOperations', 'VirtualMachineExtensionsOperations', @@ -36,5 +39,6 @@ 'VirtualMachineScaleSetExtensionsOperations', 'VirtualMachineScaleSetRollingUpgradesOperations', 'VirtualMachineScaleSetVMsOperations', + 'LogAnalyticsOperations', 'VirtualMachineRunCommandsOperations', ] diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/availability_sets_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/availability_sets_operations.py index 1417ab1beeff..53f33492be74 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/availability_sets_operations.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/availability_sets_operations.py @@ -106,6 +106,75 @@ def create_or_update( return deserialized + def update( + self, resource_group_name, availability_set_name, parameters, custom_headers=None, raw=False, **operation_config): + """Update an availability set. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param availability_set_name: The name of the availability set. + :type availability_set_name: str + :param parameters: Parameters supplied to the Create Availability Set + operation. + :type parameters: + ~azure.mgmt.compute.v2017_12_01.models.AvailabilitySet + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: AvailabilitySet or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.compute.v2017_12_01.models.AvailabilitySet or + ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + # Construct URL + url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}' + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'availabilitySetName': self._serialize.url("availability_set_name", availability_set_name, 'str'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + body_content = self._serialize.body(parameters, 'AvailabilitySet') + + # Construct and send request + request = self._client.patch(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, stream=False, **operation_config) + + if response.status_code not in [200]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('AvailabilitySet', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + def delete( self, resource_group_name, availability_set_name, custom_headers=None, raw=False, **operation_config): """Delete an availability set. diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/compute_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/compute_operations.py new file mode 100644 index 000000000000..cd524bc813f6 --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/compute_operations.py @@ -0,0 +1,90 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse +from msrestazure.azure_exceptions import CloudError + +from .. import models + + +class ComputeOperations(object): + """ComputeOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An objec model deserializer. + :ivar api_version: Client Api Version. Constant value: "2017-12-01". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2017-12-01" + + self.config = config + + def list( + self, custom_headers=None, raw=False, **operation_config): + """Gets a list of compute operations. + + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: ComputeOperationListResult or ClientRawResponse if raw=true + :rtype: + ~azure.mgmt.compute.v2017_12_01.models.ComputeOperationListResult or + ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + # Construct URL + url = '/providers/Microsoft.Compute/operations' + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters) + response = self._client.send(request, header_parameters, stream=False, **operation_config) + + if response.status_code not in [200]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('ComputeOperationListResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/images_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/images_operations.py index f5522fbf933b..e3c6e2b06b0e 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/images_operations.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/images_operations.py @@ -159,6 +159,125 @@ def get_long_running_output(response): get_long_running_status, long_running_operation_timeout) + def _update_initial( + self, resource_group_name, image_name, parameters, custom_headers=None, raw=False, **operation_config): + # Construct URL + url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/images/{imageName}' + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'imageName': self._serialize.url("image_name", image_name, 'str'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + body_content = self._serialize.body(parameters, 'Image') + + # Construct and send request + request = self._client.patch(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, stream=False, **operation_config) + + if response.status_code not in [200, 201]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('Image', response) + if response.status_code == 201: + deserialized = self._deserialize('Image', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + def update( + self, resource_group_name, image_name, parameters, custom_headers=None, raw=False, **operation_config): + """Update an image. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param image_name: The name of the image. + :type image_name: str + :param parameters: Parameters supplied to the Create Image operation. + :type parameters: ~azure.mgmt.compute.v2017_12_01.models.Image + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :return: An instance of AzureOperationPoller that returns Image or + ClientRawResponse if raw=true + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.compute.v2017_12_01.models.Image] + or ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + raw_result = self._update_initial( + resource_group_name=resource_group_name, + image_name=image_name, + parameters=parameters, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + if raw: + return raw_result + + # Construct and send request + def long_running_send(): + return raw_result.response + + def get_long_running_status(status_link, headers=None): + + request = self._client.get(status_link) + if headers: + request.headers.update(headers) + header_parameters = {} + header_parameters['x-ms-client-request-id'] = raw_result.response.request.headers['x-ms-client-request-id'] + return self._client.send( + request, header_parameters, stream=False, **operation_config) + + def get_long_running_output(response): + + if response.status_code not in [200, 201]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = self._deserialize('Image', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + long_running_operation_timeout = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + return AzureOperationPoller( + long_running_send, get_long_running_output, + get_long_running_status, long_running_operation_timeout) + + def _delete_initial( self, resource_group_name, image_name, custom_headers=None, raw=False, **operation_config): # Construct URL diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/log_analytics_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/log_analytics_operations.py new file mode 100644 index 000000000000..db2aa6911d21 --- /dev/null +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/log_analytics_operations.py @@ -0,0 +1,274 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse +from msrestazure.azure_exceptions import CloudError +from msrest.exceptions import DeserializationError +from msrestazure.azure_operation import AzureOperationPoller + +from .. import models + + +class LogAnalyticsOperations(object): + """LogAnalyticsOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An objec model deserializer. + :ivar api_version: Client Api Version. Constant value: "2017-12-01". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2017-12-01" + + self.config = config + + + def _export_request_rate_by_interval_initial( + self, parameters, location, custom_headers=None, raw=False, **operation_config): + # Construct URL + url = '/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/logAnalytics/apiAccess/getRequestRateByInterval' + path_format_arguments = { + 'location': self._serialize.url("location", location, 'str', pattern=r'^[-\w\._]+$'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + body_content = self._serialize.body(parameters, 'RequestRateByIntervalInput') + + # Construct and send request + request = self._client.post(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, stream=False, **operation_config) + + if response.status_code not in [200, 202]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('LogAnalyticsOperationResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + def export_request_rate_by_interval( + self, parameters, location, custom_headers=None, raw=False, **operation_config): + """Export logs that show Api requests made by this subscription in the + given time window to show throttling activities. + + :param parameters: Parameters supplied to the LogAnalytics + getRequestRateByInterval Api. + :type parameters: + ~azure.mgmt.compute.v2017_12_01.models.RequestRateByIntervalInput + :param location: The location upon which virtual-machine-sizes is + queried. + :type location: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :return: An instance of AzureOperationPoller that returns + LogAnalyticsOperationResult or ClientRawResponse if raw=true + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.compute.v2017_12_01.models.LogAnalyticsOperationResult] + or ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + raw_result = self._export_request_rate_by_interval_initial( + parameters=parameters, + location=location, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + if raw: + return raw_result + + # Construct and send request + def long_running_send(): + return raw_result.response + + def get_long_running_status(status_link, headers=None): + + request = self._client.get(status_link) + if headers: + request.headers.update(headers) + header_parameters = {} + header_parameters['x-ms-client-request-id'] = raw_result.response.request.headers['x-ms-client-request-id'] + return self._client.send( + request, header_parameters, stream=False, **operation_config) + + def get_long_running_output(response): + + if response.status_code not in [200, 202]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = self._deserialize('LogAnalyticsOperationResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + long_running_operation_timeout = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + return AzureOperationPoller( + long_running_send, get_long_running_output, + get_long_running_status, long_running_operation_timeout) + + + def _export_throttled_requests_initial( + self, parameters, location, custom_headers=None, raw=False, **operation_config): + # Construct URL + url = '/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/logAnalytics/apiAccess/getThrottledRequests' + path_format_arguments = { + 'location': self._serialize.url("location", location, 'str', pattern=r'^[-\w\._]+$'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + body_content = self._serialize.body(parameters, 'ThrottledRequestsInput') + + # Construct and send request + request = self._client.post(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, stream=False, **operation_config) + + if response.status_code not in [200, 202]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('LogAnalyticsOperationResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + def export_throttled_requests( + self, parameters, location, custom_headers=None, raw=False, **operation_config): + """Export logs that show total throttled Api requests for this + subscription in the given time window. + + :param parameters: Parameters supplied to the LogAnalytics + getThrottledRequests Api. + :type parameters: + ~azure.mgmt.compute.v2017_12_01.models.ThrottledRequestsInput + :param location: The location upon which virtual-machine-sizes is + queried. + :type location: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :return: An instance of AzureOperationPoller that returns + LogAnalyticsOperationResult or ClientRawResponse if raw=true + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.compute.v2017_12_01.models.LogAnalyticsOperationResult] + or ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + raw_result = self._export_throttled_requests_initial( + parameters=parameters, + location=location, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + if raw: + return raw_result + + # Construct and send request + def long_running_send(): + return raw_result.response + + def get_long_running_status(status_link, headers=None): + + request = self._client.get(status_link) + if headers: + request.headers.update(headers) + header_parameters = {} + header_parameters['x-ms-client-request-id'] = raw_result.response.request.headers['x-ms-client-request-id'] + return self._client.send( + request, header_parameters, stream=False, **operation_config) + + def get_long_running_output(response): + + if response.status_code not in [200, 202]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = self._deserialize('LogAnalyticsOperationResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + long_running_operation_timeout = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + return AzureOperationPoller( + long_running_send, get_long_running_output, + get_long_running_status, long_running_operation_timeout) diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machine_scale_sets_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machine_scale_sets_operations.py index 87c7283ce3f0..21c3229068c0 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machine_scale_sets_operations.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machine_scale_sets_operations.py @@ -1726,3 +1726,69 @@ def get_long_running_output(response): return AzureOperationPoller( long_running_send, get_long_running_output, get_long_running_status, long_running_operation_timeout) + + def force_recovery_service_fabric_platform_update_domain_walk( + self, resource_group_name, vm_scale_set_name, platform_update_domain, custom_headers=None, raw=False, **operation_config): + """Manual platform update domain walk to update virtual machines in a + service fabric virtual machine scale set. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param vm_scale_set_name: The name of the VM scale set. + :type vm_scale_set_name: str + :param platform_update_domain: The platform update domain for which a + manual recovery walk is requested + :type platform_update_domain: int + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: RecoveryWalkResponse or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.compute.v2017_12_01.models.RecoveryWalkResponse or + ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + # Construct URL + url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/forceRecoveryServiceFabricPlatformUpdateDomainWalk' + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'vmScaleSetName': self._serialize.url("vm_scale_set_name", vm_scale_set_name, 'str'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + query_parameters['platformUpdateDomain'] = self._serialize.query("platform_update_domain", platform_update_domain, 'int') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.post(url, query_parameters) + response = self._client.send(request, header_parameters, stream=False, **operation_config) + + if response.status_code not in [200]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('RecoveryWalkResponse', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized diff --git a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machines_operations.py b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machines_operations.py index d6213c43ff20..2ae281c79576 100644 --- a/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machines_operations.py +++ b/azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/operations/virtual_machines_operations.py @@ -281,6 +281,127 @@ def get_long_running_output(response): get_long_running_status, long_running_operation_timeout) + def _update_initial( + self, resource_group_name, vm_name, parameters, custom_headers=None, raw=False, **operation_config): + # Construct URL + url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines/{vmName}' + path_format_arguments = { + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'vmName': self._serialize.url("vm_name", vm_name, 'str'), + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + body_content = self._serialize.body(parameters, 'VirtualMachine') + + # Construct and send request + request = self._client.patch(url, query_parameters) + response = self._client.send( + request, header_parameters, body_content, stream=False, **operation_config) + + if response.status_code not in [200, 201]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('VirtualMachine', response) + if response.status_code == 201: + deserialized = self._deserialize('VirtualMachine', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + def update( + self, resource_group_name, vm_name, parameters, custom_headers=None, raw=False, **operation_config): + """The operation to update a virtual machine. + + :param resource_group_name: The name of the resource group. + :type resource_group_name: str + :param vm_name: The name of the virtual machine. + :type vm_name: str + :param parameters: Parameters supplied to the Update Virtual Machine + operation. + :type parameters: + ~azure.mgmt.compute.v2017_12_01.models.VirtualMachine + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :return: An instance of AzureOperationPoller that returns + VirtualMachine or ClientRawResponse if raw=true + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.compute.v2017_12_01.models.VirtualMachine] + or ~msrest.pipeline.ClientRawResponse + :raises: :class:`CloudError` + """ + raw_result = self._update_initial( + resource_group_name=resource_group_name, + vm_name=vm_name, + parameters=parameters, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + if raw: + return raw_result + + # Construct and send request + def long_running_send(): + return raw_result.response + + def get_long_running_status(status_link, headers=None): + + request = self._client.get(status_link) + if headers: + request.headers.update(headers) + header_parameters = {} + header_parameters['x-ms-client-request-id'] = raw_result.response.request.headers['x-ms-client-request-id'] + return self._client.send( + request, header_parameters, stream=False, **operation_config) + + def get_long_running_output(response): + + if response.status_code not in [200, 201]: + exp = CloudError(response) + exp.request_id = response.headers.get('x-ms-request-id') + raise exp + + deserialized = self._deserialize('VirtualMachine', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + long_running_operation_timeout = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + return AzureOperationPoller( + long_running_send, get_long_running_output, + get_long_running_status, long_running_operation_timeout) + + def _delete_initial( self, resource_group_name, vm_name, custom_headers=None, raw=False, **operation_config): # Construct URL