NetworkConfiguration Class

  • java.lang.Object
    • com.microsoft.azure.management.batch.NetworkConfiguration

public class NetworkConfiguration

The network configuration for a pool.

Constructor Summary

Constructor Description
NetworkConfiguration()

Method Summary

Modifier and Type Method and Description
PoolEndpointConfiguration endpointConfiguration()

Get pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property.

PublicIPAddressConfiguration publicIPAddressConfiguration()

Get this property is only supported on Pools with the virtualMachineConfiguration property.

java.lang.String subnetId()

Get the virtual network must be in the same region and subscription as the Azure Batch account.

NetworkConfiguration withEndpointConfiguration(PoolEndpointConfiguration endpointConfiguration)

Set pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property.

NetworkConfiguration withPublicIPAddressConfiguration(PublicIPAddressConfiguration publicIPAddressConfiguration)

Set this property is only supported on Pools with the virtualMachineConfiguration property.

NetworkConfiguration withSubnetId(String subnetId)

Set the virtual network must be in the same region and subscription as the Azure Batch account.

Methods inherited from java.lang.Object

java.lang.Object.clone java.lang.Object.equals java.lang.Object.finalize java.lang.Object.getClass java.lang.Object.hashCode java.lang.Object.notify java.lang.Object.notifyAll java.lang.Object.toString java.lang.Object.wait java.lang.Object.wait java.lang.Object.wait

Constructor Details

NetworkConfiguration

public NetworkConfiguration()

Method Details

endpointConfiguration

public PoolEndpointConfiguration endpointConfiguration()

Get pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property.

Returns:

the endpointConfiguration value

publicIPAddressConfiguration

public PublicIPAddressConfiguration publicIPAddressConfiguration()

Get this property is only supported on Pools with the virtualMachineConfiguration property.

Returns:

the publicIPAddressConfiguration value

subnetId

public String subnetId()

Get the virtual network must be in the same region and subscription as the Azure Batch account. The specified subnet should have enough free IP addresses to accommodate the number of nodes in the pool. If the subnet doesn't have enough free IP addresses, the pool will partially allocate compute nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule tasks on the compute nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the compute nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the compute nodes to unusable. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication. For pools created with a virtual machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. For pools created with a cloud service configuration, enable ports 10100, 20100, and 30100. Also enable outbound connections to Azure Storage on port 443. For cloudServiceConfiguration pools, only 'classic' VNETs are supported. For more details see: https://docs.microsoft.com/en-us/azure/batch/batch-api-basics\#virtual-network-vnet-and-firewall-configuration.

Returns:

the subnetId value

withEndpointConfiguration

public NetworkConfiguration withEndpointConfiguration(PoolEndpointConfiguration endpointConfiguration)

Set pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property.

Parameters:

endpointConfiguration - the endpointConfiguration value to set

Returns:

the NetworkConfiguration object itself.

withPublicIPAddressConfiguration

public NetworkConfiguration withPublicIPAddressConfiguration(PublicIPAddressConfiguration publicIPAddressConfiguration)

Set this property is only supported on Pools with the virtualMachineConfiguration property.

Parameters:

publicIPAddressConfiguration - the publicIPAddressConfiguration value to set

Returns:

the NetworkConfiguration object itself.

withSubnetId

public NetworkConfiguration withSubnetId(String subnetId)

Set the virtual network must be in the same region and subscription as the Azure Batch account. The specified subnet should have enough free IP addresses to accommodate the number of nodes in the pool. If the subnet doesn't have enough free IP addresses, the pool will partially allocate compute nodes and a resize error will occur. The 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch service to be able to schedule tasks on the compute nodes. This can be verified by checking if the specified VNet has any associated Network Security Groups (NSG). If communication to the compute nodes in the specified subnet is denied by an NSG, then the Batch service will set the state of the compute nodes to unusable. If the specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be enabled for inbound communication. For pools created with a virtual machine configuration, enable ports 29876 and 29877, as well as port 22 for Linux and port 3389 for Windows. For pools created with a cloud service configuration, enable ports 10100, 20100, and 30100. Also enable outbound connections to Azure Storage on port 443. For cloudServiceConfiguration pools, only 'classic' VNETs are supported. For more details see: https://docs.microsoft.com/en-us/azure/batch/batch-api-basics\#virtual-network-vnet-and-firewall-configuration.

Parameters:

subnetId - the subnetId value to set

Returns:

the NetworkConfiguration object itself.

Applies to