From f33a065eebe661516fc83739bbad2ef25ac7241f Mon Sep 17 00:00:00 2001 From: SDK Automation Date: Fri, 7 Aug 2020 07:18:54 +0000 Subject: [PATCH] Generated from f0657b98b307c9412b9e88aacb30020a38508d0d Update API description for SimulateEviction --- .../compute/mgmt/2020-06-01/compute/enums.go | 21 ++++++ .../compute/mgmt/2020-06-01/compute/models.go | 66 ++++++++++++++++++- .../2020-06-01/compute/virtualmachines.go | 3 +- .../compute/virtualmachinescalesetvms.go | 3 +- 4 files changed, 88 insertions(+), 5 deletions(-) diff --git a/services/compute/mgmt/2020-06-01/compute/enums.go b/services/compute/mgmt/2020-06-01/compute/enums.go index 3f698a23cbc0..558aade42519 100644 --- a/services/compute/mgmt/2020-06-01/compute/enums.go +++ b/services/compute/mgmt/2020-06-01/compute/enums.go @@ -843,6 +843,27 @@ func PossibleProximityPlacementGroupTypeValues() []ProximityPlacementGroupType { return []ProximityPlacementGroupType{Standard, Ultra} } +// RebootStatus enumerates the values for reboot status. +type RebootStatus string + +const ( + // RebootStatusCompleted ... + RebootStatusCompleted RebootStatus = "Completed" + // RebootStatusFailed ... + RebootStatusFailed RebootStatus = "Failed" + // RebootStatusNotNeeded ... + RebootStatusNotNeeded RebootStatus = "NotNeeded" + // RebootStatusRequired ... + RebootStatusRequired RebootStatus = "Required" + // RebootStatusStarted ... + RebootStatusStarted RebootStatus = "Started" +) + +// PossibleRebootStatusValues returns an array of possible values for the RebootStatus const type. +func PossibleRebootStatusValues() []RebootStatus { + return []RebootStatus{RebootStatusCompleted, RebootStatusFailed, RebootStatusNotNeeded, RebootStatusRequired, RebootStatusStarted} +} + // ReplicationState enumerates the values for replication state. type ReplicationState string diff --git a/services/compute/mgmt/2020-06-01/compute/models.go b/services/compute/mgmt/2020-06-01/compute/models.go index c29150164bf0..4047da39acda 100644 --- a/services/compute/mgmt/2020-06-01/compute/models.go +++ b/services/compute/mgmt/2020-06-01/compute/models.go @@ -487,6 +487,27 @@ func (asu *AvailabilitySetUpdate) UnmarshalJSON(body []byte) error { return nil } +// AvailablePatchSummary describes the properties of an virtual machine instance view for available patch +// summary. +type AvailablePatchSummary struct { + // Status - READ-ONLY; The overall success or failure status of the operation. It remains "InProgress" until the operation completes. At that point it will become "Failed", "Succeeded", or "CompletedWithWarnings.". Possible values include: 'PatchOperationStatusInProgress', 'PatchOperationStatusFailed', 'PatchOperationStatusSucceeded', 'PatchOperationStatusCompletedWithWarnings' + Status PatchOperationStatus `json:"status,omitempty"` + // AssessmentActivityID - READ-ONLY; The activity ID of the operation that produced this result. It is used to correlate across CRP and extension logs. + AssessmentActivityID *string `json:"assessmentActivityId,omitempty"` + // RebootPending - READ-ONLY; The overall reboot status of the VM. It will be true when partially installed patches require a reboot to complete installation but the reboot has not yet occurred. + RebootPending *bool `json:"rebootPending,omitempty"` + // CriticalAndSecurityPatchCount - READ-ONLY; The number of critical or security patches that have been detected as available and not yet installed. + CriticalAndSecurityPatchCount *int32 `json:"criticalAndSecurityPatchCount,omitempty"` + // OtherPatchCount - READ-ONLY; The number of all available patches excluding critical and security. + OtherPatchCount *int32 `json:"otherPatchCount,omitempty"` + // StartTime - READ-ONLY; The UTC timestamp when the operation began. + StartTime *date.Time `json:"startTime,omitempty"` + // LastModifiedTime - READ-ONLY; The UTC timestamp when the operation began. + LastModifiedTime *date.Time `json:"lastModifiedTime,omitempty"` + // Error - READ-ONLY; The errors that were encountered during execution of the operation. The details array contains the list of them. + Error *APIError `json:"error,omitempty"` +} + // BillingProfile specifies the billing related details of a Azure Spot VM or VMSS.

