VirtualMachineScaleSet Interface

Implements

public interface VirtualMachineScaleSet
extends GroupableResource<ComputeManager,VirtualMachineScaleSetInner>, Refreshable<VirtualMachineScaleSet>, Updatable<WithPrimaryLoadBalancer>

An immutable client-side representation of an Azure virtual machine scale set.

Method Summary

Modifier and Type Method and Description
abstract AdditionalCapabilities additionalCapabilities()

Get specifies additional capabilities enabled or disabled on the Virtual Machines in the Virtual Machine Scale Set.

abstract List<String> applicationGatewayBackendAddressPoolsIds()
abstract List<String> applicationSecurityGroupIds()
abstract Set<AvailabilityZoneId> availabilityZones()
abstract BillingProfile billingProfile()
abstract String bootDiagnosticsStorageUri()
abstract int capacity()
abstract String computerNamePrefix()
abstract void deallocate()

Shuts down the virtual machines in the scale set and releases its compute resources.

abstract Mono<Void> deallocateAsync()

Shuts down the virtual machines in the scale set and releases its compute resources asynchronously.

abstract Boolean doNotRunExtensionsOnOverprovisionedVMs()
abstract Map<String,VirtualMachineScaleSetExtension> extensions()
abstract VirtualMachineScaleSetNetworkInterface getNetworkInterfaceByInstanceId(String instanceId, String name)

Gets a network interface associated with a virtual machine scale set instance.

abstract Mono<VirtualMachineScaleSetNetworkInterface> getNetworkInterfaceByInstanceIdAsync(String instanceId, String name)

Gets a network interface associated with a virtual machine scale set instance.

abstract LoadBalancer getPrimaryInternalLoadBalancer()
abstract LoadBalancer getPrimaryInternetFacingLoadBalancer()
abstract Network getPrimaryNetwork()
abstract boolean isAcceleratedNetworkingEnabled()
abstract boolean isBootDiagnosticsEnabled()
abstract boolean isEphemeralOSDisk()
abstract boolean isIpForwardingEnabled()
abstract boolean isManagedDiskEnabled()
abstract boolean isManagedServiceIdentityEnabled()
abstract boolean isSinglePlacementGroupEnabled()
abstract PagedIterable<VirtualMachineScaleSetSku> listAvailableSkus()
abstract PagedIterable<VirtualMachineScaleSetNetworkInterface> listNetworkInterfaces()
abstract PagedIterable<VirtualMachineScaleSetNetworkInterface> listNetworkInterfacesByInstanceId(String virtualMachineInstanceId)

Lists the network interface associated with a specific virtual machine instance in the scale set.

abstract PagedFlux<VirtualMachineScaleSetNetworkInterface> listNetworkInterfacesByInstanceIdAsync(String virtualMachineInstanceId)

Lists the network interface associated with a specific virtual machine instance in the scale set asynchronously.

abstract Map<String,LoadBalancerBackend> listPrimaryInternalLoadBalancerBackends()
abstract Map<String,LoadBalancerInboundNatPool> listPrimaryInternalLoadBalancerInboundNatPools()
abstract Map<String,LoadBalancerBackend> listPrimaryInternetFacingLoadBalancerBackends()
abstract Map<String,LoadBalancerInboundNatPool> listPrimaryInternetFacingLoadBalancerInboundNatPools()
abstract StorageAccountTypes managedOSDiskStorageAccountType()
abstract ResourceIdentityType managedServiceIdentityType()
abstract VirtualMachineScaleSetNetworkProfile networkProfile()
abstract String networkSecurityGroupId()
abstract OrchestrationMode orchestrationMode()

Get orchestration mode of the Virtual Machine Scale Set.

abstract CachingTypes osDiskCachingType()
abstract String osDiskName()
abstract OperatingSystemTypes osType()
abstract boolean overProvisionEnabled()
abstract Plan plan()
abstract void powerOff()

Powers off (stops) the virtual machines in the scale set.

abstract Mono<Void> powerOffAsync()

Powers off (stops) the virtual machines in the scale set asynchronously.

