Skip to content

Commit

Permalink
.NET SDK Resource Provider:'Compute'
Browse files Browse the repository at this point in the history
REST Spec PR 'Azure/azure-rest-api-specs#5753'
REST Spec PR Author 'robhat1'
REST Spec PR Last commit
  • Loading branch information
adxsdknet committed Apr 24, 2019
1 parent 750900f commit d8c4a9a
Show file tree
Hide file tree
Showing 11 changed files with 147 additions and 32 deletions.
2 changes: 1 addition & 1 deletion src/SDKs/Compute/AzSdk.RP.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!--This file and it's contents are updated at build time moving or editing might result in build failure. Take due deligence while editing this file-->
<PropertyGroup>
<AzureApiTag>Compute_2019-03-01;Compute_2018-09-30;Compute_2017-09-01;ContainerService_2017-01-31;</AzureApiTag>
<AzureApiTag>Compute_2019-03-01;Compute_2018-09-30;Compute_2019-04-01;ContainerService_2017-01-31;</AzureApiTag>
<PackageTags>$(PackageTags);$(CommonTags);$(AzureApiTag);</PackageTags>
</PropertyGroup>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,13 @@ public AutomaticOSUpgradePolicy()
/// <summary>
/// Initializes a new instance of the AutomaticOSUpgradePolicy class.
/// </summary>
/// <param name="enableAutomaticOSUpgrade">Whether OS upgrades should
/// automatically be applied to scale set instances in a rolling
/// fashion when a newer version of the image becomes available.
/// Default value is false.</param>
/// <param name="enableAutomaticOSUpgrade">Indicates whether OS
/// upgrades should automatically be applied to scale set instances in
/// a rolling fashion when a newer version of the OS image becomes
/// available. Default value is false. If this is set to true for
/// Windows based scale sets, recommendation is to set
/// [enableAutomaticUpdates](https://docs.microsoft.com/dotnet/api/microsoft.azure.management.compute.models.windowsconfiguration.enableautomaticupdates?view=azure-dotnet)
/// to false.</param>
/// <param name="disableAutomaticRollback">Whether OS image rollback
/// feature should be disabled. Default value is false.</param>
public AutomaticOSUpgradePolicy(bool? enableAutomaticOSUpgrade = default(bool?), bool? disableAutomaticRollback = default(bool?))
Expand All @@ -48,9 +51,13 @@ public AutomaticOSUpgradePolicy()
partial void CustomInit();

/// <summary>
/// Gets or sets whether OS upgrades should automatically be applied to
/// scale set instances in a rolling fashion when a newer version of
/// the image becomes available. Default value is false.
/// Gets or sets indicates whether OS upgrades should automatically be
/// applied to scale set instances in a rolling fashion when a newer
/// version of the OS image becomes available. Default value is false.
/// If this is set to true for Windows based scale sets, recommendation
/// is to set
/// [enableAutomaticUpdates](https://docs.microsoft.com/dotnet/api/microsoft.azure.management.compute.models.windowsconfiguration.enableautomaticupdates?view=azure-dotnet)
/// to false.
/// </summary>
[JsonProperty(PropertyName = "enableAutomaticOSUpgrade")]
public bool? EnableAutomaticOSUpgrade { get; set; }
Expand Down
13 changes: 12 additions & 1 deletion src/SDKs/Compute/Management.Compute/Generated/Models/DataDisk.cs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,10 @@ public DataDisk()
/// disk in a virtual machine image. &lt;br&gt;&lt;br&gt; This value
/// cannot be larger than 1023 GB</param>
/// <param name="managedDisk">The managed disk parameters.</param>
public DataDisk(int lun, string createOption, string name = default(string), VirtualHardDisk vhd = default(VirtualHardDisk), VirtualHardDisk image = default(VirtualHardDisk), CachingTypes? caching = default(CachingTypes?), bool? writeAcceleratorEnabled = default(bool?), int? diskSizeGB = default(int?), ManagedDiskParameters managedDisk = default(ManagedDiskParameters))
/// <param name="toBeDetached">Specifies whether the datadisk is in
/// process of detachment from the
/// VirtualMachine/VirtualMachineScaleset</param>
public DataDisk(int lun, string createOption, string name = default(string), VirtualHardDisk vhd = default(VirtualHardDisk), VirtualHardDisk image = default(VirtualHardDisk), CachingTypes? caching = default(CachingTypes?), bool? writeAcceleratorEnabled = default(bool?), int? diskSizeGB = default(int?), ManagedDiskParameters managedDisk = default(ManagedDiskParameters), bool? toBeDetached = default(bool?))
{
Lun = lun;
Name = name;
Expand All @@ -74,6 +77,7 @@ public DataDisk()
CreateOption = createOption;
DiskSizeGB = diskSizeGB;
ManagedDisk = managedDisk;
ToBeDetached = toBeDetached;
CustomInit();
}

