docs: void vertexFinished() {
  		assertRunningInJobMasterMainThread();
  		final int numFinished = verticesFinished.incrementAndGet();
  		if (numFinished == numVerticesTotal) {
  			// done :-)
  
  			// check whether we are still in "RUNNING" and trigger the final cleanup
  			if (state == JobStatus.RUNNING) {
  				// we do the final cleanup in the I/O executor, because it may involve
  				// some heavier work
  
  				try {
  					for (ExecutionJobVertex ejv : verticesInCreationOrder) {
  						ejv.getJobVertex().finalizeOnMaster(getUserClassLoader());
  					}
  				}
  				catch (Throwable t) {
  					ExceptionUtils.rethrowIfFatalError(t);
  					failGlobal(new Exception("Failed to finalize execution on master", t));
  					return;
  				}
  
  				// if we do not make this state transition, then a concurrent
  				// cancellation or failure happened
  				if (transitionState(JobStatus.RUNNING, JobStatus.FINISHED)) {
  					onTerminalState(JobStatus.FINISHED);
  				}
  			}
  		}
  	}