abstract List<String> primaryPublicIpAddressIds()
abstract ProximityPlacementGroup proximityPlacementGroup()

Get specifies information about the proximity placement group that the virtual machine scale set should be assigned to.

abstract void reimage()

Re-images (updates the version of the installed operating system) the virtual machines in the scale set.

abstract Mono<Void> reimageAsync()

Re-images (updates the version of the installed operating system) the virtual machines in the scale set asynchronously.

abstract void restart()

Restarts the virtual machines in the scale set.

abstract Mono<Void> restartAsync()

Restarts the virtual machines in the scale set asynchronously.

abstract RunCommandResult runCommandInVMInstance(String vmId, RunCommandInput inputCommand)

Run commands in a virtual machine instance in a scale set.

abstract Mono<RunCommandResult> runCommandVMInstanceAsync(String vmId, RunCommandInput inputCommand)

Run commands in a virtual machine instance in a scale set asynchronously.

abstract RunCommandResult runPowerShellScriptInVMInstance(String vmId, List<String> scriptLines, List<RunCommandInputParameter> scriptParameters)

Run PowerShell script in a virtual machine instance in a scale set.

abstract Mono<RunCommandResult> runPowerShellScriptInVMInstanceAsync(String vmId, List<String> scriptLines, List<RunCommandInputParameter> scriptParameters)

Run PowerShell in a virtual machine instance in a scale set asynchronously.

abstract RunCommandResult runShellScriptInVMInstance(String vmId, List<String> scriptLines, List<RunCommandInputParameter> scriptParameters)

Run shell script in a virtual machine instance in a scale set.

abstract Mono<RunCommandResult> runShellScriptInVMInstanceAsync(String vmId, List<String> scriptLines, List<RunCommandInputParameter> scriptParameters)

Run shell script in a virtual machine instance in a scale set asynchronously.

abstract VirtualMachineScaleSetSkuTypes sku()
abstract void start()

Starts the virtual machines in the scale set.

abstract Mono<Void> startAsync()

Starts the virtual machines in the scale set asynchronously.

abstract VirtualMachineScaleSetStorageProfile storageProfile()
abstract String systemAssignedManagedServiceIdentityPrincipalId()
abstract String systemAssignedManagedServiceIdentityTenantId()
abstract UpgradeMode upgradeModel()
abstract Set<String> userAssignedManagedServiceIdentityIds()
abstract List<String> vhdContainers()
abstract VirtualMachineEvictionPolicyTypes virtualMachineEvictionPolicy()
abstract VirtualMachinePriorityTypes virtualMachinePriority()
abstract VirtualMachineScaleSetPublicIpAddressConfiguration virtualMachinePublicIpConfig()
abstract VirtualMachineScaleSetVMs virtualMachines()

Method Details

additionalCapabilities

public abstract AdditionalCapabilities additionalCapabilities()

Get 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.

Returns:

the additionalCapabilities value

applicationGatewayBackendAddressPoolsIds

public abstract List applicationGatewayBackendAddressPoolsIds()

Returns:

the list of application gateway backend pool associated with the virtual machine scale set.

applicationSecurityGroupIds

public abstract List applicationSecurityGroupIds()

Returns:

the list of application security groups associated with the virtual machine scale set.

availabilityZones

public abstract Set availabilityZones()

Returns:

the availability zones assigned to virtual machine scale set.

billingProfile

public abstract BillingProfile billingProfile()

Returns:

the billing related details of the low priority virtual machines in the scale set.

bootDiagnosticsStorageUri

public abstract String bootDiagnosticsStorageUri()

Returns:

the storage blob endpoint uri if boot diagnostics is enabled for the virtual machine scale set.

capacity

public abstract int capacity()

Returns:

the number of virtual machine instances in the scale set

computerNamePrefix

public abstract String computerNamePrefix()

Returns:

the name prefix of the virtual machines in the scale set

deallocate

public abstract void deallocate()

Shuts down the virtual machines in the scale set and releases its compute resources.

deallocateAsync

public abstract Mono deallocateAsync()

