Fixes #5679 and #5680 listing modules (#5683)

+ Updated usage to show that --list-config lists the enabled Modules
+ fixed unsupported operation in --list-all-modules
+ list enabled modules with default --list-module
This commit is contained in:
Greg Wilkins 2020-11-17 23:03:57 +01:00 committed by GitHub
parent e9c6c942ea
commit 41a7d8bcb5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 4 deletions

View File

@ -266,6 +266,10 @@ public class Main
System.out.printf("%nModules %s:%n", t);
System.out.printf("=========%s%n", "=".repeat(t.length()));
args.getAllModules().listModules(tags);
// for default module listings, also show enabled modules
if ("[-internal]".equals(t) || "[*]".equals(t))
args.getAllModules().listEnabled();
}
public void showModules(StartArgs args)

View File

@ -167,6 +167,8 @@ public class Modules implements Iterable<Module>
if (tags.contains("-*"))
return;
tags = new ArrayList<>(tags);
boolean wild = tags.contains("*");
Set<String> included = new HashSet<>();
if (wild)

View File

@ -347,8 +347,6 @@ public class StartArgs
}
System.out.println();
}
System.out.println();
}
public void dumpJvmArgs()

View File

@ -19,12 +19,15 @@ Command Line Options:
--list-config List the resolved configuration that will be used to
start Jetty.
Output includes:
o Enabled jetty modules
o Java Environment
o Jetty Environment
o Config file search order
o JVM Arguments
o System Properties
o Properties
o Server Classpath
o Server XML Configuration
o Java Classpath
o XML Configuration files
--dry-run Print the command line that the start.jar generates,
then exit. This may be used to generate command lines