Class PatchSettings


  • public final class PatchSettings
    extends Object
    Specifies settings related to VM Guest Patching on Windows.
    • Constructor Summary

      Constructors 
      Constructor Description
      PatchSettings()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      WindowsPatchAssessmentMode assessmentMode()
      Get the assessmentMode property: Specifies the mode of VM Guest patch assessment for the IaaS virtual machine.<br /><br /> Possible values are:<br /><br /> **ImageDefault** - You control the timing of patch assessments on a virtual machine.<br /><br /> **AutomaticByPlatform** - The platform will trigger periodic patch assessments.
      Boolean enableHotpatching()
      Get the enableHotpatching property: Enables customers to patch their Azure VMs without requiring a reboot.
      WindowsVMGuestPatchMode patchMode()
      Get the patchMode property: Specifies the mode of VM Guest Patching to IaaS virtual machine or virtual machines associated to virtual machine scale set with OrchestrationMode as Flexible.<br /><br /> Possible values are:<br /><br /> **Manual** - You control the application of patches to a virtual machine.
      void validate()
      Validates the instance.
      PatchSettings withAssessmentMode​(WindowsPatchAssessmentMode assessmentMode)
      Set the assessmentMode property: Specifies the mode of VM Guest patch assessment for the IaaS virtual machine.<br /><br /> Possible values are:<br /><br /> **ImageDefault** - You control the timing of patch assessments on a virtual machine.<br /><br /> **AutomaticByPlatform** - The platform will trigger periodic patch assessments.
      PatchSettings withEnableHotpatching​(Boolean enableHotpatching)
      Set the enableHotpatching property: Enables customers to patch their Azure VMs without requiring a reboot.
      PatchSettings withPatchMode​(WindowsVMGuestPatchMode patchMode)
      Set the patchMode property: Specifies the mode of VM Guest Patching to IaaS virtual machine or virtual machines associated to virtual machine scale set with OrchestrationMode as Flexible.<br /><br /> Possible values are:<br /><br /> **Manual** - You control the application of patches to a virtual machine.
    • Constructor Detail

      • PatchSettings

        public PatchSettings()
    • Method Detail

      • patchMode

        public WindowsVMGuestPatchMode patchMode()
        Get the patchMode property: Specifies the mode of VM Guest Patching to IaaS virtual machine or virtual machines associated to virtual machine scale set with OrchestrationMode as Flexible.<br /><br /> Possible values are:<br /><br /> **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<br /><br /> **AutomaticByOS** - The virtual machine will automatically be updated by the OS. The property WindowsConfiguration.enableAutomaticUpdates must be true. <br /><br /> **AutomaticByPlatform** - the virtual machine will automatically updated by the platform. The properties provisionVMAgent and WindowsConfiguration.enableAutomaticUpdates must be true.
        Returns:
        the patchMode value.
      • withPatchMode

        public PatchSettings withPatchMode​(WindowsVMGuestPatchMode patchMode)
        Set the patchMode property: Specifies the mode of VM Guest Patching to IaaS virtual machine or virtual machines associated to virtual machine scale set with OrchestrationMode as Flexible.<br /><br /> Possible values are:<br /><br /> **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<br /><br /> **AutomaticByOS** - The virtual machine will automatically be updated by the OS. The property WindowsConfiguration.enableAutomaticUpdates must be true. <br /><br /> **AutomaticByPlatform** - the virtual machine will automatically updated by the platform. The properties provisionVMAgent and WindowsConfiguration.enableAutomaticUpdates must be true.
        Parameters:
        patchMode - the patchMode value to set.
        Returns:
        the PatchSettings object itself.
      • enableHotpatching

        public Boolean enableHotpatching()
        Get the enableHotpatching property: Enables customers to patch their Azure VMs without requiring a reboot. For enableHotpatching, the 'provisionVMAgent' must be set to true and 'patchMode' must be set to 'AutomaticByPlatform'.
        Returns:
        the enableHotpatching value.
      • withEnableHotpatching

        public PatchSettings withEnableHotpatching​(Boolean enableHotpatching)
        Set the enableHotpatching property: Enables customers to patch their Azure VMs without requiring a reboot. For enableHotpatching, the 'provisionVMAgent' must be set to true and 'patchMode' must be set to 'AutomaticByPlatform'.
        Parameters:
        enableHotpatching - the enableHotpatching value to set.
        Returns:
        the PatchSettings object itself.
      • assessmentMode

        public WindowsPatchAssessmentMode assessmentMode()
        Get the assessmentMode property: Specifies the mode of VM Guest patch assessment for the IaaS virtual machine.<br /><br /> Possible values are:<br /><br /> **ImageDefault** - You control the timing of patch assessments on a virtual machine.<br /><br /> **AutomaticByPlatform** - The platform will trigger periodic patch assessments. The property provisionVMAgent must be true.
        Returns:
        the assessmentMode value.
      • withAssessmentMode

        public PatchSettings withAssessmentMode​(WindowsPatchAssessmentMode assessmentMode)
        Set the assessmentMode property: Specifies the mode of VM Guest patch assessment for the IaaS virtual machine.<br /><br /> Possible values are:<br /><br /> **ImageDefault** - You control the timing of patch assessments on a virtual machine.<br /><br /> **AutomaticByPlatform** - The platform will trigger periodic patch assessments. The property provisionVMAgent must be true.
        Parameters:
        assessmentMode - the assessmentMode value to set.
        Returns:
        the PatchSettings object itself.
      • validate

        public void validate()
        Validates the instance.
        Throws:
        IllegalArgumentException - thrown if the instance is not valid.