Package org.eclipse.jetty.start
Class Main
- java.lang.Object
-
- org.eclipse.jetty.start.Main
-
public class Main extends java.lang.ObjectMain start class.This class is intended to be the main class listed in the MANIFEST.MF of the start.jar archive. It allows the Jetty Application server to be started with the command "java -jar start.jar".
Argument processing steps:
- Directory Location: jetty.home=[directory] (the jetty.home location)
- Directory Location: jetty.base=[directory] (the jetty.base location)
- Start Logging behavior: --debug (debugging enabled)
- Start Logging behavior: --start-log-file=logs/start.log (output start logs to logs/start.log location)
- Module Resolution
- Properties Resolution
- Present Optional Informational Options
- Normal Startup
-
-
Constructor Summary
Constructors Constructor Description Main()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddestroy()BaseHomegetBaseHome()voidinit(java.lang.String[] args)voidinvokeMain(java.lang.ClassLoader classloader, StartArgs args)voidlistConfig(StartArgs args)voidlistModules(StartArgs args)static voidmain(java.lang.String[] args)static booleanprintTextResource(java.lang.String resourceName)StartArgsprocessCommandLine(java.lang.String[] cmdLine)StartArgsprocessCommandLine(java.util.List<java.lang.String> cmdLine)Convenience forprocessCommandLine(cmdLine.toArray(new String[cmdLine.size()]))voidstart()voidstart(StartArgs args)voidstop()voidstop(java.lang.String host, int port, java.lang.String key)Stop a running jetty instance.voidstop(java.lang.String host, int port, java.lang.String key, int timeout)voidusage(boolean exit)
-
-
-
Method Detail
-
main
public static void main(java.lang.String[] args)
-
getBaseHome
public BaseHome getBaseHome()
-
invokeMain
public void invokeMain(java.lang.ClassLoader classloader, StartArgs args) throws java.lang.IllegalAccessException, java.lang.reflect.InvocationTargetException, java.lang.NoSuchMethodException, java.lang.ClassNotFoundException, java.io.IOException- Throws:
java.lang.IllegalAccessExceptionjava.lang.reflect.InvocationTargetExceptionjava.lang.NoSuchMethodExceptionjava.lang.ClassNotFoundExceptionjava.io.IOException
-
listConfig
public void listConfig(StartArgs args)
-
listModules
public void listModules(StartArgs args)
-
processCommandLine
public StartArgs processCommandLine(java.util.List<java.lang.String> cmdLine) throws java.lang.Exception
Convenience forprocessCommandLine(cmdLine.toArray(new String[cmdLine.size()]))- Parameters:
cmdLine- the command line- Returns:
- the start args parsed from the command line
- Throws:
java.lang.Exception- if unable to process the command line
-
processCommandLine
public StartArgs processCommandLine(java.lang.String[] cmdLine) throws java.lang.Exception
- Throws:
java.lang.Exception
-
start
public void start(StartArgs args) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOExceptionjava.lang.InterruptedException
-
stop
public void stop(java.lang.String host, int port, java.lang.String key)Stop a running jetty instance.- Parameters:
host- the hostport- the portkey- the key
-
stop
public void stop(java.lang.String host, int port, java.lang.String key, int timeout)
-
usage
public void usage(boolean exit)
-
printTextResource
public static boolean printTextResource(java.lang.String resourceName)
-
init
public void init(java.lang.String[] args) throws java.lang.Exception- Throws:
java.lang.Exception
-
start
public void start() throws java.lang.Exception- Throws:
java.lang.Exception
-
stop
public void stop() throws java.lang.Exception- Throws:
java.lang.Exception
-
destroy
public void destroy()
-
-