Shuts down the virtual machines in the scale set and releases its compute resources asynchronously.

Returns:

a representation of the deferred computation of this call

doNotRunExtensionsOnOverprovisionedVMs

public abstract Boolean doNotRunExtensionsOnOverprovisionedVMs()

Returns:

When Overprovision is enabled, extensions are launched only on the requested number of VMs which are finally kept. This property will hence ensure that the extensions do not run on the extra overprovisioned VMs.

extensions

public abstract Map extensions()

Returns:

the extensions attached to the virtual machines in the scale set

getNetworkInterfaceByInstanceId

public abstract VirtualMachineScaleSetNetworkInterface getNetworkInterfaceByInstanceId(String instanceId, String name)

Gets a network interface associated with a virtual machine scale set instance.

Parameters:

instanceId - the virtual machine scale set vm instance ID
name - the network interface name

Returns:

the network interface

getNetworkInterfaceByInstanceIdAsync

public abstract Mono getNetworkInterfaceByInstanceIdAsync(String instanceId, String name)

Gets a network interface associated with a virtual machine scale set instance.

Parameters:

instanceId - the virtual machine scale set vm instance ID
name - the network interface name

Returns:

the network interface

getPrimaryInternalLoadBalancer

public abstract LoadBalancer getPrimaryInternalLoadBalancer()

Returns:

the internal load balancer associated with the primary network interface of the virtual machines in the scale set

Throws:

IOException

- the IO exception

getPrimaryInternetFacingLoadBalancer

public abstract LoadBalancer getPrimaryInternetFacingLoadBalancer()

Returns:

the Internet-facing load balancer associated with the primary network interface of the virtual machines in the scale set.

Throws:

IOException

- the IO exception

getPrimaryNetwork

public abstract Network getPrimaryNetwork()

Returns:

the virtual network associated with the primary network interfaces of the virtual machines in the scale set.

A primary internal load balancer associated with the primary network interfaces of the scale set virtual machine will be also belong to this network

Throws:

IOException

- the IO exception

isAcceleratedNetworkingEnabled

public abstract boolean isAcceleratedNetworkingEnabled()

Returns:

true if accelerated networking is enabled for the virtual machine scale set.

isBootDiagnosticsEnabled

public abstract boolean isBootDiagnosticsEnabled()

Returns:

true if boot diagnostics is enabled for the virtual machine scale set.

isEphemeralOSDisk

public abstract boolean isEphemeralOSDisk()

Returns:

whether the instance OS disk is ephemeral

isIpForwardingEnabled

public abstract boolean isIpForwardingEnabled()

Returns:

true if ip forwarding is enabled for the virtual machine scale set.

isManagedDiskEnabled

public abstract boolean isManagedDiskEnabled()

Returns:

true if managed disk is used for the virtual machine scale set's disks (os, data)

isManagedServiceIdentityEnabled

public abstract boolean isManagedServiceIdentityEnabled()

Returns:

true if Managed Service Identity is enabled for the virtual machine scale set

isSinglePlacementGroupEnabled

public abstract boolean isSinglePlacementGroupEnabled()

Returns:

true if single placement group is enabled for the virtual machine scale set.

listAvailableSkus

public abstract PagedIterable listAvailableSkus()

Returns:

available SKUs for the virtual machine scale set, including the minimum and maximum virtual machine instances allowed for a particular SKU

listNetworkInterfaces

public abstract PagedIterable listNetworkInterfaces()

Returns:

the network interfaces associated with all virtual machine instances in a scale set

listNetworkInterfacesByInstanceId

public abstract PagedIterable listNetworkInterfacesByInstanceId(String virtualMachineInstanceId)

Lists the network interface associated with a specific virtual machine instance in the scale set.

Parameters:

virtualMachineInstanceId - the instance ID

Returns:

the network interfaces

listNetworkInterfacesByInstanceIdAsync

public abstract PagedFlux listNetworkInterfacesByInstanceIdAsync(String virtualMachineInstanceId)

Lists the network interface associated with a specific virtual machine instance in the scale set asynchronously.

Parameters:

virtualMachineInstanceId - the instance ID

