public List<ResourceRequest> createReq(String[] hosts, int memory, int priority, int containers, long allocationRequestId) throws Exception { return createReq(hosts, memory, priority, containers, null, allocationRequestId); }
public List<ResourceRequest> createReq(String[] hosts, int memory, int priority, int containers) throws Exception { return createReq(hosts, memory, priority, containers, null); }
public void addRequests(String[] hosts, int memory, int priority, int containers, long allocationRequestId) throws Exception { requests.addAll( createReq(hosts, memory, priority, containers, allocationRequestId)); }
public void addRequests(String[] hosts, int memory, int priority, int containers) throws Exception { requests.addAll(createReq(hosts, memory, priority, containers)); }
public AllocateResponse allocate( String host, int memory, int numContainers, List<ContainerId> releases, String labelExpression) throws Exception { List<ResourceRequest> reqs = createReq(new String[] { host }, memory, 1, numContainers, labelExpression); return allocate(reqs, releases); }
public AllocateResponse allocate( String host, int memory, int numContainers, int priority, List<ContainerId> releases, String labelExpression) throws Exception { List<ResourceRequest> reqs = createReq(new String[] { host }, memory, priority, numContainers, labelExpression, -1); return allocate(reqs, releases); }
am1.allocate(am1.createReq( new String[] {host0, host1}, 1 * GB, 1, numContainers, 5L), null); am2.allocate(am1.createReq( new String[] {host0, host1}, 2 * GB, 1, numContainers, 5L), null); am2.allocate(am1.createReq( new String[] {host0, host1}, 3 * GB, 1, numContainers, 10L), null); am1.allocate(am1.createReq( new String[] {host0, host1}, 4 * GB, 1, numContainers, 10L), null);