ComputeNode Class

  • java.lang.Object
    • com.microsoft.azure.batch.protocol.models.ComputeNode

public class ComputeNode

A compute node in the Batch service.

Method Summary

Modifier and Type Method and Description
String affinityId()

Get note that this is just a soft affinity. If the target node is busy or unavailable at the time the task is scheduled, then the task will be scheduled elsewhere.

DateTime allocationTime()

Get this is the time when the node was initially allocated and doesn't change once set. It is not updated when the node is service healed or preempted.

List<CertificateReference> certificateReferences()

Get for Windows compute nodes, the Batch service installs the certificates to the specified certificate store and location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory.

ComputeNodeEndpointConfiguration endpointConfiguration()

Get the endpointConfiguration value.

List<ComputeNodeError> errors()

Get the errors value.

String id()

Get every node that is added to a pool is assigned a unique ID. Whenever a node is removed from a pool, all of its local files are deleted, and the ID is reclaimed and could be reused for new nodes.

String ipAddress()

Get every node that is added to a pool is assigned a unique IP address. Whenever a node is removed from a pool, all of its local files are deleted, and the IP address is reclaimed and could be reused for new nodes.

Boolean isDedicated()

Get the isDedicated value.

DateTime lastBootTime()

Get this property may not be present if the node state is unusable.

NodeAgentInformation nodeAgentInfo()

Get the nodeAgentInfo value.

List<TaskInformation> recentTasks()

Get this property is present only if at least one task has run on this node since it was assigned to the pool.

Integer runningTasksCount()

Get the runningTasksCount value.

SchedulingState schedulingState()

Get possible values include: 'enabled', 'disabled'.

StartTask startTask()

Get the startTask value.

StartTaskInformation startTaskInfo()

Get the startTaskInfo value.

ComputeNodeState state()

Get the low-priority node has been preempted. Tasks which were running on the node when it was pre-empted will be rescheduled when another node becomes available. Possible values include: 'idle', 'rebooting', 'reimaging', 'running', 'unusable', 'creating', 'starting', 'waitingForStartTask', 'startTaskFailed', 'unknown', 'leavingPool', 'offline', 'preempted'.

DateTime stateTransitionTime()

Get the stateTransitionTime value.

Integer totalTasksRun()

Get the totalTasksRun value.

Integer totalTasksSucceeded()

Get the totalTasksSucceeded value.

String url()

Get the url value.

String vmSize()

Get for information about available sizes of virtual machines in pools, see Choose a VM size for compute nodes in an Azure Batch pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes).

ComputeNode withAffinityId(String affinityId)

Set note that this is just a soft affinity. If the target node is busy or unavailable at the time the task is scheduled, then the task will be scheduled elsewhere.

ComputeNode withAllocationTime(DateTime allocationTime)

Set this is the time when the node was initially allocated and doesn't change once set. It is not updated when the node is service healed or preempted.

ComputeNode withCertificateReferences(List<CertificateReference> certificateReferences)

Set for Windows compute nodes, the Batch service installs the certificates to the specified certificate store and location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory.

ComputeNode withEndpointConfiguration(ComputeNodeEndpointConfiguration endpointConfiguration)

Set the endpointConfiguration value.

ComputeNode withErrors(List<ComputeNodeError> errors)

Set the errors value.

ComputeNode withId(String id)

Set every node that is added to a pool is assigned a unique ID. Whenever a node is removed from a pool, all of its local files are deleted, and the ID is reclaimed and could be reused for new nodes.

ComputeNode withIpAddress(String ipAddress)

Set every node that is added to a pool is assigned a unique IP address. Whenever a node is removed from a pool, all of its local files are deleted, and the IP address is reclaimed and could be reused for new nodes.

ComputeNode withIsDedicated(Boolean isDedicated)

Set the isDedicated value.

ComputeNode withLastBootTime(DateTime lastBootTime)

Set this property may not be present if the node state is unusable.

ComputeNode withNodeAgentInfo(NodeAgentInformation nodeAgentInfo)

Set the nodeAgentInfo value.

ComputeNode withRecentTasks(List<TaskInformation> recentTasks)

Set this property is present only if at least one task has run on this node since it was assigned to the pool.

ComputeNode withRunningTasksCount(Integer runningTasksCount)

Set the runningTasksCount value.

ComputeNode withSchedulingState(SchedulingState schedulingState)

Set possible values include: 'enabled', 'disabled'.

ComputeNode withStartTask(StartTask startTask)

Set the startTask value.

ComputeNode withStartTaskInfo(StartTaskInformation startTaskInfo)

Set the startTaskInfo value.

ComputeNode withState(ComputeNodeState state)

Set the low-priority node has been preempted. Tasks which were running on the node when it was pre-empted will be rescheduled when another node becomes available. Possible values include: 'idle', 'rebooting', 'reimaging', 'running', 'unusable', 'creating', 'starting', 'waitingForStartTask', 'startTaskFailed', 'unknown', 'leavingPool', 'offline', 'preempted'.