Returns:

the network interfaces

listPrimaryInternalLoadBalancerBackends

public abstract Map listPrimaryInternalLoadBalancerBackends()

Returns:

the internal load balancer's backends associated with the primary network interface of the virtual machines in the scale set

Throws:

IOException

- the IO exception

listPrimaryInternalLoadBalancerInboundNatPools

public abstract Map listPrimaryInternalLoadBalancerInboundNatPools()

Returns:

the inbound NAT pools of the internal load balancer associated with the primary network interface of the virtual machines in the scale set, if any.

Throws:

IOException

- the IO exception

listPrimaryInternetFacingLoadBalancerBackends

public abstract Map listPrimaryInternetFacingLoadBalancerBackends()

Returns:

the Internet-facing load balancer's backends associated with the primary network interface of the virtual machines in the scale set

Throws:

IOException

- the IO exception

listPrimaryInternetFacingLoadBalancerInboundNatPools

public abstract Map listPrimaryInternetFacingLoadBalancerInboundNatPools()

Returns:

the Internet-facing load balancer's inbound NAT pool associated with the primary network interface of the virtual machines in the scale set

Throws:

IOException

- the IO exception

managedOSDiskStorageAccountType

public abstract StorageAccountTypes managedOSDiskStorageAccountType()

Returns:

the storage account type of the OS managed disk. A null value will be returned if the virtual machine scale set is based on un-managed disk.

managedServiceIdentityType

public abstract ResourceIdentityType managedServiceIdentityType()

Returns:

the type of Managed Service Identity used for the virtual machine scale set.

networkProfile

public abstract VirtualMachineScaleSetNetworkProfile networkProfile()

Returns:

the network profile

networkSecurityGroupId

public abstract String networkSecurityGroupId()

Returns:

the network security group ARM id.

orchestrationMode

public abstract OrchestrationMode orchestrationMode()

Get orchestration mode of the Virtual Machine Scale Set. Scale set orchestration modes allow you to have greater control over how virtual machine instances are managed by the scale set.

Returns:

the orchestration mode of the virtual machine scale set

osDiskCachingType

public abstract CachingTypes osDiskCachingType()

Returns:

the operating system disk caching type

osDiskName

public abstract String osDiskName()

Returns:

the name of the OS disk of virtual machines in the scale set

osType

public abstract OperatingSystemTypes osType()

Returns:

the operating system of the virtual machines in the scale set

overProvisionEnabled

public abstract boolean overProvisionEnabled()

Returns:

true if over provision is enabled for the virtual machines, false otherwise

plan

public abstract Plan plan()

Returns:

the purchase plan information about marketplace image

powerOff

public abstract void powerOff()

Powers off (stops) the virtual machines in the scale set.

powerOffAsync

public abstract Mono powerOffAsync()

Powers off (stops) the virtual machines in the scale set asynchronously.

Returns:

a representation of the deferred computation of this call

primaryPublicIpAddressIds

public abstract List primaryPublicIpAddressIds()

Returns:

the list of IDs of the public IP addresses associated with the primary Internet-facing load balancer of the scale set

Throws:

IOException

- the IO exception

proximityPlacementGroup

public abstract ProximityPlacementGroup proximityPlacementGroup()

Get specifies information about the proximity placement group that the virtual machine scale set should be assigned to.

Returns:

the proximityPlacementGroup.

reimage

public abstract void reimage()

Re-images (updates the version of the installed operating system) the virtual machines in the scale set.

reimageAsync

public abstract Mono reimageAsync()

Re-images (updates the version of the installed operating system) the virtual machines in the scale set asynchronously.

Returns:

a representation of the deferred computation of this call

restart

public abstract void restart()

Restarts the virtual machines in the scale set.

restartAsync

public abstract Mono restartAsync()

Restarts the virtual machines in the scale set asynchronously.

Returns:

a representation of the deferred computation of this call

runCommandInVMInstance

public abstract RunCommandResult runCommandInVMInstance(String vmId, RunCommandInput inputCommand)

Run commands in a virtual machine instance in a scale set.

