Class AutomaticOSUpgradePolicy
- java.lang.Object
-
- com.azure.resourcemanager.compute.models.AutomaticOSUpgradePolicy
-
public final class AutomaticOSUpgradePolicy extends Object
The configuration parameters used for performing automatic OS upgrade.
-
-
Constructor Summary
Constructors Constructor Description AutomaticOSUpgradePolicy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BooleandisableAutomaticRollback()Get the disableAutomaticRollback property: Whether OS image rollback feature should be disabled.BooleanenableAutomaticOSUpgrade()Get the enableAutomaticOSUpgrade property: 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.voidvalidate()Validates the instance.AutomaticOSUpgradePolicywithDisableAutomaticRollback(Boolean disableAutomaticRollback)Set the disableAutomaticRollback property: Whether OS image rollback feature should be disabled.AutomaticOSUpgradePolicywithEnableAutomaticOSUpgrade(Boolean enableAutomaticOSUpgrade)Set the enableAutomaticOSUpgrade property: 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.
-
-
-
Method Detail
-
enableAutomaticOSUpgrade
public Boolean enableAutomaticOSUpgrade()
Get the enableAutomaticOSUpgrade property: 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. <br><br> If this is set to true for Windows based scale sets, [enableAutomaticUpdates](https://docs.microsoft.com/dotnet/api/microsoft.azure.management.compute.models.windowsconfiguration.enableautomaticupdates?view=azure-dotnet) is automatically set to false and cannot be set to true.- Returns:
- the enableAutomaticOSUpgrade value.
-
withEnableAutomaticOSUpgrade
public AutomaticOSUpgradePolicy withEnableAutomaticOSUpgrade(Boolean enableAutomaticOSUpgrade)
Set the enableAutomaticOSUpgrade property: 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. <br><br> If this is set to true for Windows based scale sets, [enableAutomaticUpdates](https://docs.microsoft.com/dotnet/api/microsoft.azure.management.compute.models.windowsconfiguration.enableautomaticupdates?view=azure-dotnet) is automatically set to false and cannot be set to true.- Parameters:
enableAutomaticOSUpgrade- the enableAutomaticOSUpgrade value to set.- Returns:
- the AutomaticOSUpgradePolicy object itself.
-
disableAutomaticRollback
public Boolean disableAutomaticRollback()
Get the disableAutomaticRollback property: Whether OS image rollback feature should be disabled. Default value is false.- Returns:
- the disableAutomaticRollback value.
-
withDisableAutomaticRollback
public AutomaticOSUpgradePolicy withDisableAutomaticRollback(Boolean disableAutomaticRollback)
Set the disableAutomaticRollback property: Whether OS image rollback feature should be disabled. Default value is false.- Parameters:
disableAutomaticRollback- the disableAutomaticRollback value to set.- Returns:
- the AutomaticOSUpgradePolicy object itself.
-
validate
public void validate()
Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
-