コード例 #1
0
 StartServer(Configuration configuration)
 {
     Org.Apache.Hadoop.Yarn.Server.Webproxy.WebAppProxyServer proxy = new Org.Apache.Hadoop.Yarn.Server.Webproxy.WebAppProxyServer
                                                                          ();
     ShutdownHookManager.Get().AddShutdownHook(new CompositeService.CompositeServiceShutdownHook
                                                   (proxy), ShutdownHookPriority);
     proxy.Init(configuration);
     proxy.Start();
     return(proxy);
 }
コード例 #2
0
 public static void Main(string[] args)
 {
     Sharpen.Thread.SetDefaultUncaughtExceptionHandler(new YarnUncaughtExceptionHandler
                                                           ());
     StringUtils.StartupShutdownMessage(typeof(Org.Apache.Hadoop.Yarn.Server.Webproxy.WebAppProxyServer
                                               ), args, Log);
     try
     {
         YarnConfiguration configuration = new YarnConfiguration();
         new GenericOptionsParser(configuration, args);
         Org.Apache.Hadoop.Yarn.Server.Webproxy.WebAppProxyServer proxyServer = StartServer
                                                                                    (configuration);
         proxyServer.proxy.Join();
     }
     catch (Exception t)
     {
         ExitUtil.Terminate(-1, t);
     }
 }