private FetchedAppReport getApplicationReport(ApplicationId id) throws IOException, YarnException { return ((AppReportFetcher) getServletContext() .getAttribute(WebAppProxy.FETCHER_ATTRIBUTE)).getApplicationReport(id); }
/** * Create a direct connection to RM instead of a remote connection when * the proxy is running as part of the RM. Also create a remote connection to * Application History Server if it is enabled. * @param conf the configuration to use * @param applicationsManager what to use to get the RM reports. */ public AppReportFetcher(Configuration conf, ApplicationClientProtocol applicationsManager) { if (conf.getBoolean(YarnConfiguration.APPLICATION_HISTORY_ENABLED, YarnConfiguration.DEFAULT_APPLICATION_HISTORY_ENABLED)) { isAHSEnabled = true; } this.conf = conf; this.applicationsManager = applicationsManager; if (isAHSEnabled) { try { historyManager = getAHSProxy(conf); } catch (IOException e) { throw new YarnRuntimeException(e); } } else { this.historyManager = null; } }
@Override protected void serviceStop() throws Exception { if(proxyServer != null) { try { proxyServer.stop(); } catch (Exception e) { LOG.error("Error stopping proxy web server", e); throw new YarnRuntimeException("Error stopping proxy web server",e); } } if(this.fetcher != null) { this.fetcher.stop(); } super.serviceStop(); }
proxyHost = proxyParts[0]; fetcher = new AppReportFetcher(conf); bindAddress = conf.get(YarnConfiguration.PROXY_ADDRESS); if(bindAddress == null || bindAddress.isEmpty()) {
@Override protected void serviceStop() throws Exception { if(proxyServer != null) { try { proxyServer.stop(); } catch (Exception e) { LOG.error("Error stopping proxy web server", e); throw new YarnRuntimeException("Error stopping proxy web server",e); } } if(this.fetcher != null) { this.fetcher.stop(); } super.serviceStop(); }
proxyHost = proxyParts[0]; fetcher = new AppReportFetcher(conf); bindAddress = conf.get(YarnConfiguration.PROXY_ADDRESS); if(bindAddress == null || bindAddress.isEmpty()) {
@Override protected void serviceStop() throws Exception { if(proxyServer != null) { try { proxyServer.stop(); } catch (Exception e) { LOG.error("Error stopping proxy web server", e); throw new YarnRuntimeException("Error stopping proxy web server",e); } } if(this.fetcher != null) { this.fetcher.stop(); } super.serviceStop(); }
proxyHost = proxyParts[0]; fetcher = new AppReportFetcher(conf); bindAddress = conf.get(YarnConfiguration.PROXY_ADDRESS); if(bindAddress == null || bindAddress.isEmpty()) {
private FetchedAppReport getApplicationReport(ApplicationId id) throws IOException, YarnException { return ((AppReportFetcher) getServletContext() .getAttribute(WebAppProxy.FETCHER_ATTRIBUTE)).getApplicationReport(id); }
/** * Create a direct connection to RM instead of a remote connection when * the proxy is running as part of the RM. Also create a remote connection to * Application History Server if it is enabled. * @param conf the configuration to use * @param applicationsManager what to use to get the RM reports. */ public AppReportFetcher(Configuration conf, ApplicationClientProtocol applicationsManager) { if (conf.getBoolean(YarnConfiguration.APPLICATION_HISTORY_ENABLED, YarnConfiguration.DEFAULT_APPLICATION_HISTORY_ENABLED)) { isAHSEnabled = true; } this.conf = conf; this.applicationsManager = applicationsManager; if (isAHSEnabled) { try { historyManager = getAHSProxy(conf); } catch (IOException e) { throw new YarnRuntimeException(e); } } else { this.historyManager = null; } }
@Override protected void serviceStop() throws Exception { if(proxyServer != null) { try { proxyServer.stop(); } catch (Exception e) { LOG.error("Error stopping proxy web server", e); throw new YarnRuntimeException("Error stopping proxy web server",e); } } if(this.fetcher != null) { this.fetcher.stop(); } super.serviceStop(); }
proxyHost = proxyParts[0]; fetcher = new AppReportFetcher(conf); bindAddress = conf.get(YarnConfiguration.PROXY_ADDRESS); if(bindAddress == null || bindAddress.isEmpty()) {
private FetchedAppReport getApplicationReport(ApplicationId id) throws IOException, YarnException { return ((AppReportFetcher) getServletContext() .getAttribute(WebAppProxy.FETCHER_ATTRIBUTE)).getApplicationReport(id); }
/** * Create a direct connection to RM instead of a remote connection when * the proxy is running as part of the RM. Also create a remote connection to * Application History Server if it is enabled. * @param conf the configuration to use * @param applicationsManager what to use to get the RM reports. */ public AppReportFetcher(Configuration conf, ApplicationClientProtocol applicationsManager) { if (conf.getBoolean(YarnConfiguration.APPLICATION_HISTORY_ENABLED, YarnConfiguration.DEFAULT_APPLICATION_HISTORY_ENABLED)) { isAHSEnabled = true; } this.conf = conf; this.applicationsManager = applicationsManager; if (isAHSEnabled) { try { historyManager = getAHSProxy(conf); } catch (IOException e) { throw new YarnRuntimeException(e); } } else { this.historyManager = null; } }
@Override protected void serviceStop() throws Exception { if (webApp != null) { webApp.stop(); } if (fetcher != null) { fetcher.stop(); } if (configurationProvider != null) { configurationProvider.close(); } super.serviceStop(); transitionToStandby(false); rmContext.setHAServiceState(HAServiceState.STOPPING); }
equals(proxyHostAndPort)) { if (HAUtil.isHAEnabled(conf)) { fetcher = new AppReportFetcher(conf); } else { fetcher = new AppReportFetcher(conf, getClientRMService());
private FetchedAppReport getApplicationReport(ApplicationId id) throws IOException, YarnException { return ((AppReportFetcher) getServletContext() .getAttribute(WebAppProxy.FETCHER_ATTRIBUTE)).getApplicationReport(id); }
/** * Create a direct connection to RM instead of a remote connection when * the proxy is running as part of the RM. Also create a remote connection to * Application History Server if it is enabled. * @param conf the configuration to use * @param applicationsManager what to use to get the RM reports. */ public AppReportFetcher(Configuration conf, ApplicationClientProtocol applicationsManager) { if (conf.getBoolean(YarnConfiguration.APPLICATION_HISTORY_ENABLED, YarnConfiguration.DEFAULT_APPLICATION_HISTORY_ENABLED)) { isAHSEnabled = true; } this.conf = conf; this.applicationsManager = applicationsManager; if (isAHSEnabled) { try { historyManager = getAHSProxy(conf); } catch (IOException e) { throw new YarnRuntimeException(e); } } else { this.historyManager = null; } }
@Override protected void serviceStop() throws Exception { if (webApp != null) { webApp.stop(); } if (fetcher != null) { fetcher.stop(); } if (configurationProvider != null) { configurationProvider.close(); } super.serviceStop(); transitionToStandby(false); rmContext.setHAServiceState(HAServiceState.STOPPING); }
equals(proxyHostAndPort)) { if (HAUtil.isHAEnabled(conf)) { fetcher = new AppReportFetcher(conf); } else { fetcher = new AppReportFetcher(conf, getClientRMService());