\n");
pageContent.append("
\n");
pageContent.append("
MailArchiver
\n");
pageContent.append("
Serviços de arquivamento local de mensagens
\n");
pageContent.append("
Acesse o console de administração
\n");
pageContent.append("
\n");
pageContent.append("
Serviço Federal de Processamento de Dados - SERPRO
\n");
pageContent.append("
\n");
pageContent.append("
\n");
pageContent.append("
\n");
pageContent.append("\n");
pageContent.append("\n");
writer.write(pageContent.toString());
log.debug("ErrorHandler adicionado com sucesso ao contexto jetty \"" + jettyContext + "\"");
}
catch (IOException ex){
log.error("Erro ao adicionar ErrorHandler ao contexto jetty \"" + jettyContext + "\"");
}
}
@Bean(destroyMethod = "stop")
public org.eclipse.jetty.server.Server jetty() throws UnknownHostException, URISyntaxException, IOException {
log.debug("Instanciando bean jetty");
org.eclipse.jetty.server.Server jetty = new org.eclipse.jetty.server.Server();
//thread pool
QueuedThreadPool threadPool = new QueuedThreadPool();
threadPool.setMinThreads(10);
threadPool.setMaxThreads(200);
//threadPool.setDetailedDump(true);
log.debug("threadPool configurado");
//connector
SelectChannelConnector connector = new SelectChannelConnector();
connector.setPort(userAppConfig().SERVER.getPort());
connector.setAcceptors(2 * Runtime.getRuntime().availableProcessors());
connector.setStatsOn(false);
connector.setLowResourcesConnections(20000);
log.debug("connector configurado");
//ssl connector
//String keyStorePath = new ClassPathResource("/serpro/mailarchiver/config").getURI().toString() + "/keystore";
String keyStorePath = new ClassPathResource("/serpro/mailarchiver/config").getURI().toString() + "/mailarchiver";
SslContextFactory sslContextFactory = new SslContextFactory(keyStorePath);
sslContextFactory.setTrustStore(keyStorePath);
sslContextFactory.setTrustStorePassword(TRUST_STORE_PASSWORD);
sslContextFactory.setKeyStorePassword(KEY_STORE_PASSWORD);
sslContextFactory.setKeyManagerPassword(KEY_MANAGER_PASSWORD);
SslSelectChannelConnector sslConnector = new SslSelectChannelConnector(sslContextFactory);
sslConnector.setPort(userAppConfig().SERVER.getConfidentialPort());
sslConnector.setAcceptors(2 * Runtime.getRuntime().availableProcessors());
sslConnector.setStatsOn(false);
sslConnector.setLowResourcesConnections(20000);
log.debug("ssl connector configurado com URL keystore = " + keyStorePath);
//virtual hosts
Set