/// <summary> /// Create a direct connection to RM instead of a remote connection when /// the proxy is running as part of the RM. /// </summary> /// <remarks> /// 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. /// </remarks> /// <param name="conf">the configuration to use</param> /// <param name="applicationsManager">what to use to get the RM reports.</param> public AppReportFetcher(Configuration conf, ApplicationClientProtocol applicationsManager ) { if (conf.GetBoolean(YarnConfiguration.ApplicationHistoryEnabled, YarnConfiguration .DefaultApplicationHistoryEnabled)) { 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; } }
/// <exception cref="System.Exception"/> protected override void ServiceStart() { try { ahsClient = AHSProxy.CreateAHSProxy <ApplicationHistoryProtocol>(GetConfig(), this .ahsAddress); } catch (IOException e) { throw new YarnRuntimeException(e); } base.ServiceStart(); }
public ApplicationHistoryProtocolPBServiceImpl(ApplicationHistoryProtocol impl) { this.real = impl; }
public virtual void CleanUp() { historyManager = null; appManager = null; fetcher = null; }