Expand Down Expand Up @@ -161,6 +165,13 @@ public DataDisk()
[JsonProperty(PropertyName = "managedDisk")]
public ManagedDiskParameters ManagedDisk { get; set; }

/// <summary>
/// Gets or sets specifies whether the datadisk is in process of
/// detachment from the VirtualMachine/VirtualMachineScaleset
/// </summary>
[JsonProperty(PropertyName = "toBeDetached")]
public bool? ToBeDetached { get; set; }

/// <summary>
/// Validate the object.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,13 @@ public ResourceSkuLocationInfo()
/// <param name="location">Location of the SKU</param>
/// <param name="zones">List of availability zones where the SKU is
/// supported.</param>
public ResourceSkuLocationInfo(string location = default(string), IList<string> zones = default(IList<string>))
/// <param name="zoneDetails">Details of capabilities available to a
/// SKU in specific zones.</param>
public ResourceSkuLocationInfo(string location = default(string), IList<string> zones = default(IList<string>), IList<ResourceSkuZoneDetails> zoneDetails = default(IList<ResourceSkuZoneDetails>))
{
Location = location;
Zones = zones;
ZoneDetails = zoneDetails;
CustomInit();
}

Expand All @@ -55,5 +58,11 @@ public ResourceSkuLocationInfo()
[JsonProperty(PropertyName = "zones")]
public IList<string> Zones { get; private set; }

/// <summary>
/// Gets details of capabilities available to a SKU in specific zones.
/// </summary>
[JsonProperty(PropertyName = "zoneDetails")]
public IList<ResourceSkuZoneDetails> ZoneDetails { get; private set; }

}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
// <auto-generated>
// 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.
// </auto-generated>

