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 void run() { try { while (true) { // take the first host that has an expired penalty MapHost host = penalties.take().host; synchronized (ShuffleSchedulerImpl.this) { if (host.markAvailable() == MapHost.State.PENDING) { pendingHosts.add(host); ShuffleSchedulerImpl.this.notifyAll(); } } } } catch (InterruptedException ie) { return; } catch (Throwable t) { reporter.reportException(t); } }
public void run() { try { while (true) { // take the first host that has an expired penalty MapHost host = penalties.take().host; synchronized (ShuffleScheduler.this) { if (host.markAvailable() == MapHost.State.PENDING) { pendingHosts.add(host); ShuffleScheduler.this.notifyAll(); } } } } catch (InterruptedException ie) { return; } catch (Throwable t) { reporter.reportException(t); } }
public synchronized void freeHost(MapHost host) { if (host.getState() != State.PENALIZED) { if (host.markAvailable() == State.PENDING) { pendingHosts.add(host); notifyAll(); } } LOG.info(host + " freed by " + Thread.currentThread().getName() + " in " + (Time.monotonicNow()-shuffleStart.get()) + "ms"); }
public synchronized void freeHost(MapHost host) { if (host.getState() != State.PENALIZED) { if (host.markAvailable() == State.PENDING) { pendingHosts.add(host); notifyAll(); } } LOG.info(host + " freed by " + Thread.currentThread().getName() + " in " + (Time.monotonicNow()-SHUFFLE_START.get()) + "ms"); }
public synchronized void freeHost(MapHost host) { if (host.getState() != State.PENALIZED) { if (host.markAvailable() == State.PENDING) { pendingHosts.add(host); notifyAll(); } } LOG.info(host + " freed by " + Thread.currentThread().getName() + " in " + (System.currentTimeMillis()-shuffleStart.get()) + "ms"); }
public synchronized void freeHost(MapHost host) { if (host.getState() != State.PENALIZED) { if (host.markAvailable() == State.PENDING) { pendingHosts.add(host); notifyAll(); } } LOG.info(host + " freed by " + Thread.currentThread().getName() + " in " + (System.currentTimeMillis()-shuffleStart.get()) + "s"); }