public void display(boolean verbose, boolean isNew) { YarnApplicationState state = report.getYarnApplicationState(); if (verbose || !isNew) { System.out.println("Application State: " + state.toString()); System.out.println("Host: " + report.getHost()); } if (verbose || !isNew) { System.out.println("Queue: " + report.getQueue()); System.out.println("User: " + report.getUser()); long startTime = report.getStartTime(); System.out.println("Start Time: " + DoYUtil.toIsoTime(startTime)); System.out.println("Application Name: " + report.getName()); } System.out.println("Tracking URL: " + report.getTrackingUrl()); if (isNew) { System.out.println("Application Master URL: " + getAmUrl()); } showFinalStatus(); }
+ ", distributedFinalState=" + report.getFinalApplicationStatus().toString() + ", appTrackingUrl=" + report.getTrackingUrl() + ", appUser=" + report.getUser());
LOGGER.info("Application Name: " + applicationReport.getName()); LOGGER.info("Application Tracking URL: " + applicationReport.getTrackingUrl()); LOGGER.info("Application User: " + applicationReport.getUser() + " Queue: " + applicationReport.getQueue());
+ ", distributedFinalState=" + report.getFinalApplicationStatus().toString() + ", appTrackingUrl=" + report.getTrackingUrl() + ", appUser=" + report.getUser());
@Override public synchronized String getUsername() { return report.getUser(); }
private String guessAppOwner(ApplicationReport appReport, ApplicationId appId) throws IOException { String appOwner = null; if (appReport != null) { //always use the app owner from the app report if possible appOwner = appReport.getUser(); } else { appOwner = UserGroupInformation.getCurrentUser().getShortUserName(); appOwner = LogCLIHelpers.getOwnerForAppIdOrNull( appId, appOwner, getConf()); } return appOwner; }
public static JobStatus[] fromYarnApps(List<ApplicationReport> applications, Configuration conf) { List<JobStatus> jobStatuses = new ArrayList<JobStatus>(); for (ApplicationReport application : applications) { // each applicationReport has its own jobFile org.apache.hadoop.mapreduce.JobID jobId = TypeConverter.fromYarn(application.getApplicationId()); jobStatuses.add(TypeConverter.fromYarn(application, MRApps.getJobFile(conf, application.getUser(), jobId))); } return jobStatuses.toArray(new JobStatus[jobStatuses.size()]); }
public static JobStatus[] fromYarnApps(List<ApplicationReport> applications, Configuration conf) { List<JobStatus> jobStatuses = new ArrayList<JobStatus>(); for (ApplicationReport application : applications) { // each applicationReport has its own jobFile org.apache.hadoop.mapreduce.JobID jobId = TypeConverter.fromYarn(application.getApplicationId()); jobStatuses.add(TypeConverter.fromYarn(application, MRApps.getJobFile(conf, application.getUser(), jobId))); } return jobStatuses.toArray(new JobStatus[jobStatuses.size()]); }
public static JobStatus[] fromYarnApps(List<ApplicationReport> applications, Configuration conf) { List<JobStatus> jobStatuses = new ArrayList<JobStatus>(); for (ApplicationReport application : applications) { // each applicationReport has its own jobFile org.apache.hadoop.mapreduce.JobID jobId = TypeConverter.fromYarn(application.getApplicationId()); jobStatuses.add(TypeConverter.fromYarn(application, MRApps.getJobFile(conf, application.getUser(), jobId))); } return jobStatuses.toArray(new JobStatus[jobStatuses.size()]); }
public static JobStatus[] fromYarnApps(List<ApplicationReport> applications, Configuration conf) { List<JobStatus> jobStatuses = new ArrayList<JobStatus>(); for (ApplicationReport application : applications) { // each applicationReport has its own jobFile org.apache.hadoop.mapreduce.JobID jobId = TypeConverter.fromYarn(application.getApplicationId()); jobStatuses.add(TypeConverter.fromYarn(application, MRApps.getJobFile(conf, application.getUser(), jobId))); } return jobStatuses.toArray(new JobStatus[jobStatuses.size()]); }
@Override public Map<ContainerId, ContainerReport> getContainers( ApplicationAttemptId appAttemptId) throws IOException { ApplicationReport app = getApplication(appAttemptId.getApplicationId()); Map<ContainerId, ContainerHistoryData> histData = historyStore.getContainers(appAttemptId); HashMap<ContainerId, ContainerReport> containersReport = new HashMap<ContainerId, ContainerReport>(); for (Entry<ContainerId, ContainerHistoryData> entry : histData.entrySet()) { containersReport.put(entry.getKey(), convertToContainerReport(entry.getValue(), app == null ? null : app.getUser())); } return containersReport; }
@Override public Map<ContainerId, ContainerReport> getContainers( ApplicationAttemptId appAttemptId) throws IOException { ApplicationReport app = getApplication(appAttemptId.getApplicationId()); Map<ContainerId, ContainerHistoryData> histData = historyStore.getContainers(appAttemptId); HashMap<ContainerId, ContainerReport> containersReport = new HashMap<ContainerId, ContainerReport>(); for (Entry<ContainerId, ContainerHistoryData> entry : histData.entrySet()) { containersReport.put(entry.getKey(), convertToContainerReport(entry.getValue(), app == null ? null : app.getUser())); } return containersReport; }
@Override public ContainerReport getAMContainer(ApplicationAttemptId appAttemptId) throws IOException { ApplicationReport app = getApplication(appAttemptId.getApplicationId()); return convertToContainerReport(historyStore.getAMContainer(appAttemptId), app == null ? null : app.getUser()); }
@Override public ContainerReport getAMContainer(ApplicationAttemptId appAttemptId) throws IOException { ApplicationReport app = getApplication(appAttemptId.getApplicationId()); return convertToContainerReport(historyStore.getAMContainer(appAttemptId), app == null ? null : app.getUser()); }
@Override public ContainerReport getAMContainer(ApplicationAttemptId appAttemptId) throws IOException { ApplicationReport app = getApplication(appAttemptId.getApplicationId()); return convertToContainerReport(historyStore.getAMContainer(appAttemptId), app == null ? null : app.getUser()); }
@Override public ContainerReport getContainer(ContainerId containerId) throws IOException { ApplicationReport app = getApplication(containerId.getApplicationAttemptId().getApplicationId()); return convertToContainerReport(historyStore.getContainer(containerId), app == null ? null: app.getUser()); }
@Override public ContainerReport getContainer(ContainerId containerId) throws IOException { ApplicationReport app = getApplication(containerId.getApplicationAttemptId().getApplicationId()); return convertToContainerReport(historyStore.getContainer(containerId), app == null ? null: app.getUser()); }
@Override public ContainerReport getContainer(ContainerId containerId) throws IOException { ApplicationReport app = getApplication(containerId.getApplicationAttemptId().getApplicationId()); return convertToContainerReport(historyStore.getContainer(containerId), app == null ? null: app.getUser()); }
@Override public boolean exitLoop(ApplicationReport report) { LOG.info("Got application report from ASM for, appId={}, clientToken={}, appDiagnostics={}, appMasterHost={}," + "appQueue={}, appMasterRpcPort={}, appStartTime={}, yarnAppState={}, distributedFinalState={}, " + "appTrackingUrl={}, appUser={}", appId.getId(), report.getClientToAMToken(), report.getDiagnostics(), report.getHost(), report.getQueue(), report.getRpcPort(), report.getStartTime(), report.getYarnApplicationState(), report.getFinalApplicationStatus(), report.getTrackingUrl(), report.getUser()); return false; }