namespace Microsoft.Azure.Management.Compute.Models
{
using Newtonsoft.Json;
using System.Collections;
using System.Collections.Generic;
using System.Linq;

/// <summary>
/// Describes The zonal capabilities of a SKU.
/// </summary>
public partial class ResourceSkuZoneDetails
{
/// <summary>
/// Initializes a new instance of the ResourceSkuZoneDetails class.
/// </summary>
public ResourceSkuZoneDetails()
{
CustomInit();
}

/// <summary>
/// Initializes a new instance of the ResourceSkuZoneDetails class.
/// </summary>
/// <param name="name">The set of zones that the SKU is available in
/// with the specified capabilities.</param>
/// <param name="capabilities">A list of capabilities that are
/// available for the SKU in the specified list of zones.</param>
public ResourceSkuZoneDetails(IList<string> name = default(IList<string>), IList<ResourceSkuCapabilities> capabilities = default(IList<ResourceSkuCapabilities>))
{
Name = name;
Capabilities = capabilities;
CustomInit();
}

/// <summary>
/// An initialization method that performs custom operations like setting defaults
/// </summary>
partial void CustomInit();

/// <summary>
/// Gets the set of zones that the SKU is available in with the
/// specified capabilities.
/// </summary>
[JsonProperty(PropertyName = "name")]
public IList<string> Name { get; private set; }

/// <summary>
/// Gets a list of capabilities that are available for the SKU in the
/// specified list of zones.
/// </summary>
[JsonProperty(PropertyName = "capabilities")]
public IList<ResourceSkuCapabilities> Capabilities { get; private set; }

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,15 @@ public VirtualMachineScaleSet()
/// the proximity placement group that the virtual machine scale set
/// should be assigned to. &lt;br&gt;&lt;br&gt;Minimum api-version:
/// 2018-04-01.</param>
/// <param name="additionalCapabilities">Specifies additional
/// capabilities enabled or disabled on the Virtual Machines in the
/// Virtual Machine Scale Set. For instance: whether the Virtual
/// Machines have the capability to support attaching managed data
/// disks with UltraSSD_LRS storage account type.</param>
/// <param name="identity">The identity of the virtual machine scale
/// set, if configured.</param>
/// <param name="zones">The virtual machine scale set zones.</param>
public VirtualMachineScaleSet(string location, string id = default(string), string name = default(string), string type = default(string), IDictionary<string, string> tags = default(IDictionary<string, string>), Sku sku = default(Sku), Plan plan = default(Plan), UpgradePolicy upgradePolicy = default(UpgradePolicy), VirtualMachineScaleSetVMProfile virtualMachineProfile = default(VirtualMachineScaleSetVMProfile), string provisioningState = default(string), bool? overprovision = default(bool?), bool? doNotRunExtensionsOnOverprovisionedVMs = default(bool?), string uniqueId = default(string), bool? singlePlacementGroup = default(bool?), bool? zoneBalance = default(bool?), int? platformFaultDomainCount = default(int?), SubResource proximityPlacementGroup = default(SubResource), VirtualMachineScaleSetIdentity identity = default(VirtualMachineScaleSetIdentity), IList<string> zones = default(IList<string>))
public VirtualMachineScaleSet(string location, string id = default(string), string name = default(string), string type = default(string), IDictionary<string, string> tags = default(IDictionary<string, string>), Sku sku = default(Sku), Plan plan = default(Plan), UpgradePolicy upgradePolicy = default(UpgradePolicy), VirtualMachineScaleSetVMProfile virtualMachineProfile = default(VirtualMachineScaleSetVMProfile), string provisioningState = default(string), bool? overprovision = default(bool?), bool? doNotRunExtensionsOnOverprovisionedVMs = default(bool?), string uniqueId = default(string), bool? singlePlacementGroup = default(bool?), bool? zoneBalance = default(bool?), int? platformFaultDomainCount = default(int?), SubResource proximityPlacementGroup = default(SubResource), AdditionalCapabilities additionalCapabilities = default(AdditionalCapabilities), VirtualMachineScaleSetIdentity identity = default(VirtualMachineScaleSetIdentity), IList<string> zones = default(IList<string>))
: base(location, id, name, type, tags)
{
Sku = sku;
Expand All @@ -91,6 +96,7 @@ public VirtualMachineScaleSet()
ZoneBalance = zoneBalance;
PlatformFaultDomainCount = platformFaultDomainCount;
ProximityPlacementGroup = proximityPlacementGroup;
AdditionalCapabilities = additionalCapabilities;
Identity = identity;
Zones = zones;
CustomInit();
Expand Down Expand Up @@ -189,6 +195,16 @@ public VirtualMachineScaleSet()
[JsonProperty(PropertyName = "properties.proximityPlacementGroup")]
public SubResource ProximityPlacementGroup { get; set; }

/// <summary>
/// Gets or sets specifies additional capabilities enabled or disabled
/// on the Virtual Machines in the Virtual Machine Scale Set. For
/// instance: whether the Virtual Machines have the capability to
/// support attaching managed data disks with UltraSSD_LRS storage
/// account type.
/// </summary>
[JsonProperty(PropertyName = "properties.additionalCapabilities")]
public AdditionalCapabilities AdditionalCapabilities { get; set; }

/// <summary>
/// Gets or sets the identity of the virtual machine scale set, if
/// configured.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,14 @@ public VirtualMachineScaleSetUpdate()
/// <param name="singlePlacementGroup">When true this limits the scale
/// set to a single placement group, of max size 100 virtual
/// machines.</param>
/// <param name="additionalCapabilities">Specifies additional
/// capabilities enabled or disabled on the Virtual Machines in the
/// Virtual Machine Scale Set. For instance: whether the Virtual
/// Machines have the capability to support attaching managed data
/// disks with UltraSSD_LRS storage account type.</param>
/// <param name="identity">The identity of the virtual machine scale
/// set, if configured.</param>
public VirtualMachineScaleSetUpdate(IDictionary<string, string> tags = default(IDictionary<string, string>), Sku sku = default(Sku), Plan plan = default(Plan), UpgradePolicy upgradePolicy = default(UpgradePolicy), VirtualMachineScaleSetUpdateVMProfile virtualMachineProfile = default(VirtualMachineScaleSetUpdateVMProfile), bool? overprovision = default(bool?), bool? singlePlacementGroup = default(bool?), VirtualMachineScaleSetIdentity identity = default(VirtualMachineScaleSetIdentity))
public VirtualMachineScaleSetUpdate(IDictionary<string, string> tags = default(IDictionary<string, string>), Sku sku = default(Sku), Plan plan = default(Plan), UpgradePolicy upgradePolicy = default(UpgradePolicy), VirtualMachineScaleSetUpdateVMProfile virtualMachineProfile = default(VirtualMachineScaleSetUpdateVMProfile), bool? overprovision = default(bool?), bool? singlePlacementGroup = default(bool?), AdditionalCapabilities additionalCapabilities = default(AdditionalCapabilities), VirtualMachineScaleSetIdentity identity = default(VirtualMachineScaleSetIdentity))
: base(tags)
{
Sku = sku;
Expand All @@ -59,6 +64,7 @@ public VirtualMachineScaleSetUpdate()
VirtualMachineProfile = virtualMachineProfile;
Overprovision = overprovision;
SinglePlacementGroup = singlePlacementGroup;
AdditionalCapabilities = additionalCapabilities;
Identity = identity;
CustomInit();
}
Expand Down Expand Up @@ -107,6 +113,16 @@ public VirtualMachineScaleSetUpdate()
[JsonProperty(PropertyName = "properties.singlePlacementGroup")]
public bool? SinglePlacementGroup { get; set; }

/// <summary>
/// Gets or sets specifies additional capabilities enabled or disabled
/// on the Virtual Machines in the Virtual Machine Scale Set. For
/// instance: whether the Virtual Machines have the capability to
/// support attaching managed data disks with UltraSSD_LRS storage
/// account type.
/// </summary>
[JsonProperty(PropertyName = "properties.additionalCapabilities")]
public AdditionalCapabilities AdditionalCapabilities { get; set; }

/// <summary>
/// Gets or sets the identity of the virtual machine scale set, if
/// configured.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,6 @@ public VirtualMachineScaleSetVMProfile()
/// the virtual machines in the scale set.</param>
/// <param name="storageProfile">Specifies the storage settings for the
/// virtual machine disks.</param>
/// <param name="additionalCapabilities">Specifies additional
/// capabilities enabled or disabled on the virtual machine in the
/// scale set. For instance: whether the virtual machine has the
/// capability to support attaching managed data disks with
/// UltraSSD_LRS storage account type.</param>
/// <param name="networkProfile">Specifies properties of the network
/// interfaces of the virtual machines in the scale set.</param>
/// <param name="diagnosticsProfile">Specifies the boot diagnostic
Expand Down Expand Up @@ -67,11 +62,10 @@ public VirtualMachineScaleSetVMProfile()
/// virtual machines in a low priority scale set.
/// &lt;br&gt;&lt;br&gt;Minimum api-version: 2017-10-30-preview.
/// Possible values include: 'Deallocate', 'Delete'</param>
public VirtualMachineScaleSetVMProfile(VirtualMachineScaleSetOSProfile osProfile = default(VirtualMachineScaleSetOSProfile), VirtualMachineScaleSetStorageProfile storageProfile = default(VirtualMachineScaleSetStorageProfile), AdditionalCapabilities additionalCapabilities = default(AdditionalCapabilities), VirtualMachineScaleSetNetworkProfile networkProfile = default(VirtualMachineScaleSetNetworkProfile), DiagnosticsProfile diagnosticsProfile = default(DiagnosticsProfile), VirtualMachineScaleSetExtensionProfile extensionProfile = default(VirtualMachineScaleSetExtensionProfile), string licenseType = default(string), string priority = default(string), string evictionPolicy = default(string))
public VirtualMachineScaleSetVMProfile(VirtualMachineScaleSetOSProfile osProfile = default(VirtualMachineScaleSetOSProfile), VirtualMachineScaleSetStorageProfile storageProfile = default(VirtualMachineScaleSetStorageProfile), VirtualMachineScaleSetNetworkProfile networkProfile = default(VirtualMachineScaleSetNetworkProfile), DiagnosticsProfile diagnosticsProfile = default(DiagnosticsProfile), VirtualMachineScaleSetExtensionProfile extensionProfile = default(VirtualMachineScaleSetExtensionProfile), string licenseType = default(string), string priority = default(string), string evictionPolicy = default(string))
{
OsProfile = osProfile;
StorageProfile = storageProfile;
AdditionalCapabilities = additionalCapabilities;
NetworkProfile = networkProfile;
DiagnosticsProfile = diagnosticsProfile;
ExtensionProfile = extensionProfile;
Expand Down Expand Up @@ -100,15 +94,6 @@ public VirtualMachineScaleSetVMProfile()
[JsonProperty(PropertyName = "storageProfile")]
public VirtualMachineScaleSetStorageProfile StorageProfile { get; set; }

/// <summary>
/// Gets or sets specifies additional capabilities enabled or disabled
/// on the virtual machine in the scale set. For instance: whether the
/// virtual machine has the capability to support attaching managed
/// data disks with UltraSSD_LRS storage account type.
/// </summary>
[JsonProperty(PropertyName = "additionalCapabilities")]
public AdditionalCapabilities AdditionalCapabilities { get; set; }

/// <summary>
/// Gets or sets specifies properties of the network interfaces of the
/// virtual machines in the scale set.
Expand Down
Loading

0 comments on commit d8c4a9a

Please sign in to comment.