Minimum // api-version: 2019-03-01. type BillingProfile struct { @@ -6637,6 +6658,36 @@ type KeyVaultSecretReference struct { SourceVault *SubResource `json:"sourceVault,omitempty"` } +// LastPatchInstallationSummary describes the properties of the last installed patch summary. +type LastPatchInstallationSummary struct { + // Status - READ-ONLY; The overall success or failure status of the operation. It remains "InProgress" until the operation completes. At that point it will become "Failed", "Succeeded", or "CompletedWithWarnings.". Possible values include: 'PatchOperationStatusInProgress', 'PatchOperationStatusFailed', 'PatchOperationStatusSucceeded', 'PatchOperationStatusCompletedWithWarnings' + Status PatchOperationStatus `json:"status,omitempty"` + // InstallationActivityID - READ-ONLY; The activity ID of the operation that produced this result. It is used to correlate across CRP and extension logs. + InstallationActivityID *string `json:"installationActivityId,omitempty"` + // MaintenanceWindowExceeded - READ-ONLY; Describes whether the operation ran out of time before it completed all its intended actions + MaintenanceWindowExceeded *bool `json:"maintenanceWindowExceeded,omitempty"` + // RebootStatus - READ-ONLY; The reboot status of the machine after the patch operation. It will be in "NotNeeded" status if reboot is not needed after the patch operation. "Required" will be the status once the patch is applied and machine is required to reboot. "Started" will be the reboot status when the machine has started to reboot. "Failed" will be the status if the machine is failed to reboot. "Completed" will be the status once the machine is rebooted successfully. Possible values include: 'RebootStatusNotNeeded', 'RebootStatusRequired', 'RebootStatusStarted', 'RebootStatusFailed', 'RebootStatusCompleted' + RebootStatus RebootStatus `json:"rebootStatus,omitempty"` + // NotSelectedPatchCount - READ-ONLY; The number of all available patches but not going to be installed because it didn't match a classification or inclusion list entry. + NotSelectedPatchCount *int32 `json:"notSelectedPatchCount,omitempty"` + // ExcludedPatchCount - READ-ONLY; The number of all available patches but excluded explicitly by a customer-specified exclusion list match. + ExcludedPatchCount *int32 `json:"excludedPatchCount,omitempty"` + // PendingPatchCount - READ-ONLY; The number of all available patches expected to be installed over the course of the patch installation operation. + PendingPatchCount *int32 `json:"pendingPatchCount,omitempty"` + // InstalledPatchCount - READ-ONLY; The count of patches that successfully installed. + InstalledPatchCount *int32 `json:"installedPatchCount,omitempty"` + // FailedPatchCount - READ-ONLY; The count of patches that failed installation. + FailedPatchCount *int32 `json:"failedPatchCount,omitempty"` + // StartTime - READ-ONLY; The UTC timestamp when the operation began. + StartTime *date.Time `json:"startTime,omitempty"` + // LastModifiedTime - READ-ONLY; The UTC timestamp when the operation began. + LastModifiedTime *date.Time `json:"lastModifiedTime,omitempty"` + // StartedBy - READ-ONLY; The person or system account that started the operation + StartedBy *string `json:"startedBy,omitempty"` + // Error - READ-ONLY; The errors that were encountered during execution of the operation. The details array contains the list of them. + Error *APIError `json:"error,omitempty"` +} + // LinuxConfiguration specifies the Linux operating system settings on the virtual machine.

For a list // of supported Linux distributions, see [Linux on Azure-Endorsed // Distributions](https://docs.microsoft.com/azure/virtual-machines/virtual-machines-linux-endorsed-distros?toc=%2fazure%2fvirtual-machines%2flinux%2ftoc.json) @@ -7164,7 +7215,7 @@ type OSProfile struct { // PatchSettings ... type PatchSettings struct { - // PatchMode - Specifies the mode of in-guest patching to IaaS virtual machine.

Possible values are:

**Manual** - You control the application of patches to a virtual machine. You do this by applying patches manually inside the VM. In this mode, automatic updates are disabled; the property WindowsConfiguration.enableAutomaticUpdates must be false

**AutomaticByOS** - The virtual machine will automatically be updated by the OS. The property WindowsConfiguration.enableAutomaticUpdates must be true.

