YARN-1723. AMRMClientAsync missing blacklist addition and removal
functionality. Contributed by Bartosz Ługowski.
(cherry picked from commit e04e8fa810
)
This commit is contained in:
parent
76c0757c6e
commit
c330bca833
|
@ -205,6 +205,9 @@ Release 2.7.0 - UNRELEASED
|
||||||
|
|
||||||
YARN-1393. SLS: Add how-to-use instructions. (Wei Yan via kasha)
|
YARN-1393. SLS: Add how-to-use instructions. (Wei Yan via kasha)
|
||||||
|
|
||||||
|
YARN-1723. AMRMClientAsync missing blacklist addition and removal
|
||||||
|
functionality. (Bartosz Ługowski via sseth)
|
||||||
|
|
||||||
OPTIMIZATIONS
|
OPTIMIZATIONS
|
||||||
|
|
||||||
BUG FIXES
|
BUG FIXES
|
||||||
|
|
|
@ -194,6 +194,17 @@ extends AbstractService {
|
||||||
*/
|
*/
|
||||||
public abstract int getClusterNodeCount();
|
public abstract int getClusterNodeCount();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update application's blacklist with addition or removal resources.
|
||||||
|
*
|
||||||
|
* @param blacklistAdditions list of resources which should be added to the
|
||||||
|
* application blacklist
|
||||||
|
* @param blacklistRemovals list of resources which should be removed from the
|
||||||
|
* application blacklist
|
||||||
|
*/
|
||||||
|
public abstract void updateBlacklist(List<String> blacklistAdditions,
|
||||||
|
List<String> blacklistRemovals);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Wait for <code>check</code> to return true for each 1000 ms.
|
* Wait for <code>check</code> to return true for each 1000 ms.
|
||||||
* See also {@link #waitFor(com.google.common.base.Supplier, int)}
|
* See also {@link #waitFor(com.google.common.base.Supplier, int)}
|
||||||
|
|
|
@ -206,6 +206,19 @@ extends AMRMClientAsync<T> {
|
||||||
return client.getClusterNodeCount();
|
return client.getClusterNodeCount();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update application's blacklist with addition or removal resources.
|
||||||
|
*
|
||||||
|
* @param blacklistAdditions list of resources which should be added to the
|
||||||
|
* application blacklist
|
||||||
|
* @param blacklistRemovals list of resources which should be removed from the
|
||||||
|
* application blacklist
|
||||||
|
*/
|
||||||
|
public void updateBlacklist(List<String> blacklistAdditions,
|
||||||
|
List<String> blacklistRemovals) {
|
||||||
|
client.updateBlacklist(blacklistAdditions, blacklistRemovals);
|
||||||
|
}
|
||||||
|
|
||||||
private class HeartbeatThread extends Thread {
|
private class HeartbeatThread extends Thread {
|
||||||
public HeartbeatThread() {
|
public HeartbeatThread() {
|
||||||
super("AMRM Heartbeater thread");
|
super("AMRM Heartbeater thread");
|
||||||
|
|
Loading…
Reference in New Issue