public synchronized void putBackKnownMapOutput(MapHost host, TaskAttemptID mapId) { host.addKnownMap(mapId); }
public synchronized void putBackKnownMapOutput(MapHost host, TaskAttemptID mapId) { host.addKnownMap(mapId); }
public synchronized void putBackKnownMapOutput(MapHost host, TaskAttemptID mapId) { host.addKnownMap(mapId); }
public synchronized void putBackKnownMapOutput(MapHost host, TaskAttemptID mapId) { host.addKnownMap(mapId); }
public synchronized void putBackKnownMapOutput(MapHost host, TaskAttemptID mapId) { host.addKnownMap(mapId); }
public synchronized void addKnownMapOutput(String hostName, String hostUrl, TaskAttemptID mapId) { MapHost host = mapLocations.get(hostName); if (host == null) { host = new MapHost(hostName, hostUrl); mapLocations.put(hostName, host); } host.addKnownMap(mapId); // Mark the host as pending if (host.getState() == State.PENDING) { pendingHosts.add(host); notifyAll(); } }
public synchronized void addKnownMapOutput(String hostName, String hostUrl, TaskAttemptID mapId) { MapHost host = mapLocations.get(hostName); if (host == null) { host = new MapHost(hostName, hostUrl); mapLocations.put(hostName, host); } host.addKnownMap(mapId); // Mark the host as pending if (host.getState() == State.PENDING) { pendingHosts.add(host); notifyAll(); } }
public synchronized void addKnownMapOutput(String hostName, String hostUrl, TaskAttemptID mapId) { MapHost host = mapLocations.get(hostName); if (host == null) { host = new MapHost(hostName, hostUrl); mapLocations.put(hostName, host); } host.addKnownMap(mapId); // Mark the host as pending if (host.getState() == State.PENDING) { pendingHosts.add(host); notifyAll(); } }
public synchronized void addKnownMapOutput(String hostName, String hostUrl, TaskAttemptID mapId) { MapHost host = mapLocations.get(hostName); if (host == null) { host = new MapHost(hostName, hostUrl); mapLocations.put(hostName, host); } host.addKnownMap(mapId); // Mark the host as pending if (host.getState() == State.PENDING) { pendingHosts.add(host); notifyAll(); } }
public synchronized void addKnownMapOutput(String hostName, String hostUrl, TaskAttemptID mapId) { MapHost host = mapLocations.get(hostName); if (host == null) { host = new MapHost(hostName, hostUrl); mapLocations.put(hostName, host); } host.addKnownMap(mapId); // Mark the host as pending if (host.getState() == State.PENDING) { pendingHosts.add(host); notifyAll(); } }
public synchronized List<TaskAttemptID> getMapsForHost(MapHost host) { List<TaskAttemptID> list = host.getAndClearKnownMaps(); Iterator<TaskAttemptID> itr = list.iterator(); List<TaskAttemptID> result = new ArrayList<TaskAttemptID>(); int includedMaps = 0; int totalSize = list.size(); // find the maps that we still need, up to the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { result.add(id); if (++includedMaps >= MAX_MAPS_AT_ONCE) { break; } } } // put back the maps left after the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { host.addKnownMap(id); } } LOG.info("assigned " + includedMaps + " of " + totalSize + " to " + host + " to " + Thread.currentThread().getName()); return result; }
public synchronized List<TaskAttemptID> getMapsForHost(MapHost host) { List<TaskAttemptID> list = host.getAndClearKnownMaps(); Iterator<TaskAttemptID> itr = list.iterator(); List<TaskAttemptID> result = new ArrayList<TaskAttemptID>(); int includedMaps = 0; int totalSize = list.size(); // find the maps that we still need, up to the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { result.add(id); if (++includedMaps >= MAX_MAPS_AT_ONCE) { break; } } } // put back the maps left after the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { host.addKnownMap(id); } } LOG.info("assigned " + includedMaps + " of " + totalSize + " to " + host + " to " + Thread.currentThread().getName()); return result; }
public synchronized List<TaskAttemptID> getMapsForHost(MapHost host) { List<TaskAttemptID> list = host.getAndClearKnownMaps(); Iterator<TaskAttemptID> itr = list.iterator(); List<TaskAttemptID> result = new ArrayList<TaskAttemptID>(); int includedMaps = 0; int totalSize = list.size(); // find the maps that we still need, up to the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { result.add(id); if (++includedMaps >= MAX_MAPS_AT_ONCE) { break; } } } // put back the maps left after the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { host.addKnownMap(id); } } LOG.debug("assigned " + includedMaps + " of " + totalSize + " to " + host + " to " + Thread.currentThread().getName()); return result; }
public synchronized List<TaskAttemptID> getMapsForHost(MapHost host) { List<TaskAttemptID> list = host.getAndClearKnownMaps(); Iterator<TaskAttemptID> itr = list.iterator(); List<TaskAttemptID> result = new ArrayList<TaskAttemptID>(); int includedMaps = 0; int totalSize = list.size(); // find the maps that we still need, up to the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { result.add(id); if (++includedMaps >= MAX_MAPS_AT_ONCE) { break; } } } // put back the maps left after the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { host.addKnownMap(id); } } LOG.info("assigned " + includedMaps + " of " + totalSize + " to " + host + " to " + Thread.currentThread().getName()); return result; }
public synchronized List<TaskAttemptID> getMapsForHost(MapHost host) { List<TaskAttemptID> list = host.getAndClearKnownMaps(); Iterator<TaskAttemptID> itr = list.iterator(); List<TaskAttemptID> result = new ArrayList<TaskAttemptID>(); int includedMaps = 0; int totalSize = list.size(); // find the maps that we still need, up to the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { result.add(id); if (++includedMaps >= MAX_MAPS_AT_ONCE) { break; } } } // put back the maps left after the limit while (itr.hasNext()) { TaskAttemptID id = itr.next(); if (!obsoleteMaps.contains(id) && !finishedMaps[id.getTaskID().getId()]) { host.addKnownMap(id); } } LOG.info("assigned " + includedMaps + " of " + totalSize + " to " + host + " to " + Thread.currentThread().getName()); return result; }