connector.setHost(endpoint.getHttpUri().getHost());
if ("localhost".equalsIgnoreCase(endpoint.getHttpUri().getHost())) {
LOG.warn("You use localhost interface! It means that no external connections will be available."
+ " Don't you want to use 0.0.0.0 instead (all network interfaces)? " + endpoint);
}
Server server = createServer();
if (endpoint.isEnableJmx()) {
enableJmx(server);
}
// This setting is only work for the first endpoint which create the server
// just set if we need sendServerVersion, the default value is true
server.setSendServerVersion(endpoint.isSendServerVersion());
server.addConnector(connector);
server.setSendDateHeader(endpoint.isSendDateHeader());
connectorRef = new ConnectorRef(server, connector, createServletForConnector(server, connector, endpoint.getHandlers(), endpoint));
// must enable session before we start
if (endpoint.isSessionSupport()) {
enableSessionSupport(connectorRef.server, connectorKey);