ComputeNode withStateTransitionTime(DateTime stateTransitionTime)

Set the stateTransitionTime value.

ComputeNode withTotalTasksRun(Integer totalTasksRun)

Set the totalTasksRun value.

ComputeNode withTotalTasksSucceeded(Integer totalTasksSucceeded)

Set the totalTasksSucceeded value.

ComputeNode withUrl(String url)

Set the url value.

ComputeNode withVmSize(String vmSize)

Set for information about available sizes of virtual machines in pools, see Choose a VM size for compute nodes in an Azure Batch pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes).

Method Details

affinityId

public String affinityId()

Get note that this is just a soft affinity. If the target node is busy or unavailable at the time the task is scheduled, then the task will be scheduled elsewhere.

Returns:

the affinityId value

allocationTime

public DateTime allocationTime()

Get this is the time when the node was initially allocated and doesn't change once set. It is not updated when the node is service healed or preempted.

Returns:

the allocationTime value

certificateReferences

public List certificateReferences()

Get for Windows compute nodes, the Batch service installs the certificates to the specified certificate store and location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory.

Returns:

the certificateReferences value

endpointConfiguration

public ComputeNodeEndpointConfiguration endpointConfiguration()

Get the endpointConfiguration value.

Returns:

the endpointConfiguration value

errors

public List errors()

Get the errors value.

Returns:

the errors value

id

public String id()

Get every node that is added to a pool is assigned a unique ID. Whenever a node is removed from a pool, all of its local files are deleted, and the ID is reclaimed and could be reused for new nodes.

Returns:

the id value

ipAddress

public String ipAddress()

Get every node that is added to a pool is assigned a unique IP address. Whenever a node is removed from a pool, all of its local files are deleted, and the IP address is reclaimed and could be reused for new nodes.

Returns:

the ipAddress value

isDedicated

public Boolean isDedicated()

Get the isDedicated value.

Returns:

the isDedicated value

lastBootTime

public DateTime lastBootTime()

Get this property may not be present if the node state is unusable.

Returns:

the lastBootTime value

nodeAgentInfo

public NodeAgentInformation nodeAgentInfo()

Get the nodeAgentInfo value.

Returns:

the nodeAgentInfo value

recentTasks

public List recentTasks()

Get this property is present only if at least one task has run on this node since it was assigned to the pool.

Returns:

the recentTasks value

runningTasksCount

public Integer runningTasksCount()

Get the runningTasksCount value.

Returns:

the runningTasksCount value

schedulingState

public SchedulingState schedulingState()

Get possible values include: 'enabled', 'disabled'.

Returns:

the schedulingState value

startTask

public StartTask startTask()

Get the startTask value.

Returns:

the startTask value

startTaskInfo

public StartTaskInformation startTaskInfo()

Get the startTaskInfo value.

Returns:

the startTaskInfo value

state

public ComputeNodeState state()

Get the low-priority node has been preempted. Tasks which were running on the node when it was pre-empted will be rescheduled when another node becomes available. Possible values include: 'idle', 'rebooting', 'reimaging', 'running', 'unusable', 'creating', 'starting', 'waitingForStartTask', 'startTaskFailed', 'unknown', 'leavingPool', 'offline', 'preempted'.

Returns:

the state value

stateTransitionTime

public DateTime stateTransitionTime()

Get the stateTransitionTime value.

Returns:

the stateTransitionTime value

totalTasksRun

public Integer totalTasksRun()

Get the totalTasksRun value.

Returns:

the totalTasksRun value

totalTasksSucceeded

public Integer totalTasksSucceeded()

Get the totalTasksSucceeded value.

Returns:

the totalTasksSucceeded value

url

public String url()

Get the url value.

Returns:

the url value

vmSize

public String vmSize()

Get for information about available sizes of virtual machines in pools, see Choose a VM size for compute nodes in an Azure Batch pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes).

Returns:

the vmSize value

withAffinityId

public ComputeNode withAffinityId(String affinityId)

Set note that this is just a soft affinity. If the target node is busy or unavailable at the time the task is scheduled, then the task will be scheduled elsewhere.

Parameters:

affinityId - the affinityId value to set

Returns:

the ComputeNode object itself.

withAllocationTime

public ComputeNode withAllocationTime(DateTime allocationTime)

Set this is the time when the node was initially allocated and doesn't change once set. It is not updated when the node is service healed or preempted.

Parameters:

allocationTime - the allocationTime value to set

Returns:

the ComputeNode object itself.

withCertificateReferences

public ComputeNode withCertificateReferences(List certificateReferences)

Set for Windows compute nodes, the Batch service installs the certificates to the specified certificate store and location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory.

Parameters:

certificateReferences - the certificateReferences value to set

Returns:

the ComputeNode object itself.

withEndpointConfiguration

public ComputeNode withEndpointConfiguration(ComputeNodeEndpointConfiguration endpointConfiguration)

Set the endpointConfiguration value.

Parameters:

endpointConfiguration - the endpointConfiguration value to set

Returns:

the ComputeNode object itself.

withErrors

public ComputeNode withErrors(List errors)

Set the errors value.

Parameters:

errors - the errors value to set

Returns:

the ComputeNode object itself.

withId

public ComputeNode withId(String id)

Set every node that is added to a pool is assigned a unique ID. Whenever a node is removed from a pool, all of its local files are deleted, and the ID is reclaimed and could be reused for new nodes.

Parameters:

id - the id value to set

Returns:

the ComputeNode object itself.

withIpAddress

public ComputeNode withIpAddress(String ipAddress)

Set every node that is added to a pool is assigned a unique IP address. Whenever a node is removed from a pool, all of its local files are deleted, and the IP address is reclaimed and could be reused for new nodes.

Parameters:

ipAddress - the ipAddress value to set

Returns:

the ComputeNode object itself.

withIsDedicated

public ComputeNode withIsDedicated(Boolean isDedicated)

Set the isDedicated value.

Parameters:

isDedicated - the isDedicated value to set

Returns:

the ComputeNode object itself.

withLastBootTime

public ComputeNode withLastBootTime(DateTime lastBootTime)

Set this property may not be present if the node state is unusable.

Parameters:

lastBootTime - the lastBootTime value to set

Returns:

the ComputeNode object itself.

withNodeAgentInfo

public ComputeNode withNodeAgentInfo(NodeAgentInformation nodeAgentInfo)

Set the nodeAgentInfo value.

Parameters:

nodeAgentInfo - the nodeAgentInfo value to set

Returns:

the ComputeNode object itself.

withRecentTasks

public ComputeNode withRecentTasks(List recentTasks)

Set this property is present only if at least one task has run on this node since it was assigned to the pool.

Parameters:

recentTasks - the recentTasks value to set

Returns:

the ComputeNode object itself.

withRunningTasksCount

public ComputeNode withRunningTasksCount(Integer runningTasksCount)

Set the runningTasksCount value.

Parameters:

runningTasksCount - the runningTasksCount value to set

Returns:

the ComputeNode object itself.

withSchedulingState

public ComputeNode withSchedulingState(SchedulingState schedulingState)

Set possible values include: 'enabled', 'disabled'.

Parameters:

schedulingState - the schedulingState value to set

Returns:

the ComputeNode object itself.

withStartTask

public ComputeNode withStartTask(StartTask startTask)

Set the startTask value.

Parameters:

startTask - the startTask value to set

Returns:

the ComputeNode object itself.

withStartTaskInfo

public ComputeNode withStartTaskInfo(StartTaskInformation startTaskInfo)

Set the startTaskInfo value.

Parameters:

startTaskInfo - the startTaskInfo value to set

Returns:

the ComputeNode object itself.

withState

public ComputeNode withState(ComputeNodeState state)

Set the low-priority node has been preempted. Tasks which were running on the node when it was pre-empted will be rescheduled when another node becomes available. Possible values include: 'idle', 'rebooting', 'reimaging', 'running', 'unusable', 'creating', 'starting', 'waitingForStartTask', 'startTaskFailed', 'unknown', 'leavingPool', 'offline', 'preempted'.

Parameters:

state - the state value to set

Returns:

the ComputeNode object itself.

withStateTransitionTime

public ComputeNode withStateTransitionTime(DateTime stateTransitionTime)

Set the stateTransitionTime value.

Parameters:

stateTransitionTime - the stateTransitionTime value to set

Returns:

the ComputeNode object itself.

withTotalTasksRun

public ComputeNode withTotalTasksRun(Integer totalTasksRun)

Set the totalTasksRun value.

Parameters:

totalTasksRun - the totalTasksRun value to set

Returns:

the ComputeNode object itself.

withTotalTasksSucceeded

public ComputeNode withTotalTasksSucceeded(Integer totalTasksSucceeded)

Set the totalTasksSucceeded value.

Parameters:

totalTasksSucceeded - the totalTasksSucceeded value to set

Returns:

the ComputeNode object itself.

withUrl

public ComputeNode withUrl(String url)

Set the url value.

Parameters:

url - the url value to set

Returns:

the ComputeNode object itself.

withVmSize

public ComputeNode withVmSize(String vmSize)

Set for information about available sizes of virtual machines in pools, see Choose a VM size for compute nodes in an Azure Batch pool (https://docs.microsoft.com/azure/batch/batch-pool-vm-sizes).

Parameters:

vmSize - the vmSize value to set

Returns:

the ComputeNode object itself.

Applies to