public class WebServer extends GenericWebServer
In particular, Jetty will be started using keystore info from p2j config that is already in memory.
Modifier and Type | Class and Description |
---|---|
static class |
WebServer.WebContext
Holds the web content resource description.
|
Modifier and Type | Field and Description |
---|---|
static int |
HTTPS_PORT
HTTPS default port for listening.
|
private static WebServer |
instance
Singleton instance of this class.
|
private static java.util.logging.Logger |
LOG
Anonymous log instance.
|
private int |
port
Server port in use.
|
MAX_HTTP_IDLE_TIMEOUT, OUTPUT_AGGREGATION_SIZE, OUTPUT_BUFFER_SIZE, REQUEST_HEADER_SIZE, RESPONSE_HEADER_SIZE
Modifier | Constructor and Description |
---|---|
private |
WebServer(org.eclipse.jetty.server.Handler[] handlers)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
getURL()
Get the URL on which this server is running.
|
static org.eclipse.jetty.server.handler.ContextHandler[] |
getWebContentHandlers()
Builds the list of web handlers for managing static web content given by the web-static-content
directory settings.
|
static void |
initialize(org.eclipse.jetty.server.Handler[] handlers)
Called by StandardServer.loadStartup() to start the Web Server.
|
static void |
terminate()
Shutdown web server instance if any.
|
addHandler, addHandler, addWebSocketHandler, addWebSocketHandler, getContextPath, getHost, getHttpConfiguration, getPort, getServer, getSslContextFactory, getWarFile, getWebAppConnectors, initializeWebApp, isRunning, join, removeHandler, setBootstrapConfig, setContextPath, setKeyStore, shutdown, startup, startup, startup
public static final int HTTPS_PORT
private static final java.util.logging.Logger LOG
private static WebServer instance
private int port
private WebServer(org.eclipse.jetty.server.Handler[] handlers) throws java.lang.Exception
handlers
- List of handlers to register.java.lang.Exception
- If something goes wrong.public static java.lang.String getURL()
public static org.eclipse.jetty.server.handler.ContextHandler[] getWebContentHandlers() throws java.lang.Throwable
java.lang.Throwable
- Iff errors occur while reading web-static-content settings from the directorypublic static void initialize(org.eclipse.jetty.server.Handler[] handlers)
handlers
- List of handlers to register.public static void terminate()