ssl_b_connector.setTrustPassword("OBF:1vny1zlo1x8e1vnw1vn61x8g1zlu1vn4");
server.addConnector(ssl_b_connector);
HandlerCollection handlers = new HandlerCollection();
ContextHandlerCollection contexts = new ContextHandlerCollection();
RequestLogHandler requestLogHandler = new RequestLogHandler();
handlers.setHandlers(new Handler[]{contexts,new DefaultHandler(),requestLogHandler});
server.setHandler(handlers);
ContextDeployer deployer0 = new ContextDeployer();
deployer0.setContexts(contexts);
deployer0.setConfigurationDir(jetty_home+"/contexts");
deployer0.setScanInterval(1);
server.addLifeCycle(deployer0);
WebAppDeployer deployer1 = new WebAppDeployer();
deployer1.setContexts(contexts);
deployer1.setWebAppDir(jetty_home+"/webapps");
deployer1.setParentLoaderPriority(false);
deployer1.setExtract(true);
deployer1.setAllowDuplicates(false);
deployer1.setDefaultsDescriptor(jetty_home+"/etc/webdefault.xml");
server.addLifeCycle(deployer1);
HashUserRealm userRealm = new HashUserRealm();
userRealm.setName("Test Realm");
userRealm.setConfig(jetty_home+"/etc/realm.properties");
server.setUserRealms(new UserRealm[]{userRealm});
NCSARequestLog requestLog = new NCSARequestLog(jetty_home+"/logs/jetty-yyyy_mm_dd.log");
requestLog.setExtended(false);
requestLogHandler.setRequestLog(requestLog);
server.setStopAtShutdown(true);
server.setSendServerVersion(true);
server.start();