** AutomaticByPlatform** - the virtual machine will automatically updated by the OS. The properties provisionVMAgent and WindowsConfiguration.enableAutomaticUpdates must be true. Possible values include: 'Manual', 'AutomaticByOS', 'AutomaticByPlatform' + // PatchMode - Specifies the mode of in-guest patching to IaaS virtual machine.

Possible values are:

**Manual** - You control the application of patches to a virtual machine. You do this by applying patches manually inside the VM. In this mode, automatic updates are disabled; the property WindowsConfiguration.enableAutomaticUpdates must be false

**AutomaticByOS** - The virtual machine will automatically be updated by the OS. The property WindowsConfiguration.enableAutomaticUpdates must be true.

** AutomaticByPlatform** - the virtual machine will automatically updated by the platform. The properties provisionVMAgent and WindowsConfiguration.enableAutomaticUpdates must be true. Possible values include: 'Manual', 'AutomaticByOS', 'AutomaticByPlatform' PatchMode InGuestPatchMode `json:"patchMode,omitempty"` } @@ -10461,6 +10512,8 @@ type VirtualMachineInstanceView struct { AssignedHost *string `json:"assignedHost,omitempty"` // Statuses - The resource status information. Statuses *[]InstanceViewStatus `json:"statuses,omitempty"` + // PatchStatus - The status of virtual machine patch operations. + PatchStatus *VirtualMachinePatchStatus `json:"patchStatus,omitempty"` } // MarshalJSON is the custom marshaler for VirtualMachineInstanceView. @@ -10505,6 +10558,9 @@ func (vmiv VirtualMachineInstanceView) MarshalJSON() ([]byte, error) { if vmiv.Statuses != nil { objectMap["statuses"] = vmiv.Statuses } + if vmiv.PatchStatus != nil { + objectMap["patchStatus"] = vmiv.PatchStatus + } return json.Marshal(objectMap) } @@ -10664,6 +10720,14 @@ func NewVirtualMachineListResultPage(getNextPage func(context.Context, VirtualMa return VirtualMachineListResultPage{fn: getNextPage} } +// VirtualMachinePatchStatus the status of virtual machine patch operations. +type VirtualMachinePatchStatus struct { + // AvailablePatchSummary - The available patch summary of the latest assessment operation for the virtual machine. + AvailablePatchSummary *AvailablePatchSummary `json:"availablePatchSummary,omitempty"` + // LastPatchInstallationSummary - The installation summary of the latest installation operation for the virtual machine. + LastPatchInstallationSummary *LastPatchInstallationSummary `json:"lastPatchInstallationSummary,omitempty"` +} + // VirtualMachineProperties describes the properties of a Virtual Machine. type VirtualMachineProperties struct { // HardwareProfile - Specifies the hardware settings for the virtual machine. diff --git a/services/compute/mgmt/2020-06-01/compute/virtualmachines.go b/services/compute/mgmt/2020-06-01/compute/virtualmachines.go index e79f7122b30c..ac69843a71f6 100644 --- a/services/compute/mgmt/2020-06-01/compute/virtualmachines.go +++ b/services/compute/mgmt/2020-06-01/compute/virtualmachines.go @@ -1812,8 +1812,7 @@ func (client VirtualMachinesClient) RunCommandResponder(resp *http.Response) (re return } -// SimulateEviction the operation to simulate the eviction of spot virtual machine. The eviction will occur within 30 -// minutes of calling the API +// SimulateEviction the operation to simulate the eviction of spot virtual machine. // Parameters: // resourceGroupName - the name of the resource group. // VMName - the name of the virtual machine. diff --git a/services/compute/mgmt/2020-06-01/compute/virtualmachinescalesetvms.go b/services/compute/mgmt/2020-06-01/compute/virtualmachinescalesetvms.go index 21a2ee96fef3..8a39ff8f6638 100644 --- a/services/compute/mgmt/2020-06-01/compute/virtualmachinescalesetvms.go +++ b/services/compute/mgmt/2020-06-01/compute/virtualmachinescalesetvms.go @@ -1127,8 +1127,7 @@ func (client VirtualMachineScaleSetVMsClient) RunCommandResponder(resp *http.Res return } -// SimulateEviction the operation to simulate the eviction of spot virtual machine in a VM scale set. The eviction will -// occur within 30 minutes of calling the API +// SimulateEviction the operation to simulate the eviction of spot virtual machine in a VM scale set. // Parameters: // resourceGroupName - the name of the resource group. // VMScaleSetName - the name of the VM scale set.