|
@@ -124,7 +124,7 @@ public class LeafQueue implements CSQueue {
|
|
|
|
|
|
private final ActiveUsersManager activeUsersManager;
|
|
|
|
|
|
- private final int nodeLocalityDelay;
|
|
|
+ private int nodeLocalityDelay;
|
|
|
|
|
|
public LeafQueue(CapacitySchedulerContext cs,
|
|
|
String queueName, CSQueue parent,
|
|
@@ -189,9 +189,6 @@ public class LeafQueue implements CSQueue {
|
|
|
|
|
|
Map<QueueACL, AccessControlList> acls =
|
|
|
cs.getConfiguration().getAcls(getQueuePath());
|
|
|
-
|
|
|
- this.nodeLocalityDelay =
|
|
|
- cs.getConfiguration().getNodeLocalityDelay();
|
|
|
|
|
|
setupQueueConfigs(
|
|
|
cs.getClusterResources(),
|
|
@@ -200,7 +197,7 @@ public class LeafQueue implements CSQueue {
|
|
|
userLimit, userLimitFactor,
|
|
|
maxApplications, maxApplicationsPerUser,
|
|
|
maxActiveApplications, maxActiveApplicationsPerUser,
|
|
|
- state, acls);
|
|
|
+ state, acls, cs.getConfiguration().getNodeLocalityDelay());
|
|
|
|
|
|
if(LOG.isDebugEnabled()) {
|
|
|
LOG.debug("LeafQueue:" + " name=" + queueName
|
|
@@ -219,7 +216,8 @@ public class LeafQueue implements CSQueue {
|
|
|
int userLimit, float userLimitFactor,
|
|
|
int maxApplications, int maxApplicationsPerUser,
|
|
|
int maxActiveApplications, int maxActiveApplicationsPerUser,
|
|
|
- QueueState state, Map<QueueACL, AccessControlList> acls)
|
|
|
+ QueueState state, Map<QueueACL, AccessControlList> acls,
|
|
|
+ int nodeLocalityDelay)
|
|
|
{
|
|
|
// Sanity check
|
|
|
CSQueueUtils.checkMaxCapacity(getQueueName(), capacity, maximumCapacity);
|
|
@@ -248,6 +246,8 @@ public class LeafQueue implements CSQueue {
|
|
|
this.queueInfo.setCapacity(this.capacity);
|
|
|
this.queueInfo.setMaximumCapacity(this.maximumCapacity);
|
|
|
this.queueInfo.setQueueState(this.state);
|
|
|
+
|
|
|
+ this.nodeLocalityDelay = nodeLocalityDelay;
|
|
|
|
|
|
StringBuilder aclsString = new StringBuilder();
|
|
|
for (Map.Entry<QueueACL, AccessControlList> e : acls.entrySet()) {
|
|
@@ -310,7 +310,8 @@ public class LeafQueue implements CSQueue {
|
|
|
"state = " + state +
|
|
|
" [= configuredState ]" + "\n" +
|
|
|
"acls = " + aclsString +
|
|
|
- " [= configuredAcls ]" + "\n");
|
|
|
+ " [= configuredAcls ]" + "\n" +
|
|
|
+ "nodeLocalityDelay = " + nodeLocalityDelay + "\n");
|
|
|
}
|
|
|
|
|
|
@Override
|
|
@@ -596,7 +597,8 @@ public class LeafQueue implements CSQueue {
|
|
|
newlyParsedLeafQueue.getMaxApplicationsPerUser(),
|
|
|
newlyParsedLeafQueue.getMaximumActiveApplications(),
|
|
|
newlyParsedLeafQueue.getMaximumActiveApplicationsPerUser(),
|
|
|
- newlyParsedLeafQueue.state, newlyParsedLeafQueue.acls);
|
|
|
+ newlyParsedLeafQueue.state, newlyParsedLeafQueue.acls,
|
|
|
+ newlyParsedLeafQueue.getNodeLocalityDelay());
|
|
|
}
|
|
|
|
|
|
@Override
|