refined start.jar mechanism to align with updated documentation

This commit is contained in:
Greg Wilkins 2013-09-06 16:10:03 +10:00
parent c6355854ab
commit ace43502ad
20 changed files with 51 additions and 31 deletions

View File

@ -478,7 +478,8 @@
<argument>--debug</argument>
<argument>jetty.home=${assembly-directory}</argument>
<argument>jetty.base=${assembly-directory}</argument>
<argument>--module-start-ini=server,deploy,http,websocket,jsp,ext,resources</argument>
<argument>--module-start-ini=server,deploy,websocket,jsp,ext,resources</argument>
<argument>--module-ini=http</argument>
</arguments>
</configuration>
</plugin>

View File

@ -7,7 +7,7 @@ jetty-setuid-java-1.0.1.jar
[xml]
etc/jetty-setuid.xml
[ini]
[ini-template]
# jetty.startServerAsPrivileged=false
# jetty.username=jetty
# jetty.groupname=jetty

View File

@ -13,5 +13,5 @@ lib/jetty-jaas-${jetty.version}.jar
# JAAS configuration
etc/jetty-jaas.xml
[ini]
jaas.login.conf=etc/login.conf
[ini-template]
jaas.login.conf=etc/login.conf

View File

@ -10,7 +10,7 @@ lib/jetty-jmx-${jetty.version}.jar
# JMX configuration
etc/jetty-jmx.xml
[ini]
[ini-template]
# jetty.jmxrmihost=localhost
# jetty.jmxrmiport=1099
# -Dcom.sun.management.jmxremote
# -Dcom.sun.management.jmxremote

View File

@ -8,6 +8,6 @@ server
[xml]
etc/jetty-http.xml
[ini]
[ini-template]
jetty.port=8080
http.timeout=30000
http.timeout=30000

View File

@ -8,6 +8,6 @@ ssl
[xml]
etc/jetty-https.xml
[ini]
[ini-template]
https.port=8443
https.timeout=30000
https.timeout=30000

View File

@ -1,4 +1,4 @@
[ini]
[ini-template]
#===========================================================
# Configure JVM arguments.
# If JVM args are include in an ini file then --exec is needed
@ -21,4 +21,4 @@
# -XX:+PrintTenuringDistribution
# -XX:+PrintCommandLineFlags
# -XX:+DisableExplicitGC
# -Dorg.apache.jasper.compiler.disablejsr199=true
# -Dorg.apache.jasper.compiler.disablejsr199=true

View File

@ -8,10 +8,10 @@ server
[xml]
etc/jetty-lowresources.xml
[ini]
[ini-template]
# lowresources.period=1050
# lowresources.lowResourcesIdleTimeout=200
# lowresources.monitorThreads=true
# lowresources.maxConnections=0
# lowresources.maxMemory=0
# lowresources.maxLowResourcesTime=5000
# lowresources.maxLowResourcesTime=5000

View File

@ -11,7 +11,7 @@ etc/jetty-requestlog.xml
[files]
logs/
[ini]
[ini-template]
# requestlog.retain=90
# requestlog.append=true
# requestlog.extended=true

View File

@ -22,7 +22,7 @@ lib/jetty-io-${jetty.version}.jar
# Annotations needs annotations configuration
etc/jetty.xml
[ini]
[ini-template]
threads.min=10
threads.max=200
threads.timeout=60000

View File

@ -10,10 +10,17 @@ etc/jetty-ssl.xml
[files]
http://git.eclipse.org/c/jetty/org.eclipse.jetty.project.git/plain/jetty-server/src/main/config/etc/keystore:etc/keystore
[ini]
[ini-template]
# define the port to use for secure redirection
jetty.secure.port=8443
# Setup a demonstration keystore and truststore
jetty.keystore=etc/keystore
jetty.truststore=etc/keystore
# Set the demonstration passwords.
# Note that OBF passwords are not secure, just protected from casual observation
jetty.keystore.password=OBF:1vny1zlo1x8e1vnw1vn61x8g1zlu1vn4
jetty.keymanager.password=OBF:1u2u1wml1z7s1z7a1wnl1u2g
jetty.truststore=etc/keystore
jetty.truststore.password=OBF:1vny1zlo1x8e1vnw1vn61x8g1zlu1vn4
jetty.secure.port=8443

View File

@ -2,6 +2,6 @@
[files]
http://repo1.maven.org/maven2/org/mortbay/jetty/npn/npn-boot/1.1.5.v20130313/npn-boot-1.1.5.v20130313.jar:lib/npn/npn-boot-1.1.5.v20130313.jar
[ini]
[ini-template]
-Xbootclasspath/p:lib/npn/npn-boot-1.1.5.v20130313.jar
--exec

View File

@ -9,7 +9,7 @@ lib/spdy/*.jar
etc/jetty-ssl.xml
etc/jetty-spdy.xml
[ini]
[ini-template]
spdy.port=8443
spdy.timeout=30000
#spdy.initialWindowSize=65536
#spdy.initialWindowSize=65536

View File

@ -177,7 +177,7 @@ public class Main
{
File file = baseHome.getBaseFile(arg.location);
StartLog.debug("Download to %s %s",file.getAbsolutePath(),(file.exists()?"[Exists!]":""));
StartLog.debug("Module file %s %s",file.getAbsolutePath(),(file.exists()?"[Exists!]":""));
if (file.exists())
{
return;

View File

@ -274,7 +274,7 @@ public class Module
// blank lines and comments are valid for initialize section
if (line.length() == 0 || line.startsWith("#"))
{
if ("INI".equals(sectionType))
if ("INI-TEMPLATE".equals(sectionType))
{
initialise.add(line);
}
@ -298,7 +298,7 @@ public class Module
case "FILES":
files.add(line);
break;
case "INI":
case "INI-TEMPLATE":
initialise.add(line);
break;
}

View File

@ -78,6 +78,7 @@ public class StartArgs
private List<String> jvmArgs = new ArrayList<>();
private List<String> moduleIni = new ArrayList<>();
private List<String> moduleStartIni = new ArrayList<>();
private Map<String,String> propertySource = new HashMap<>();
private String moduleGraphFilename;
private Modules allModules;
@ -767,6 +768,13 @@ public class StartArgs
{
String key = arg.substring(0,idx);
String value = arg.substring(idx + 1);
if (source!=CMD_LINE_SOURCE)
{
if (propertySource.containsKey(key))
throw new UsageException(ERR_BAD_ARG,"Property %s in %s already set in %s",key,source,propertySource.get(key));
propertySource.put(key,source);
}
properties.setProperty(key,value);
return;
}

View File

@ -2,5 +2,5 @@
[files]
http://repo1.maven.org/maven2/org/mortbay/jetty/npn/npn-boot/1.1.5.v20130313/npn-boot-1.1.5.v20130313.jar:lib/npn/npn-boot-1.1.5.v20130313.jar
[ini]
[ini-template]
-Xbootclasspath/p:lib/npn/npn-boot-1.1.5.v20130313.jar

View File

@ -6,6 +6,6 @@
etc/jetty-logging.xml
[ini]
[ini-template]
# Number of days to retain logs
# jetty.log.retain=90

View File

@ -0,0 +1,6 @@
#
# HTTP connector
#
--module=http
jetty.port=8080

View File

@ -1,11 +1,9 @@
#
# Example of providing a demo configuration, using a ${jetty.base}
#
# Additional ini files are in demo-base/start.d
#
# We want to serve content over http
--module=http
jetty.port=8080
# Have webapps be deployed normally from webapps directory
--module=deploy