Parameters:

vmId - the virtual machine instance id
inputCommand - command input

Returns:

result of execution

runCommandVMInstanceAsync

public abstract Mono runCommandVMInstanceAsync(String vmId, RunCommandInput inputCommand)

Run commands in a virtual machine instance in a scale set asynchronously.

Parameters:

vmId - the virtual machine instance id
inputCommand - command input

Returns:

handle to the asynchronous execution

runPowerShellScriptInVMInstance

public abstract RunCommandResult runPowerShellScriptInVMInstance(String vmId, List scriptLines, List scriptParameters)

Run PowerShell script in a virtual machine instance in a scale set.

Parameters:

vmId - the virtual machine instance id
scriptLines - PowerShell script lines
scriptParameters - script parameters

Returns:

result of PowerShell script execution

runPowerShellScriptInVMInstanceAsync

public abstract Mono runPowerShellScriptInVMInstanceAsync(String vmId, List scriptLines, List scriptParameters)

Run PowerShell in a virtual machine instance in a scale set asynchronously.

Parameters:

vmId - the virtual machine instance id
scriptLines - PowerShell script lines
scriptParameters - script parameters

Returns:

handle to the asynchronous execution

runShellScriptInVMInstance

public abstract RunCommandResult runShellScriptInVMInstance(String vmId, List scriptLines, List scriptParameters)

Run shell script in a virtual machine instance in a scale set.

Parameters:

vmId - the virtual machine instance id
scriptLines - shell script lines
scriptParameters - script parameters

Returns:

result of shell script execution

runShellScriptInVMInstanceAsync

public abstract Mono runShellScriptInVMInstanceAsync(String vmId, List scriptLines, List scriptParameters)

Run shell script in a virtual machine instance in a scale set asynchronously.

Parameters:

vmId - the virtual machine instance id
scriptLines - shell script lines
scriptParameters - script parameters

Returns:

handle to the asynchronous execution

sku

public abstract VirtualMachineScaleSetSkuTypes sku()

Returns:

the SKU of the virtual machines in the scale set

start

public abstract void start()

Starts the virtual machines in the scale set.

startAsync

public abstract Mono startAsync()

Starts the virtual machines in the scale set asynchronously.

Returns:

a representation of the deferred computation of this call

storageProfile

public abstract VirtualMachineScaleSetStorageProfile storageProfile()

Returns:

the storage profile

systemAssignedManagedServiceIdentityPrincipalId

public abstract String systemAssignedManagedServiceIdentityPrincipalId()

Returns:

the System Assigned (Local) Managed Service Identity specific Active Directory service principal ID assigned to the virtual machine scale set.

systemAssignedManagedServiceIdentityTenantId

public abstract String systemAssignedManagedServiceIdentityTenantId()

Returns:

the System Assigned (Local) Managed Service Identity specific Active Directory tenant ID assigned to the virtual machine scale set.

upgradeModel

public abstract UpgradeMode upgradeModel()

Returns:

the upgrade model, null for scale set with FLEXIBLE

userAssignedManagedServiceIdentityIds

public abstract Set userAssignedManagedServiceIdentityIds()

Returns:

the resource ids of User Assigned Managed Service Identities associated with the virtual machine scale set.

vhdContainers

public abstract List vhdContainers()

Returns:

the URL to storage containers that store the VHDs of the virtual machines in the scale set

virtualMachineEvictionPolicy

public abstract VirtualMachineEvictionPolicyTypes virtualMachineEvictionPolicy()

Returns:

the eviction policy of the virtual machines in the scale set.

virtualMachinePriority

public abstract VirtualMachinePriorityTypes virtualMachinePriority()

Returns:

the priority of virtual machines in the scale set.

virtualMachinePublicIpConfig

public abstract VirtualMachineScaleSetPublicIpAddressConfiguration virtualMachinePublicIpConfig()

Returns:

the public ip configuration of virtual machines in the scale set.

virtualMachines

public abstract VirtualMachineScaleSetVMs virtualMachines()

Returns:

entry point to manage virtual machine instances in the scale set.

Applies to