Cleanup and documentation of StartArgs in prep for extra-start-dirs
This commit is contained in:
parent
87f2deed65
commit
e793c85eb4
|
@ -683,13 +683,13 @@ public class Main
|
||||||
}
|
}
|
||||||
|
|
||||||
// Initialize start.ini
|
// Initialize start.ini
|
||||||
for (String module : args.getModuleStartIni())
|
for (String module : args.getAddToStartIni())
|
||||||
{
|
{
|
||||||
moduleIni(args,module,true,true);
|
moduleIni(args,module,true,true);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Initialize start.d
|
// Initialize start.d
|
||||||
for (String module : args.getModuleStartdIni())
|
for (String module : args.getAddToStartdIni())
|
||||||
{
|
{
|
||||||
moduleIni(args,module,true,false);
|
moduleIni(args,module,true,false);
|
||||||
}
|
}
|
||||||
|
|
|
@ -69,23 +69,41 @@ public class StartArgs
|
||||||
private static final String SERVER_MAIN = "org.eclipse.jetty.xml.XmlConfiguration";
|
private static final String SERVER_MAIN = "org.eclipse.jetty.xml.XmlConfiguration";
|
||||||
|
|
||||||
private List<String> commandLine = new ArrayList<>();
|
private List<String> commandLine = new ArrayList<>();
|
||||||
|
/** List of enabled modules */
|
||||||
private Set<String> modules = new HashSet<>();
|
private Set<String> modules = new HashSet<>();
|
||||||
|
/** Map of enabled modules to the source of where that activation occurred */
|
||||||
private Map<String, List<String>> sources = new HashMap<>();
|
private Map<String, List<String>> sources = new HashMap<>();
|
||||||
|
/** Map of properties to where that property was declared */
|
||||||
|
private Map<String, String> propertySource = new HashMap<>();
|
||||||
|
/** List of all active [files] sections from enabled modules */
|
||||||
private List<FileArg> files = new ArrayList<>();
|
private List<FileArg> files = new ArrayList<>();
|
||||||
|
/** List of all active [lib] sectinos from enabled modules */
|
||||||
private Classpath classpath;
|
private Classpath classpath;
|
||||||
private List<String> xmlRefs = new ArrayList<>();
|
/** List of all active [xml] sections from enabled modules */
|
||||||
private List<File> xmls = new ArrayList<>();
|
private List<File> xmls = new ArrayList<>();
|
||||||
|
/** JVM arguments, found via commmand line and in all active [exec] sections from enabled modules */
|
||||||
|
private List<String> jvmArgs = new ArrayList<>();
|
||||||
|
|
||||||
|
/** List of all xml references found directly on command line or start.ini */
|
||||||
|
private List<String> xmlRefs = new ArrayList<>();
|
||||||
|
|
||||||
private Props properties = new Props();
|
private Props properties = new Props();
|
||||||
private Set<String> systemPropertyKeys = new HashSet<>();
|
private Set<String> systemPropertyKeys = new HashSet<>();
|
||||||
private List<String> jvmArgs = new ArrayList<>();
|
|
||||||
private List<String> rawLibs = new ArrayList<>();
|
private List<String> rawLibs = new ArrayList<>();
|
||||||
private List<String> moduleStartdIni = new ArrayList<>();
|
|
||||||
private List<String> moduleStartIni = new ArrayList<>();
|
// jetty.base - build out commands
|
||||||
private Map<String, String> propertySource = new HashMap<>();
|
/** --add-to-startd=[module,[module]] */
|
||||||
|
private List<String> addToStartdIni = new ArrayList<>();
|
||||||
|
/** --add-to-start=[module,[module]] */
|
||||||
|
private List<String> addToStartIni = new ArrayList<>();
|
||||||
|
|
||||||
|
// module inspection commands
|
||||||
|
/** --write-module-graph=[filename] */
|
||||||
private String moduleGraphFilename;
|
private String moduleGraphFilename;
|
||||||
|
|
||||||
|
/** Collection of all modules */
|
||||||
private Modules allModules;
|
private Modules allModules;
|
||||||
// Should the server be run?
|
/** Should the server be run? */
|
||||||
private boolean run = true;
|
private boolean run = true;
|
||||||
private boolean download = false;
|
private boolean download = false;
|
||||||
private boolean help = false;
|
private boolean help = false;
|
||||||
|
@ -357,7 +375,7 @@ public class StartArgs
|
||||||
|
|
||||||
for (String jvmArg : module.getJvmArgs())
|
for (String jvmArg : module.getJvmArgs())
|
||||||
{
|
{
|
||||||
exec=true;
|
exec = true;
|
||||||
jvmArgs.add(jvmArg);
|
jvmArgs.add(jvmArg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -475,14 +493,14 @@ public class StartArgs
|
||||||
return moduleGraphFilename;
|
return moduleGraphFilename;
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<String> getModuleStartdIni()
|
public List<String> getAddToStartdIni()
|
||||||
{
|
{
|
||||||
return moduleStartdIni;
|
return addToStartdIni;
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<String> getModuleStartIni()
|
public List<String> getAddToStartIni()
|
||||||
{
|
{
|
||||||
return moduleStartIni;
|
return addToStartIni;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Props getProperties()
|
public Props getProperties()
|
||||||
|
@ -770,7 +788,7 @@ public class StartArgs
|
||||||
{
|
{
|
||||||
throw new UsageException(ERR_BAD_ARG,"%s not allowed in %s",arg,source);
|
throw new UsageException(ERR_BAD_ARG,"%s not allowed in %s",arg,source);
|
||||||
}
|
}
|
||||||
moduleStartdIni.addAll(getValues(arg));
|
addToStartdIni.addAll(getValues(arg));
|
||||||
run = false;
|
run = false;
|
||||||
download = true;
|
download = true;
|
||||||
return;
|
return;
|
||||||
|
@ -782,7 +800,7 @@ public class StartArgs
|
||||||
{
|
{
|
||||||
throw new UsageException(ERR_BAD_ARG,"%s not allowed in %s",arg,source);
|
throw new UsageException(ERR_BAD_ARG,"%s not allowed in %s",arg,source);
|
||||||
}
|
}
|
||||||
moduleStartIni.addAll(getValues(arg));
|
addToStartIni.addAll(getValues(arg));
|
||||||
run = false;
|
run = false;
|
||||||
download = true;
|
download = true;
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue