Class AffinityInformation
- java.lang.Object
-
- com.microsoft.azure.batch.protocol.models.AffinityInformation
-
public class AffinityInformation extends Object
A locality hint that can be used by the Batch service to select a Compute Node on which to start a Task.
-
-
Constructor Summary
Constructors Constructor Description AffinityInformation()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
affinityId()
Get you can pass the affinityId of a Node to indicate that this Task needs to run on that Compute Node.AffinityInformation
withAffinityId(String affinityId)
Set you can pass the affinityId of a Node to indicate that this Task needs to run on that Compute Node.
-
-
-
Method Detail
-
affinityId
public String affinityId()
Get you can pass the affinityId of a Node to indicate that this Task needs to run on that Compute Node. Note that this is just a soft affinity. If the target Compute Node is busy or unavailable at the time the Task is scheduled, then the Task will be scheduled elsewhere.- Returns:
- the affinityId value
-
withAffinityId
public AffinityInformation withAffinityId(String affinityId)
Set you can pass the affinityId of a Node to indicate that this Task needs to run on that Compute Node. Note that this is just a soft affinity. If the target Compute 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 AffinityInformation object itself.
-
-