public static void main(String[] args) throws IOException, InterruptedException { try { _main(args); } catch (CmdLineException e) { System.err.println(e.getMessage()); System.err.println("java -jar slave.jar [options...] <secret key> <slave name>"); new CmdLineParser(new Main()).printUsage(System.err); } }
/** * Main without the argument handling. */ public static void _main(String[] args) throws IOException, InterruptedException, CmdLineException { // see http://forum.java.sun.com/thread.jspa?threadID=706976&tstart=0 // not sure if this is the cause, but attempting to fix // http://issues.hudson-ci.org/browse/HUDSON-310 // by overwriting the security manager. try { System.setSecurityManager(null); } catch (SecurityException e) { // ignore and move on. // some user reported that this happens on their JVM: http://d.hatena.ne.jp/tueda_wolf/20080723 } Main m = new Main(); CmdLineParser p = new CmdLineParser(m); p.parseArgument(args); if(m.args.size()!=2) throw new CmdLineException("two arguments required, but got "+m.args); if(m.urls.isEmpty()) throw new CmdLineException("At least one -url option is required."); m.main(); }
List<String> jnlpArgs = parseJnlpArguments(); try { hudson.remoting.jnlp.Main._main(jnlpArgs.toArray(new String[jnlpArgs.size()])); } catch (CmdLineException e) { System.err.println("JNLP file "+slaveJnlpURL+" has invalid arguments: "+jnlpArgs);
Main.main(args.toArray(new String[0])); } catch (Exception e) { e.printStackTrace();
public void main() throws IOException, InterruptedException { Engine engine = createEngine(); engine.startEngine(); try { engine.join(); LOGGER.fine("Engine has died"); } finally { // if we are programmatically driven by other code, // allow them to interrupt our blocking main thread // to kill the on-going connection to Jenkins engine.interrupt(); } }
/** * Main without the argument handling. */ public static void _main(String[] args) throws IOException, InterruptedException, CmdLineException { // see http://forum.java.sun.com/thread.jspa?threadID=706976&tstart=0 // not sure if this is the cause, but attempting to fix // http://issues.hudson-ci.org/browse/HUDSON-310 // by overwriting the security manager. try { System.setSecurityManager(null); } catch (SecurityException e) { // ignore and move on. // some user reported that this happens on their JVM: http://d.hatena.ne.jp/tueda_wolf/20080723 } Main m = new Main(); CmdLineParser p = new CmdLineParser(m); p.parseArgument(args); if(m.args.size()!=2) throw new CmdLineException("two arguments required, but got "+m.args); if(m.urls.isEmpty()) throw new CmdLineException("At least one -url option is required."); m.main(); }
List<String> jnlpArgs = parseJnlpArguments(); try { hudson.remoting.jnlp.Main._main(jnlpArgs.toArray(new String[jnlpArgs.size()])); } catch (CmdLineException e) { System.err.println("JNLP file "+slaveJnlpURL+" has invalid arguments: "+jnlpArgs);
/** * Main without the argument handling. */ public static void _main(String[] args) throws IOException, InterruptedException, CmdLineException { // see http://forum.java.sun.com/thread.jspa?threadID=706976&tstart=0 // not sure if this is the cause, but attempting to fix // http://issues.hudson-ci.org/browse/HUDSON-310 // by overwriting the security manager. try { System.setSecurityManager(null); } catch (SecurityException e) { // ignore and move on. // some user reported that this happens on their JVM: http://d.hatena.ne.jp/tueda_wolf/20080723 } Main m = new Main(); CmdLineParser p = new CmdLineParser(m); p.parseArgument(args); if(m.args.size()!=2) throw new CmdLineException("two arguments required, but got "+m.args); if(m.urls.isEmpty()) throw new CmdLineException("At least one -url option is required."); m.main(); }
public static void main(String[] args) throws IOException, InterruptedException { try { _main(args); } catch (CmdLineException e) { System.err.println(e.getMessage()); System.err.println("java -jar slave.jar [options...] <secret key> <slave name>"); new CmdLineParser(new Main()).printUsage(System.err); } }
List<String> jnlpArgs = parseJnlpArguments(); try { hudson.remoting.jnlp.Main._main(jnlpArgs.toArray(new String[jnlpArgs.size()])); } catch (CmdLineException e) { System.err.println("JNLP file "+slaveJnlpURL+" has invalid arguments: "+jnlpArgs);
/** * Main without the argument handling. */ public static void _main(String[] args) throws IOException, InterruptedException, CmdLineException { // see http://forum.java.sun.com/thread.jspa?threadID=706976&tstart=0 // not sure if this is the cause, but attempting to fix // https://hudson.dev.java.net/issues/show_bug.cgi?id=310 // by overwriting the security manager. try { System.setSecurityManager(null); } catch (SecurityException e) { // ignore and move on. // some user reported that this happens on their JVM: http://d.hatena.ne.jp/tueda_wolf/20080723 } // if we run in Mac, put the menu bar where the user expects it System.setProperty("apple.laf.useScreenMenuBar", "true"); Main m = new Main(); CmdLineParser p = new CmdLineParser(m); p.parseArgument(args); if(m.args.size()!=2) throw new CmdLineException("two arguments required, but got "+m.args); if(m.urls.isEmpty()) throw new CmdLineException("At least one -url option is required."); m.main(); }
public static void main(String[] args) throws IOException, InterruptedException { try { _main(args); } catch (CmdLineException e) { System.err.println(e.getMessage()); System.err.println("java -jar agent.jar [options...] <secret key> <agent name>"); new CmdLineParser(new Main()).printUsage(System.err); } }
hudson.remoting.jnlp.Main._main(jnlpArgs.toArray(new String[jnlpArgs.size()])); } catch (CmdLineException e) { System.err.println("JNLP file "+slaveJnlpURL+" has invalid arguments: "+jnlpArgs);
public static void main(String[] args) throws IOException, InterruptedException { try { _main(args); } catch (CmdLineException e) { System.err.println(e.getMessage()); System.err.println("java -jar slave.jar [options...] <secret key> <slave name>"); new CmdLineParser(new Main()).printUsage(System.err); } }