diff --git a/jetty-client/src/main/java/org/eclipse/jetty/client/HttpReceiver.java b/jetty-client/src/main/java/org/eclipse/jetty/client/HttpReceiver.java
index 484b7811065..ab65d91a16d 100644
--- a/jetty-client/src/main/java/org/eclipse/jetty/client/HttpReceiver.java
+++ b/jetty-client/src/main/java/org/eclipse/jetty/client/HttpReceiver.java
@@ -37,6 +37,7 @@ import org.eclipse.jetty.http.HttpStatus;
import org.eclipse.jetty.util.BufferUtil;
import org.eclipse.jetty.util.Callback;
import org.eclipse.jetty.util.CountingCallback;
+import org.eclipse.jetty.util.component.Destroyable;
import org.eclipse.jetty.util.log.Log;
import org.eclipse.jetty.util.log.Logger;
@@ -470,6 +471,7 @@ public abstract class HttpReceiver
*/
protected void reset()
{
+ destroyDecoder(decoder);
decoder = null;
}
@@ -482,9 +484,18 @@ public abstract class HttpReceiver
*/
protected void dispose()
{
+ destroyDecoder(decoder);
decoder = null;
}
+ private static void destroyDecoder(ContentDecoder decoder)
+ {
+ if (decoder instanceof Destroyable)
+ {
+ ((Destroyable)decoder).destroy();
+ }
+ }
+
public boolean abort(HttpExchange exchange, Throwable failure)
{
// Update the state to avoid more response processing.
diff --git a/jetty-documentation/src/main/asciidoc/configuring/deploying/quickstart-webapp.adoc b/jetty-documentation/src/main/asciidoc/configuring/deploying/quickstart-webapp.adoc
index b3651c24f4b..c7cacca4760 100644
--- a/jetty-documentation/src/main/asciidoc/configuring/deploying/quickstart-webapp.adoc
+++ b/jetty-documentation/src/main/asciidoc/configuring/deploying/quickstart-webapp.adoc
@@ -31,18 +31,24 @@ Not only does the `quickstart-web.xml` contain all the discovered Servlets, Filt
With the quickstart mechanism, Jetty is able to entirely bypass all scanning and discovery modes and start a webapp in a predictable and fast way.
Tests have shown that webapps that took many seconds to scan and deploy can now be deployed in a few hundred milliseconds.
+Additionally, if debug logging is enabled, the generated quickstart information is tagged with the origin of every element, which can be useful for debugging purposes.
==== Setting up Quickstart
-To use quickstart the module has to be available to the Jetty instance.
-In a standard Jetty distribution it can be configured with the following command:
+===== Prerequisites
+
+====== Jetty Distribution
+
+In a standard Jetty distribution the quickstart module can be configured with the following command:
[source, screen, subs="{sub-order}"]
----
$ java -jar $JETTY_HOME/start.jar --add-to-start=quickstart
----
-In a Maven project this is done by adding a dependency on the artifact ID `jetty-quickstart`.
+====== Embedded
+
+In a Maven project you add a dependency on the artifact `jetty-quickstart`.
[source, xml, subs="{sub-order}"]
----
@@ -53,26 +59,62 @@ In a Maven project this is done by adding a dependency on the artifact ID `jetty
----
-Additionally, for those using Maven, the link:#get-up-and-running[Jetty Maven Plugin] has a goal, link:#jetty-effective-web-xml[`jetty:effective-web-xml`], which performs quickstart operations.
-It should be noted, however, that the Jetty Maven Plugin also includes additional items on it's classpath which may not be needed by the webapp.
-Deployed webapps need to be instances of link:{JDURL}/org/eclipse/jetty/quickstart/QuickStartWebApp.html[`org.eclipse.jetty.quickstart.QuickStartWebApp`] rather than the normal `org.eclipse.jetty.webapp.WebAppContext`.
-If a web application already has a `webapps/myapp.xml` file, simply change the class in the `Configure` element.
-Otherwise, create a `webapps/myapp.xml` file as follows:
+
+===== Configuration
+
+Webapps need to be instances of link:{JDURL}/org/eclipse/jetty/quickstart/QuickStartWebApp.html[`org.eclipse.jetty.quickstart.QuickStartWebApp`] rather than the normal `org.eclipse.jetty.webapp.WebAppContext`.
+
+`org.eclipse.jetty.quickstart.QuickStartWebApp` instances offer the same setters as the familiar `org.eclipse.jetty.webapp.WebAppContext`, with the addition of:
+
+autoPreconfigure::
+ (true/false).
+ If true, the first time the webapp is run, the WEB-INF/quickstart-web.xml is generated BEFORE the webapp is deployed.
+ Subsequent runs use the previously generated quickstart file.
+
+====== In XML
+If a web application already has a context xml file, eg `webapps/myapp.xml` file, simply change the class in the `Configure` element.
+Otherwise, create a context xml file with the following information (in addition to the usual setting of contextPath, war etc):
[source, xml, subs="{sub-order}"]
----
-
+
- /benchmark.war
- /benchmark
true
----
-For embedded implementations of Jetty, invoking the link:{JDURL}/org/eclipse/jetty/quickstart/PreconfigureQuickStartWar.html[`org.eclipse.jetty.quickstart.PreconfigureQuickStartWar`] class can be used to configure war files for quickstart deployment.
-This will create the `quickstart-web.xml` before the first deployment.
+====== In Code
+
+Create an instance of link:{JDURL}/org/eclipse/jetty/quickstart/QuickStartWebApp.html[`org.eclipse.jetty.quickstart.QuickStartWebApp`] rather than the normal `org.eclipse.jetty.webapp.WebAppContext`. You then use the QuickStartWebApp instance in exactly the same way that you would a WebAppContext.
+
+Here's a snippet:
+
+[source, java]
+----
+ QuickStartWebApp webapp = new QuickStartWebApp();
+ webapp.setAutoPreconfigure(true);
+----
+
+
+====== Pre-generating the quickstart-web.xml file
+
+Rather than use the `autoPreconfigure` feature of the QuickStartWebApp - which lazily generates the `quickstart-web.xml` file - you can eagerly pre-generate it for an existing war by invoking as a main class link:{JDURL}/org/eclipse/jetty/quickstart/PreconfigureQuickStartWar.html[`org.eclipse.jetty.quickstart.PreconfigureQuickStartWar`].
+Note that you will need to provide all necessary jetty jars on the command line classpath.
+This will unpack the war if necessary, and create the `quickstart-web.xml` before the first deployment:
+
+
+[source, screen, subs="{sub-order}"]
+----
+$ java -cp [jetty classpath] org.eclipse.jetty.quickstart.PreconfigureQuickStartWar myapp.war
+----
+
+Run the class with no arguments to see other runtime options.
+
+Alternatively, you could use the link:#get-up-and-running[Jetty Maven Plugin] goal link:#jetty-effective-web-xml[`jetty:effective-web-xml`]: this will generate quickstart information, but print it to stderr.
+The goal provides a configuration option to save the output to a file, which you can then copy into your webapp's WEB-INF dir.
+Note that as the Jetty Maven Plugin is a general tool for running webapps, it may have more jars on its classpath than are needed by your application, and thus may generate extra quickstart information: we recommend that you use this goal only as a quick guide to the type of information that quickstart generates.
// ==== Preconfiguring the web application
//
@@ -81,14 +123,8 @@ This will create the `quickstart-web.xml` before the first deployment.
//
// It is also possible to preconfigure a war file manually by running the class link:{JDURL}/org/eclipse/jetty/quickstart/PreconfigureQuickStartWar.html[org.eclipse.jetty.quickstart.PreconfigureQuickStartWar] with the jetty-all-uber (aggregate) jar:
//
-// [source, screen, subs="{sub-order}"]
-// ----
-// $ java -cp jetty-all-{VERSION}-uber.jar org.eclipse.jetty.quickstart.PreconfigureQuickStartWar myapp.war
-// ----
//
// This will create the `quickstart-web.xml` file before the first deployment.
-// Note that this can also be a good debugging tool for discovered configuration and if run with debug turned on the origin of every element is included in the `quickstart-web.xml` file.
-// Run the class with no arguments to see other runtime options.
==== Avoiding TLD Scans with precompiled JSPs
diff --git a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud-datastore.mod b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud-datastore.mod
index c98eaf22514..43d1ea6e7b2 100644
--- a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud-datastore.mod
+++ b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud-datastore.mod
@@ -1,6 +1,10 @@
[description]
Enables GCloud Datastore API and implementation
+[Tags]
+3rdparty
+gcloud
+
[depends]
gcloud
jcl-api
diff --git a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud.mod b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud.mod
index 7c774c795d0..1508e7e98d3 100644
--- a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud.mod
+++ b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/gcloud.mod
@@ -1,6 +1,10 @@
[description]
Control GCloud API classpath
+[Tags]
+3rdparty
+gcloud
+
[files]
basehome:modules/gcloud/gcloud.xml|etc/gcloud.xml
diff --git a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/session-store-gcloud.mod b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/session-store-gcloud.mod
index 3d6b26e0497..c5e933032fa 100644
--- a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/session-store-gcloud.mod
+++ b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config/modules/session-store-gcloud.mod
@@ -1,6 +1,10 @@
[description]
Enables GCloudDatastore session management.
+[Tags]
+session
+gcloud
+
[provides]
session-store
diff --git a/jetty-home/src/main/resources/modules/hawtio.mod b/jetty-home/src/main/resources/modules/hawtio.mod
index fcc34d15048..c8eeb0d888d 100644
--- a/jetty-home/src/main/resources/modules/hawtio.mod
+++ b/jetty-home/src/main/resources/modules/hawtio.mod
@@ -1,6 +1,9 @@
[description]
Deploys the Hawtio console as a webapplication.
+[Tags]
+3rdparty
+
[depend]
stats
deploy
diff --git a/jetty-home/src/main/resources/modules/jamon.mod b/jetty-home/src/main/resources/modules/jamon.mod
index 96a331c65ad..72c76f055ff 100644
--- a/jetty-home/src/main/resources/modules/jamon.mod
+++ b/jetty-home/src/main/resources/modules/jamon.mod
@@ -1,6 +1,9 @@
[description]
Deploys the JAMon webapplication
+[Tags]
+3rdparty
+
[depend]
stats
deploy
diff --git a/jetty-home/src/main/resources/modules/jminix.mod b/jetty-home/src/main/resources/modules/jminix.mod
index 4bd48c9e72d..fc8328921f5 100644
--- a/jetty-home/src/main/resources/modules/jminix.mod
+++ b/jetty-home/src/main/resources/modules/jminix.mod
@@ -1,6 +1,9 @@
[description]
Deploys the Jminix JMX Console within the server
+[Tags]
+3rdparty
+
[depend]
stats
jmx
diff --git a/jetty-home/src/main/resources/modules/jolokia.mod b/jetty-home/src/main/resources/modules/jolokia.mod
index 8d03179697e..669e83c6da6 100644
--- a/jetty-home/src/main/resources/modules/jolokia.mod
+++ b/jetty-home/src/main/resources/modules/jolokia.mod
@@ -1,6 +1,9 @@
[description]
Deploys the Jolokia console as a web application.
+[Tags]
+3rdparty
+
[depend]
stats
deploy
diff --git a/jetty-http/src/main/java/org/eclipse/jetty/http/GZIPContentDecoder.java b/jetty-http/src/main/java/org/eclipse/jetty/http/GZIPContentDecoder.java
index 57cfa0fa51b..122421c66c3 100644
--- a/jetty-http/src/main/java/org/eclipse/jetty/http/GZIPContentDecoder.java
+++ b/jetty-http/src/main/java/org/eclipse/jetty/http/GZIPContentDecoder.java
@@ -25,6 +25,7 @@ import java.util.zip.ZipException;
import org.eclipse.jetty.io.ByteBufferPool;
import org.eclipse.jetty.util.BufferUtil;
+import org.eclipse.jetty.util.component.Destroyable;
/**
* Decoder for the "gzip" encoding.
@@ -32,7 +33,7 @@ import org.eclipse.jetty.util.BufferUtil;
* A decoder that inflates gzip compressed data that has been
* optimized for async usage with minimal data copies.
*/
-public class GZIPContentDecoder
+public class GZIPContentDecoder implements Destroyable
{
private final Inflater _inflater = new Inflater(true);
private final ByteBufferPool _pool;
@@ -383,6 +384,12 @@ public class GZIPContentDecoder
_flags = 0;
}
+ @Override
+ public void destroy()
+ {
+ _inflater.end();
+ }
+
public boolean isFinished()
{
return _state == State.INITIAL;
diff --git a/jetty-http2/http2-server/src/main/config/modules/http2.mod b/jetty-http2/http2-server/src/main/config/modules/http2.mod
index 88baddb13ab..5927f571279 100644
--- a/jetty-http2/http2-server/src/main/config/modules/http2.mod
+++ b/jetty-http2/http2-server/src/main/config/modules/http2.mod
@@ -2,6 +2,12 @@
Enables HTTP2 protocol support on the TLS(SSL) Connector,
using the ALPN extension to select which protocol to use.
+[Tags]
+connector
+http2
+http
+ssl
+
[depend]
ssl
alpn
diff --git a/jetty-http2/http2-server/src/main/config/modules/http2c.mod b/jetty-http2/http2-server/src/main/config/modules/http2c.mod
index 80b2a28a335..b0fee130af5 100644
--- a/jetty-http2/http2-server/src/main/config/modules/http2c.mod
+++ b/jetty-http2/http2-server/src/main/config/modules/http2c.mod
@@ -2,6 +2,11 @@
Enables the HTTP2C protocol on the HTTP Connector
The connector will accept both HTTP/1 and HTTP/2 connections.
+[Tags]
+connector
+http2
+http
+
[depend]
http
diff --git a/jetty-infinispan/src/main/config/modules/session-store-infinispan-embedded.mod b/jetty-infinispan/src/main/config/modules/session-store-infinispan-embedded.mod
index 76441062683..bd0bb80ea10 100644
--- a/jetty-infinispan/src/main/config/modules/session-store-infinispan-embedded.mod
+++ b/jetty-infinispan/src/main/config/modules/session-store-infinispan-embedded.mod
@@ -1,6 +1,9 @@
[description]
Enables session data store in a local Infinispan cache
+[Tags]
+session
+
[provides]
session-store
diff --git a/jetty-infinispan/src/main/config/modules/session-store-infinispan-remote.mod b/jetty-infinispan/src/main/config/modules/session-store-infinispan-remote.mod
index f9c398a5b1e..70c62076d94 100644
--- a/jetty-infinispan/src/main/config/modules/session-store-infinispan-remote.mod
+++ b/jetty-infinispan/src/main/config/modules/session-store-infinispan-remote.mod
@@ -1,6 +1,9 @@
[description]
Enables session data store in a remote Infinispan cache
+[Tags]
+session
+
[provides]
session-store
diff --git a/jetty-memcached/jetty-memcached-sessions/src/main/config/modules/sessions/session-data-cache/xmemcached.mod b/jetty-memcached/jetty-memcached-sessions/src/main/config/modules/sessions/session-data-cache/xmemcached.mod
index 76987983ddc..48c589ae00c 100644
--- a/jetty-memcached/jetty-memcached-sessions/src/main/config/modules/sessions/session-data-cache/xmemcached.mod
+++ b/jetty-memcached/jetty-memcached-sessions/src/main/config/modules/sessions/session-data-cache/xmemcached.mod
@@ -1,6 +1,9 @@
[description]
Memcache cache for SessionData
+[Tags]
+session
+
[depends]
session-store
slf4j-api
diff --git a/jetty-nosql/src/main/config/modules/session-store-mongo.mod b/jetty-nosql/src/main/config/modules/session-store-mongo.mod
index 77723093f6d..c1ffb5c755e 100644
--- a/jetty-nosql/src/main/config/modules/session-store-mongo.mod
+++ b/jetty-nosql/src/main/config/modules/session-store-mongo.mod
@@ -1,6 +1,9 @@
[description]
Enables NoSql session management with a MongoDB driver.
+[Tags]
+session
+
[provides]
session-store
diff --git a/jetty-server/src/main/config/modules/debug.mod b/jetty-server/src/main/config/modules/debug.mod
index 7b75ecc0e79..9e0ae040b9f 100644
--- a/jetty-server/src/main/config/modules/debug.mod
+++ b/jetty-server/src/main/config/modules/debug.mod
@@ -3,6 +3,9 @@ Enables the DebugListener to generate additional
logging regarding detailed request handling events.
Renames threads to include request URI.
+[Tags]
+debug
+
[depend]
deploy
diff --git a/jetty-server/src/main/config/modules/debuglog.mod b/jetty-server/src/main/config/modules/debuglog.mod
index a76f728a5b4..81db4894c71 100644
--- a/jetty-server/src/main/config/modules/debuglog.mod
+++ b/jetty-server/src/main/config/modules/debuglog.mod
@@ -2,6 +2,9 @@
Deprecated Debug Log using the DebugHandle.
Replaced with the debug module.
+[Tags]
+debug
+
[depend]
server
diff --git a/jetty-server/src/main/config/modules/ext.mod b/jetty-server/src/main/config/modules/ext.mod
index 4171f8dfc21..63081e550dd 100644
--- a/jetty-server/src/main/config/modules/ext.mod
+++ b/jetty-server/src/main/config/modules/ext.mod
@@ -2,6 +2,9 @@
Adds all jar files discovered in $JETTY_HOME/lib/ext
and $JETTY_BASE/lib/ext to the servers classpath.
+[Tags]
+classpath
+
[lib]
lib/ext/**.jar
diff --git a/jetty-server/src/main/config/modules/gzip.mod b/jetty-server/src/main/config/modules/gzip.mod
index d0173efa60f..50db40b156e 100644
--- a/jetty-server/src/main/config/modules/gzip.mod
+++ b/jetty-server/src/main/config/modules/gzip.mod
@@ -2,6 +2,9 @@
Enable GzipHandler for dynamic gzip compression
for the entire server.
+[Tags]
+handler
+
[depend]
server
diff --git a/jetty-server/src/main/config/modules/http-forwarded.mod b/jetty-server/src/main/config/modules/http-forwarded.mod
index 6508a2b9a3f..2797bc29d3b 100644
--- a/jetty-server/src/main/config/modules/http-forwarded.mod
+++ b/jetty-server/src/main/config/modules/http-forwarded.mod
@@ -2,6 +2,9 @@
Adds a forwarded request customizer to the HTTP Connector
to process forwarded-for style headers from a proxy.
+[Tags]
+connector
+
[depend]
http
diff --git a/jetty-server/src/main/config/modules/http.mod b/jetty-server/src/main/config/modules/http.mod
index 3f2766f0e45..caf104cb9b4 100644
--- a/jetty-server/src/main/config/modules/http.mod
+++ b/jetty-server/src/main/config/modules/http.mod
@@ -3,6 +3,10 @@ Enables a HTTP connector on the server.
By default HTTP/1 is support, but HTTP2C can
be added to the connector with the http2c module.
+[Tags]
+connector
+http
+
[depend]
server
diff --git a/jetty-server/src/main/config/modules/https.mod b/jetty-server/src/main/config/modules/https.mod
index 6ffbd69d0cc..9ff301e58d5 100644
--- a/jetty-server/src/main/config/modules/https.mod
+++ b/jetty-server/src/main/config/modules/https.mod
@@ -1,6 +1,12 @@
[description]
Adds HTTPS protocol support to the TLS(SSL) Connector
+[Tags]
+connector
+https
+http
+ssl
+
[depend]
ssl
diff --git a/jetty-server/src/main/config/modules/ipaccess.mod b/jetty-server/src/main/config/modules/ipaccess.mod
index 68f04dfc576..5afd05e0a11 100644
--- a/jetty-server/src/main/config/modules/ipaccess.mod
+++ b/jetty-server/src/main/config/modules/ipaccess.mod
@@ -2,6 +2,9 @@
Enable the ipaccess handler to apply a white/black list
control of the remote IP of requests.
+[Tags]
+handler
+
[depend]
server
diff --git a/jetty-server/src/main/config/modules/jvm.mod b/jetty-server/src/main/config/modules/jvm.mod
index 173a6d11ba1..b6793e3b03b 100644
--- a/jetty-server/src/main/config/modules/jvm.mod
+++ b/jetty-server/src/main/config/modules/jvm.mod
@@ -1,6 +1,7 @@
[description]
A noop module that creates an ini template useful for
setting JVM arguments (eg -Xmx )
+
[ini-template]
## JVM Configuration
## If JVM args are include in an ini file then --exec is needed
diff --git a/jetty-server/src/main/config/modules/logback-access.mod b/jetty-server/src/main/config/modules/logback-access.mod
index b1275ba49b9..0cb8bd0de45 100644
--- a/jetty-server/src/main/config/modules/logback-access.mod
+++ b/jetty-server/src/main/config/modules/logback-access.mod
@@ -1,6 +1,11 @@
[description]
Enables logback request log.
+[Tags]
+requestlog
+logging
+logback
+
[depend]
server
logback-core
diff --git a/jetty-server/src/main/config/modules/proxy-protocol-ssl.mod b/jetty-server/src/main/config/modules/proxy-protocol-ssl.mod
index 374763d0b5b..4b41e935bb6 100644
--- a/jetty-server/src/main/config/modules/proxy-protocol-ssl.mod
+++ b/jetty-server/src/main/config/modules/proxy-protocol-ssl.mod
@@ -5,6 +5,10 @@ This allows a Proxy operating in TCP mode to transport
details of the proxied connection to the server.
Both V1 and V2 versions of the protocol are supported.
+[Tags]
+connector
+ssl
+
[depend]
ssl
diff --git a/jetty-server/src/main/config/modules/requestlog.mod b/jetty-server/src/main/config/modules/requestlog.mod
index 628f759e088..0bf60edcdc0 100644
--- a/jetty-server/src/main/config/modules/requestlog.mod
+++ b/jetty-server/src/main/config/modules/requestlog.mod
@@ -1,6 +1,9 @@
[description]
Enables a NCSA style request log.
+[Tags]
+requestlog
+
[depend]
server
@@ -36,4 +39,4 @@ logs/
# jetty.requestlog.timezone=GMT
## Whether to log LogLatency
-# jetty.requestlog.loglatency=false
\ No newline at end of file
+# jetty.requestlog.loglatency=false
diff --git a/jetty-server/src/main/config/modules/resources.mod b/jetty-server/src/main/config/modules/resources.mod
index 56489486408..4e0bd35b43a 100644
--- a/jetty-server/src/main/config/modules/resources.mod
+++ b/jetty-server/src/main/config/modules/resources.mod
@@ -3,6 +3,9 @@ Adds the $JETTY_HOME/resources and/or $JETTY_BASE/resources
directory to the server classpath. Useful for configuration
property files (eg jetty-logging.properties)
+[Tags]
+classpath
+
[lib]
resources/
diff --git a/jetty-server/src/main/config/modules/session-cache-hash.mod b/jetty-server/src/main/config/modules/session-cache-hash.mod
index 9a09ec5dbdb..1f257867b25 100644
--- a/jetty-server/src/main/config/modules/session-cache-hash.mod
+++ b/jetty-server/src/main/config/modules/session-cache-hash.mod
@@ -4,6 +4,9 @@ If not enabled, sessions will use a HashSessionCache by default, so enabling
via this module is only needed if the configuration properties need to be
changed.
+[Tags]
+session
+
[provides]
session-cache
diff --git a/jetty-server/src/main/config/modules/session-cache-null.mod b/jetty-server/src/main/config/modules/session-cache-null.mod
index 81e5b02b9e4..70c9e97fa37 100644
--- a/jetty-server/src/main/config/modules/session-cache-null.mod
+++ b/jetty-server/src/main/config/modules/session-cache-null.mod
@@ -1,6 +1,9 @@
[description]
A trivial SessionCache that does not actually cache sessions.
+[Tags]
+session
+
[provides]
session-cache
diff --git a/jetty-server/src/main/config/modules/session-store-cache.mod b/jetty-server/src/main/config/modules/session-store-cache.mod
index e9a170b823e..cac19d1207d 100644
--- a/jetty-server/src/main/config/modules/session-store-cache.mod
+++ b/jetty-server/src/main/config/modules/session-store-cache.mod
@@ -1,6 +1,9 @@
[description]
Enables caching of SessionData in front of a SessionDataStore.
+[Tags]
+session
+
[depend]
session-store
diff --git a/jetty-server/src/main/config/modules/session-store-file.mod b/jetty-server/src/main/config/modules/session-store-file.mod
index 22726641879..d644f67dddd 100644
--- a/jetty-server/src/main/config/modules/session-store-file.mod
+++ b/jetty-server/src/main/config/modules/session-store-file.mod
@@ -1,6 +1,9 @@
[description]
Enables session persistent storage in files.
+[Tags]
+session
+
[provides]
session-store
diff --git a/jetty-server/src/main/config/modules/session-store-jdbc.mod b/jetty-server/src/main/config/modules/session-store-jdbc.mod
index a3f41956b24..69bf3125bd0 100644
--- a/jetty-server/src/main/config/modules/session-store-jdbc.mod
+++ b/jetty-server/src/main/config/modules/session-store-jdbc.mod
@@ -1,6 +1,9 @@
[description]
Enables JDBC peristent/distributed session storage.
+[Tags]
+session
+
[provides]
session-store
diff --git a/jetty-server/src/main/config/modules/sessions.mod b/jetty-server/src/main/config/modules/sessions.mod
index e90cd8aa2bd..4ce1cde856e 100644
--- a/jetty-server/src/main/config/modules/sessions.mod
+++ b/jetty-server/src/main/config/modules/sessions.mod
@@ -5,6 +5,9 @@ created or by enabling other session-cache or session-store
modules. Without this module enabled, the server may still
use sessions, but their management cannot be configured.
+[Tags]
+session
+
[depends]
server
diff --git a/jetty-server/src/main/config/modules/ssl.mod b/jetty-server/src/main/config/modules/ssl.mod
index 43c29143bde..db92f255bb2 100644
--- a/jetty-server/src/main/config/modules/ssl.mod
+++ b/jetty-server/src/main/config/modules/ssl.mod
@@ -3,6 +3,10 @@ Enables a TLS(SSL) Connector on the server.
This may be used for HTTPS and/or HTTP2 by enabling
the associated support modules.
+[Tags]
+connector
+ssl
+
[depend]
server
diff --git a/jetty-server/src/main/config/modules/stats.mod b/jetty-server/src/main/config/modules/stats.mod
index 838d54a904d..2b4d3d32f8b 100644
--- a/jetty-server/src/main/config/modules/stats.mod
+++ b/jetty-server/src/main/config/modules/stats.mod
@@ -2,6 +2,9 @@
Enable detailed statistics collection for the server,
available via JMX.
+[Tags]
+handler
+
[depend]
server
diff --git a/jetty-server/src/main/config/modules/threadlimit.mod b/jetty-server/src/main/config/modules/threadlimit.mod
index 1a2615bd9b9..b6d41dc1480 100644
--- a/jetty-server/src/main/config/modules/threadlimit.mod
+++ b/jetty-server/src/main/config/modules/threadlimit.mod
@@ -3,6 +3,9 @@
# Applies ThreadLimiteHandler to entire server
#
+[Tags]
+handler
+
[depend]
server
diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/HttpInput.java b/jetty-server/src/main/java/org/eclipse/jetty/server/HttpInput.java
index 839493b50a1..52604608e28 100644
--- a/jetty-server/src/main/java/org/eclipse/jetty/server/HttpInput.java
+++ b/jetty-server/src/main/java/org/eclipse/jetty/server/HttpInput.java
@@ -37,6 +37,7 @@ import org.eclipse.jetty.io.EofException;
import org.eclipse.jetty.io.RuntimeIOException;
import org.eclipse.jetty.util.BufferUtil;
import org.eclipse.jetty.util.Callback;
+import org.eclipse.jetty.util.component.Destroyable;
import org.eclipse.jetty.util.log.Log;
import org.eclipse.jetty.util.log.Logger;
@@ -80,7 +81,7 @@ public class HttpInput extends ServletInputStream implements Runnable
* {@link #readFrom(Content)} and then passes any {@link Content} returned
* to the next {@link Interceptor}.
*/
- public static class ChainedInterceptor implements Interceptor
+ public static class ChainedInterceptor implements Interceptor, Destroyable
{
private final Interceptor _prev;
private final Interceptor _next;
@@ -106,8 +107,16 @@ public class HttpInput extends ServletInputStream implements Runnable
{
return getNext().readFrom(getPrev().readFrom(content));
}
+
+ @Override
+ public void destroy()
+ {
+ if (_prev instanceof Destroyable)
+ ((Destroyable)_prev).destroy();
+ if (_next instanceof Destroyable)
+ ((Destroyable)_next).destroy();
+ }
}
-
private final static Logger LOG = Log.getLogger(HttpInput.class);
private final static Content EOF_CONTENT = new EofContent("EOF");
@@ -155,6 +164,8 @@ public class HttpInput extends ServletInputStream implements Runnable
_contentConsumed = 0;
_firstByteTimeStamp = -1;
_blockUntil = 0;
+ if (_interceptor instanceof Destroyable)
+ ((Destroyable)_interceptor).destroy();
_interceptor = null;
}
}
diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpInputInterceptor.java b/jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpInputInterceptor.java
index 97198e736f6..4f55cd956b5 100644
--- a/jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpInputInterceptor.java
+++ b/jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpInputInterceptor.java
@@ -24,18 +24,51 @@ import org.eclipse.jetty.http.GZIPContentDecoder;
import org.eclipse.jetty.io.ByteBufferPool;
import org.eclipse.jetty.server.HttpInput;
import org.eclipse.jetty.server.HttpInput.Content;
+import org.eclipse.jetty.util.component.Destroyable;
/**
* A HttpInput Interceptor that inflates GZIP encoded request content.
- *
*/
-public class GzipHttpInputInterceptor implements HttpInput.Interceptor
+public class GzipHttpInputInterceptor implements HttpInput.Interceptor, Destroyable
{
- class Decoder extends GZIPContentDecoder
+ private final Decoder _decoder;
+ private ByteBuffer _chunk;
+
+ public GzipHttpInputInterceptor(ByteBufferPool pool, int bufferSize)
{
- public Decoder(ByteBufferPool pool, int bufferSize)
+ _decoder = new Decoder(pool, bufferSize);
+ }
+
+ @Override
+ public Content readFrom(Content content)
+ {
+ _decoder.decodeChunks(content.getByteBuffer());
+ final ByteBuffer chunk = _chunk;
+
+ if (chunk == null)
+ return null;
+
+ return new Content(chunk)
{
- super(pool,bufferSize);
+ @Override
+ public void succeeded()
+ {
+ _decoder.release(chunk);
+ }
+ };
+ }
+
+ @Override
+ public void destroy()
+ {
+ _decoder.destroy();
+ }
+
+ private class Decoder extends GZIPContentDecoder
+ {
+ private Decoder(ByteBufferPool pool, int bufferSize)
+ {
+ super(pool, bufferSize);
}
@Override
@@ -52,32 +85,4 @@ public class GzipHttpInputInterceptor implements HttpInput.Interceptor
super.decodeChunks(compressed);
}
}
-
- private final Decoder _decoder;
- private ByteBuffer _chunk;
-
- public GzipHttpInputInterceptor(ByteBufferPool pool, int bufferSize)
- {
- _decoder = new Decoder(pool,bufferSize);
- }
-
- @Override
- public Content readFrom(Content content)
- {
- _decoder.decodeChunks(content.getByteBuffer());
- final ByteBuffer chunk = _chunk;
-
- if (chunk==null)
- return null;
-
- return new Content(chunk)
- {
- @Override
- public void succeeded()
- {
- _decoder.release(chunk);
- }
- };
- }
-
}
diff --git a/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java b/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java
index 3463ad3ecfe..39c7bbabfa4 100644
--- a/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java
+++ b/jetty-start/src/main/java/org/eclipse/jetty/start/Main.java
@@ -243,16 +243,19 @@ public class Main
public void listModules(StartArgs args)
{
+ List tags = args.getListModules();
+
StartLog.endStartLog();
System.out.println();
- System.out.println("Jetty All Available Modules:");
- System.out.println("----------------------------");
- args.getAllModules().dump();
+ System.out.println("Available Modules:");
+ System.out.println("==================");
+ System.out.println("tags: "+tags);
+ args.getAllModules().dump(tags);
// Dump Enabled Modules
System.out.println();
- System.out.println("Jetty Selected Module Ordering:");
- System.out.println("-------------------------------");
+ System.out.println("Enabled Modules:");
+ System.out.println("================");
Modules modules = args.getAllModules();
modules.dumpEnabled();
}
@@ -381,7 +384,7 @@ public class Main
}
// Show modules
- if (args.isListModules())
+ if (args.getListModules()!=null)
{
listModules(args);
}
diff --git a/jetty-start/src/main/java/org/eclipse/jetty/start/Module.java b/jetty-start/src/main/java/org/eclipse/jetty/start/Module.java
index 7f31cf3390f..e318cc127a9 100644
--- a/jetty-start/src/main/java/org/eclipse/jetty/start/Module.java
+++ b/jetty-start/src/main/java/org/eclipse/jetty/start/Module.java
@@ -55,7 +55,7 @@ import java.util.stream.Collectors;
* A module may be enabled, either directly by name or transiently via a dependency
* from another module by name or provided capability.
*/
-public class Module
+public class Module implements Comparable
{
private static final String VERSION_UNSPECIFIED = "9.2";
private static Pattern MOD_NAME = Pattern.compile("^(.*)\\.mod",Pattern.CASE_INSENSITIVE);
@@ -96,6 +96,9 @@ public class Module
/** List of provides for this Module */
private final Set _provides=new HashSet<>();
+ /** List of tags for this Module */
+ private final List _tags=new ArrayList<>();
+
/** Boolean true if directly enabled, false if all selections are transitive */
private boolean _notTransitive;
@@ -328,6 +331,10 @@ public class Module
case "FILES":
_files.add(line);
break;
+ case "TAG":
+ case "TAGS":
+ _tags.add(line);
+ break;
case "DEFAULTS": // old name introduced in 9.2.x
case "INI": // new name for 9.3+
_defaultConfig.add(line);
@@ -446,6 +453,16 @@ public class Module
return _description;
}
+ public List getTags()
+ {
+ return _tags;
+ }
+
+ public String getPrimaryTag()
+ {
+ return _tags.isEmpty()?"*":_tags.get(0);
+ }
+
public boolean isEnabled()
{
return !_enables.isEmpty();
@@ -504,4 +521,13 @@ public class Module
out.println();
out.flush();
}
+
+ @Override
+ public int compareTo(Module m)
+ {
+ int by_tag = getPrimaryTag().compareTo(m.getPrimaryTag());
+ if (by_tag!=0)
+ return by_tag;
+ return getName().compareTo(m.getName());
+ }
}
diff --git a/jetty-start/src/main/java/org/eclipse/jetty/start/Modules.java b/jetty-start/src/main/java/org/eclipse/jetty/start/Modules.java
index 3fee8802054..23eed50c70f 100644
--- a/jetty-start/src/main/java/org/eclipse/jetty/start/Modules.java
+++ b/jetty-start/src/main/java/org/eclipse/jetty/start/Modules.java
@@ -21,7 +21,6 @@ package org.eclipse.jetty.start;
import java.io.IOException;
import java.nio.file.Path;
import java.util.ArrayList;
-import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
@@ -30,6 +29,7 @@ import java.util.Map;
import java.util.Optional;
import java.util.Set;
import java.util.concurrent.atomic.AtomicBoolean;
+import java.util.concurrent.atomic.AtomicReference;
import java.util.function.Consumer;
import java.util.stream.Collectors;
import java.util.stream.Stream;
@@ -57,59 +57,92 @@ public class Modules implements Iterable
}
}
- public void dump()
+ public void dump(List tags)
{
- List ordered = _modules.stream().map(m->{return m.getName();}).collect(Collectors.toList());
- Collections.sort(ordered);
- ordered.stream().map(n->{return get(n);}).forEach(module->
- {
- String status = "[ ]";
- if (module.isTransitive())
+ Set exclude = tags.stream().filter(t->t.startsWith("-")).map(t->t.substring(1)).collect(Collectors.toSet());
+ Set include = tags.stream().filter(t->!t.startsWith("-")).collect(Collectors.toSet());
+ boolean all = include.contains("*") || include.isEmpty();
+ AtomicReference tag = new AtomicReference<>();
+
+ _modules.stream()
+ .filter(m->
{
- status = "[t]";
- }
- else if (module.isEnabled())
+ boolean included = all || m.getTags().stream().anyMatch(t->include.contains(t));
+ boolean excluded = m.getTags().stream().anyMatch(t->exclude.contains(t));
+ return included && !excluded;
+ })
+ .sorted()
+ .forEach(module->
{
- status = "[x]";
- }
-
- System.out.printf("%n %s Module: %s%n",status,module.getName());
- if (module.getProvides().size()>1)
- {
- System.out.printf(" Provides: %s%n",module.getProvides());
- }
- for (String description : module.getDescription())
- {
- System.out.printf(" : %s%n",description);
- }
- for (String parent : module.getDepends())
- {
- System.out.printf(" Depend: %s%n",parent);
- }
- for (String optional : module.getOptional())
- {
- System.out.printf(" Optional: %s%n",optional);
- }
- for (String lib : module.getLibs())
- {
- System.out.printf(" LIB: %s%n",lib);
- }
- for (String xml : module.getXmls())
- {
- System.out.printf(" XML: %s%n",xml);
- }
- for (String jvm : module.getJvmArgs())
- {
- System.out.printf(" JVM: %s%n",jvm);
- }
- if (module.isEnabled())
- {
- for (String selection : module.getEnableSources())
+ if (!module.getPrimaryTag().equals(tag.get()))
{
- System.out.printf(" Enabled: %s%n",selection);
+ tag.set(module.getPrimaryTag());
+ System.out.printf("%nModules for tag '%s':%n",module.getPrimaryTag());
+ System.out.print("-------------------");
+ for (int i=module.getPrimaryTag().length();i-->0;)
+ System.out.print("-");
+ System.out.println();
+
}
- }
- });
+
+ String label;
+ Set provides = module.getProvides();
+ provides.remove(module.getName());
+ System.out.printf("%n Module: %s %s%n",module.getName(),provides.size()>0?provides:"");
+ for (String description : module.getDescription())
+ {
+ System.out.printf(" : %s%n",description);
+ }
+ if (!module.getTags().isEmpty())
+ {
+ label=" Tags: %s";
+ for (String t : module.getTags())
+ {
+ System.out.printf(label,t);
+ label=", %s";
+ }
+ System.out.println();
+ }
+ if (!module.getDepends().isEmpty())
+ {
+ label=" Depend: %s";
+ for (String parent : module.getDepends())
+ {
+ System.out.printf(label,parent);
+ label=", %s";
+ }
+ System.out.println();
+ }
+ if (!module.getOptional().isEmpty())
+ {
+ label=" Optional: %s";
+ for (String parent : module.getOptional())
+ {
+ System.out.printf(label,parent);
+ label=", %s";
+ }
+ System.out.println();
+ }
+ for (String lib : module.getLibs())
+ {
+ System.out.printf(" LIB: %s%n",lib);
+ }
+ for (String xml : module.getXmls())
+ {
+ System.out.printf(" XML: %s%n",xml);
+ }
+ for (String jvm : module.getJvmArgs())
+ {
+ System.out.printf(" JVM: %s%n",jvm);
+ }
+ if (module.isEnabled())
+ {
+ for (String selection : module.getEnableSources())
+ {
+ System.out.printf(" Enabled: %s%n",selection);
+ }
+ }
+ });
}
public void dumpEnabled()
diff --git a/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java b/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java
index 5b5bc8f5fc8..5a3e94ad119 100644
--- a/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java
+++ b/jetty-start/src/main/java/org/eclipse/jetty/start/StartArgs.java
@@ -170,7 +170,7 @@ public class StartArgs
private boolean help = false;
private boolean stopCommand = false;
- private boolean listModules = false;
+ private List listModules = null;
private boolean listClasspath = false;
private boolean listConfig = false;
private boolean version = false;
@@ -750,7 +750,7 @@ public class StartArgs
return listConfig;
}
- public boolean isListModules()
+ public List getListModules()
{
return listModules;
}
@@ -873,7 +873,7 @@ public class StartArgs
if (arg.equals("--create-files"))
{
run = false;
- download = true;
+ download = true;boolean
licenseCheckRequired = true;
return;
}
@@ -938,10 +938,25 @@ public class StartArgs
return;
}
+ // Module Management
+ if ("--list-all-modules".equals(arg))
+ {
+ listModules = Collections.singletonList("*");
+ run = false;
+ return;
+ }
+
// Module Management
if ("--list-modules".equals(arg))
{
- listModules = true;
+ listModules = Collections.singletonList("-verbose");
+ run = false;
+ return;
+ }
+
+ if (arg.startsWith("--list-modules="))
+ {
+ listModules = Props.getValues(arg);
run = false;
return;
}
diff --git a/jetty-start/src/main/resources/org/eclipse/jetty/start/usage.txt b/jetty-start/src/main/resources/org/eclipse/jetty/start/usage.txt
index 27f76f44016..fad5157f0ae 100644
--- a/jetty-start/src/main/resources/org/eclipse/jetty/start/usage.txt
+++ b/jetty-start/src/main/resources/org/eclipse/jetty/start/usage.txt
@@ -59,7 +59,7 @@ Debug and Start Logging:
Module Management:
------------------
- --list-modules List all modules defined by the system.
+ --list-modules List non verbose modules defined by the system.
Looking for module files in ${jetty.base}/modules/*.mod and
then ${jetty.home}/modules/*.mod
Will also list enabled state based on information
@@ -67,6 +67,13 @@ Module Management:
o The command line
o The ${jetty.base}/start.ini
o The ${jetty.base}/start.d/*.ini files
+
+ --list-modules=(,)*
+ List modules by tag. Use '*' for all tags. Prefix a tag
+ with '-' to exclude the tag.
+
+ --list-all-modules
+ List all modules.
--module=(,)*
Temporarily enable a module from the command line.
diff --git a/jetty-unixsocket/src/main/config/modules/unixsocket-forwarded.mod b/jetty-unixsocket/src/main/config/modules/unixsocket-forwarded.mod
index 80d19995880..cb14381ebae 100644
--- a/jetty-unixsocket/src/main/config/modules/unixsocket-forwarded.mod
+++ b/jetty-unixsocket/src/main/config/modules/unixsocket-forwarded.mod
@@ -4,6 +4,9 @@ by the Unix Domain Socket connector, for use when behind a proxy operating
in HTTP mode that adds forwarded-for style HTTP headers. Typically this
is an alternate to the Proxy Protocol used mostly for TCP mode.
+[Tags]
+connector
+
[depend]
unixsocket-http
diff --git a/jetty-unixsocket/src/main/config/modules/unixsocket-http.mod b/jetty-unixsocket/src/main/config/modules/unixsocket-http.mod
index 05c46bee795..1605722f685 100644
--- a/jetty-unixsocket/src/main/config/modules/unixsocket-http.mod
+++ b/jetty-unixsocket/src/main/config/modules/unixsocket-http.mod
@@ -4,6 +4,10 @@ It should be used when a proxy is forwarding either HTTP or decrypted
HTTPS traffic to the connector and may be used with the
unix-socket-http2c modules to upgrade to HTTP/2.
+[Tags]
+connector
+http
+
[depend]
unixsocket
diff --git a/jetty-unixsocket/src/main/config/modules/unixsocket-http2c.mod b/jetty-unixsocket/src/main/config/modules/unixsocket-http2c.mod
index 59f844977be..6e112221cfe 100644
--- a/jetty-unixsocket/src/main/config/modules/unixsocket-http2c.mod
+++ b/jetty-unixsocket/src/main/config/modules/unixsocket-http2c.mod
@@ -3,6 +3,10 @@ Adds a HTTP2C connetion factory to the Unix Domain Socket Connector
It can be used when either the proxy forwards direct
HTTP/2C (unecrypted) or decrypted HTTP/2 traffic.
+[Tags]
+connector
+http2
+
[depend]
unixsocket-http
diff --git a/jetty-unixsocket/src/main/config/modules/unixsocket-proxy-protocol.mod b/jetty-unixsocket/src/main/config/modules/unixsocket-proxy-protocol.mod
index 11184d39471..cfa3c726fb7 100644
--- a/jetty-unixsocket/src/main/config/modules/unixsocket-proxy-protocol.mod
+++ b/jetty-unixsocket/src/main/config/modules/unixsocket-proxy-protocol.mod
@@ -8,6 +8,9 @@ SSL properties may be interpreted by the unixsocket-secure
module to indicate secure HTTPS traffic. Typically this
is an alternate to the forwarded module.
+[Tags]
+connector
+
[depend]
unixsocket
diff --git a/jetty-unixsocket/src/main/config/modules/unixsocket-secure.mod b/jetty-unixsocket/src/main/config/modules/unixsocket-secure.mod
index 43344706038..8d099b539fa 100644
--- a/jetty-unixsocket/src/main/config/modules/unixsocket-secure.mod
+++ b/jetty-unixsocket/src/main/config/modules/unixsocket-secure.mod
@@ -5,6 +5,9 @@ This looks for a secure scheme transported either by the
unixsocket-forwarded, unixsocket-proxy-protocol or in a
HTTP2 request.
+[Tags]
+connector
+
[depend]
unixsocket-http
diff --git a/jetty-unixsocket/src/main/config/modules/unixsocket.mod b/jetty-unixsocket/src/main/config/modules/unixsocket.mod
index c27ec9d2f43..f4defea923c 100644
--- a/jetty-unixsocket/src/main/config/modules/unixsocket.mod
+++ b/jetty-unixsocket/src/main/config/modules/unixsocket.mod
@@ -7,6 +7,9 @@ needless fragmentation and have better dispatch behaviours.
When enabled with corresponding support modules, the connector can
accept HTTP, HTTPS or HTTP2C traffic.
+[Tags]
+connector
+
[depend]
server
diff --git a/jetty-util/src/main/config/modules/jcl-slf4j.mod b/jetty-util/src/main/config/modules/jcl-slf4j.mod
index bc5ebfbbf03..34c9daf7cfd 100644
--- a/jetty-util/src/main/config/modules/jcl-slf4j.mod
+++ b/jetty-util/src/main/config/modules/jcl-slf4j.mod
@@ -2,6 +2,12 @@
Provides a Java Commons Logging implementation that logs to the SLF4J API.
Requires another module that provides and SLF4J implementation.
+[tags]
+logging
+jcl
+slf4j
+verbose
+
[depends]
slf4j-api
diff --git a/jetty-util/src/main/config/modules/jcl.mod b/jetty-util/src/main/config/modules/jcl.mod
index c72533a6c40..b3f0240ce3b 100644
--- a/jetty-util/src/main/config/modules/jcl.mod
+++ b/jetty-util/src/main/config/modules/jcl.mod
@@ -2,6 +2,11 @@
Provides a Java Commons Logging implementation.
To receive jetty logs the jetty-slf4j and slf4j-jcl must also be enabled.
+[tags]
+logging
+jcl
+verbose
+
[depends]
[provides]
diff --git a/jetty-util/src/main/config/modules/jetty-jul.mod b/jetty-util/src/main/config/modules/jetty-jul.mod
index ed7340af74c..78b91462799 100644
--- a/jetty-util/src/main/config/modules/jetty-jul.mod
+++ b/jetty-util/src/main/config/modules/jetty-jul.mod
@@ -2,6 +2,9 @@
Provides a Jetty Logging implementation that logs to the Java Util Logging API.
Requires another module that provides a Java Util Logging implementation.
+[tags]
+logging
+
[provide]
logging
diff --git a/jetty-util/src/main/config/modules/jetty-log4j.mod b/jetty-util/src/main/config/modules/jetty-log4j.mod
index 7717400b784..7b22d0e39ca 100644
--- a/jetty-util/src/main/config/modules/jetty-log4j.mod
+++ b/jetty-util/src/main/config/modules/jetty-log4j.mod
@@ -3,6 +3,10 @@ Provides a Jetty Logging implementation that logs to the log4j API.
Uses the slf4j mechanism as an intermediary
Requires another module that provides an log4j implementation.
+[tags]
+logging
+log4j
+
[depend]
jetty-slf4j
slf4j-log4j
diff --git a/jetty-util/src/main/config/modules/jetty-log4j2.mod b/jetty-util/src/main/config/modules/jetty-log4j2.mod
index c77ca46b8ba..045d639adc3 100644
--- a/jetty-util/src/main/config/modules/jetty-log4j2.mod
+++ b/jetty-util/src/main/config/modules/jetty-log4j2.mod
@@ -3,6 +3,11 @@ Provides a Jetty Logging implementation that logs to the log4j API.
Uses the slf4j and log4j v1.2 mechanisms as intermediaries.
Requires another module that provides an log4j2 implementation.
+[tags]
+logging
+log4j2
+log4j
+
[depend]
jetty-slf4j
slf4j-log4j2
diff --git a/jetty-util/src/main/config/modules/jetty-logback.mod b/jetty-util/src/main/config/modules/jetty-logback.mod
index e5373fd5301..0d6b1ce57c5 100644
--- a/jetty-util/src/main/config/modules/jetty-logback.mod
+++ b/jetty-util/src/main/config/modules/jetty-logback.mod
@@ -2,6 +2,9 @@
Provides a Jetty Logging implementation that logs to logback.
Uses the slf4j API as an intermediary
+[tags]
+logging
+
[depend]
jetty-slf4j
slf4j-logback
diff --git a/jetty-util/src/main/config/modules/jetty-logging.mod b/jetty-util/src/main/config/modules/jetty-logging.mod
index 3b46e5954ca..fcb4c749c22 100644
--- a/jetty-util/src/main/config/modules/jetty-logging.mod
+++ b/jetty-util/src/main/config/modules/jetty-logging.mod
@@ -2,6 +2,9 @@
Enables the Jetty Logging implementation and installs a template
configuration in ${jetty.base} resources/jetty-logging.properties.
+[tags]
+logging
+
[depends]
resources
diff --git a/jetty-util/src/main/config/modules/jetty-slf4j.mod b/jetty-util/src/main/config/modules/jetty-slf4j.mod
index 3836363748d..b0d68ed509a 100644
--- a/jetty-util/src/main/config/modules/jetty-slf4j.mod
+++ b/jetty-util/src/main/config/modules/jetty-slf4j.mod
@@ -2,6 +2,10 @@
Provides a Jetty Logging implementation that logs to the SLF4J API.
Requires another module that provides and SLF4J implementation.
+[tags]
+logging
+slf4j
+
[depend]
slf4j-api
slf4j-impl
diff --git a/jetty-util/src/main/config/modules/log4j-log4j2.mod b/jetty-util/src/main/config/modules/log4j-log4j2.mod
index 7a055ee07e1..63861d5b6a1 100644
--- a/jetty-util/src/main/config/modules/log4j-log4j2.mod
+++ b/jetty-util/src/main/config/modules/log4j-log4j2.mod
@@ -3,6 +3,12 @@ Provides a Log4j v1.2 implementation that logs to the Log4j v2 API.
Requires another module that provides and Log4j v2 implementation.
To receive jetty logs the jetty-slf4j and slf4j-log4j must also be enabled.
+[tags]
+logging
+log4j2
+log4j
+verbose
+
[depends]
log4j2-api
log4j2-impl
diff --git a/jetty-util/src/main/config/modules/log4j.mod b/jetty-util/src/main/config/modules/log4j.mod
index 437a297afaa..17e3ed8a639 100644
--- a/jetty-util/src/main/config/modules/log4j.mod
+++ b/jetty-util/src/main/config/modules/log4j.mod
@@ -2,6 +2,11 @@
Provides a Log4j v1.2 API and implementation.
To receive jetty logs enable the jetty-slf4j and slf4j-log4j modules.
+[tags]
+logging
+log4j
+verbose
+
[depends]
resources
diff --git a/jetty-util/src/main/config/modules/log4j2-api.mod b/jetty-util/src/main/config/modules/log4j2-api.mod
index 3244acf19f0..3b1ce7dee76 100644
--- a/jetty-util/src/main/config/modules/log4j2-api.mod
+++ b/jetty-util/src/main/config/modules/log4j2-api.mod
@@ -3,6 +3,12 @@ Provides the Log4j v2 API
Requires another module that provides an Log4j v2 implementation.
To receive jetty logs enable the jetty-slf4j, slf4j-log4j and log4j-log4j2 modules.
+[tags]
+logging
+log4j2
+log4j
+verbose
+
[files]
maven://org.apache.logging.log4j/log4j-api/${log4j2.version}|lib/log4j/log4j-api-${log4j2.version}.jar
diff --git a/jetty-util/src/main/config/modules/log4j2-core.mod b/jetty-util/src/main/config/modules/log4j2-core.mod
index 9b04f2013ad..599215067c0 100644
--- a/jetty-util/src/main/config/modules/log4j2-core.mod
+++ b/jetty-util/src/main/config/modules/log4j2-core.mod
@@ -2,6 +2,12 @@
Provides a Log4j v2 implementation.
To receive jetty logs enable the jetty-slf4j, slf4j-log4j and log4j-log4j2 modules.
+[tags]
+logging
+log4j2
+log4j
+verbose
+
[depends]
log4j2-api
resources
diff --git a/jetty-util/src/main/config/modules/log4j2-slf4j.mod b/jetty-util/src/main/config/modules/log4j2-slf4j.mod
index 6324c0d37d4..0dad0102f2f 100644
--- a/jetty-util/src/main/config/modules/log4j2-slf4j.mod
+++ b/jetty-util/src/main/config/modules/log4j2-slf4j.mod
@@ -3,6 +3,13 @@ Provides a Log4j v2 implementation that logs to the SLF4J API.
Requires another module that provides and SLF4J implementation.
To receive jetty logs enable the jetty-slf4j module.
+[tags]
+logging
+log4j2
+log4j
+slf4j
+verbose
+
[depends]
log4j2-api
slf4j-api
diff --git a/jetty-util/src/main/config/modules/logback-core.mod b/jetty-util/src/main/config/modules/logback-core.mod
index fa2832bd52c..ab2d9cea0ca 100644
--- a/jetty-util/src/main/config/modules/logback-core.mod
+++ b/jetty-util/src/main/config/modules/logback-core.mod
@@ -2,6 +2,10 @@
Provides the logback core implementation, used by slf4j-logback
and logback-access
+[tags]
+logging
+verbose
+
[files]
maven://ch.qos.logback/logback-core/${logback.version}|lib/logback/logback-core-${logback.version}.jar
diff --git a/jetty-util/src/main/config/modules/slf4j-api.mod b/jetty-util/src/main/config/modules/slf4j-api.mod
index b4eda7f19f8..a20b67e9b42 100644
--- a/jetty-util/src/main/config/modules/slf4j-api.mod
+++ b/jetty-util/src/main/config/modules/slf4j-api.mod
@@ -2,6 +2,11 @@
Provides SLF4J API. Requires a slf4j implementation (eg slf4j-simple)
otherwise a noop implementation is used.
+[tags]
+logging
+slf4j
+verbose
+
[files]
maven://org.slf4j/slf4j-api/${slf4j.version}|lib/slf4j/slf4j-api-${slf4j.version}.jar
diff --git a/jetty-util/src/main/config/modules/slf4j-jcl.mod b/jetty-util/src/main/config/modules/slf4j-jcl.mod
index 6a9773a048c..9d7f3949fb9 100644
--- a/jetty-util/src/main/config/modules/slf4j-jcl.mod
+++ b/jetty-util/src/main/config/modules/slf4j-jcl.mod
@@ -3,6 +3,12 @@ Provides a SLF4J implementation that logs to the Java Commons Logging API.
Requires another module that provides an JCL implementation.
To receive jetty logs enable the jetty-slf4j module.
+[tags]
+logging
+jcl
+slf4j
+verbose
+
[depend]
slf4j-api
jcl-api
diff --git a/jetty-util/src/main/config/modules/slf4j-jul.mod b/jetty-util/src/main/config/modules/slf4j-jul.mod
index fc858778d2f..b277a2ed065 100644
--- a/jetty-util/src/main/config/modules/slf4j-jul.mod
+++ b/jetty-util/src/main/config/modules/slf4j-jul.mod
@@ -2,6 +2,11 @@
Provides a SLF4J implementation that logs to the Java Util Logging API.
To receive jetty logs enable the jetty-slf4j module.
+[tags]
+logging
+slf4j
+verbose
+
[depend]
slf4j-api
diff --git a/jetty-util/src/main/config/modules/slf4j-log4j.mod b/jetty-util/src/main/config/modules/slf4j-log4j.mod
index 75c98577d02..fffa7b61d23 100644
--- a/jetty-util/src/main/config/modules/slf4j-log4j.mod
+++ b/jetty-util/src/main/config/modules/slf4j-log4j.mod
@@ -3,6 +3,12 @@ Provides a SLF4J implementation that logs to the Log4j v1.2 API.
Requires another module that provides a Log4j implementation.
To receive jetty logs enable the jetty-slf4j module.
+[tags]
+logging
+log4j
+slf4j
+verbose
+
[depend]
slf4j-api
log4j-api
diff --git a/jetty-util/src/main/config/modules/slf4j-log4j2.mod b/jetty-util/src/main/config/modules/slf4j-log4j2.mod
index 2f9d023059e..57ee3affd87 100644
--- a/jetty-util/src/main/config/modules/slf4j-log4j2.mod
+++ b/jetty-util/src/main/config/modules/slf4j-log4j2.mod
@@ -3,6 +3,13 @@ Provides a SLF4J implementation that logs to the Log4j v2 API.
Requires another module that provides a Log4j2 implementation.
To receive jetty logs enable the jetty-slf4j2 module.
+[tags]
+logging
+log4j2
+log4j
+slf4j
+verbose
+
[depend]
slf4j-api
log4j2-api
diff --git a/jetty-util/src/main/config/modules/slf4j-logback.mod b/jetty-util/src/main/config/modules/slf4j-logback.mod
index 0a23efdad13..185096b24aa 100644
--- a/jetty-util/src/main/config/modules/slf4j-logback.mod
+++ b/jetty-util/src/main/config/modules/slf4j-logback.mod
@@ -2,6 +2,11 @@
Provides a SLF4J implementation that logs to Logback classic
To receive jetty logs enable the jetty-slf4j module.
+[tags]
+logging
+slf4j
+verbose
+
[depend]
slf4j-api
logback-core
diff --git a/jetty-util/src/main/config/modules/slf4j-simple.mod b/jetty-util/src/main/config/modules/slf4j-simple.mod
index 804cde01a03..8fab77cc1f4 100644
--- a/jetty-util/src/main/config/modules/slf4j-simple.mod
+++ b/jetty-util/src/main/config/modules/slf4j-simple.mod
@@ -2,6 +2,11 @@
Provides SLF4J simple logging implementation.
To receive jetty logs enable the jetty-slf4j module.
+[tags]
+logging
+slf4j
+verbose
+
[depend]
slf4j-api
diff --git a/jetty-util/src/main/config/modules/stderrout-logging.mod b/jetty-util/src/main/config/modules/stderrout-logging.mod
index 846f2dabd84..77952ac54f9 100644
--- a/jetty-util/src/main/config/modules/stderrout-logging.mod
+++ b/jetty-util/src/main/config/modules/stderrout-logging.mod
@@ -2,6 +2,9 @@
Redirects JVMs stderr and stdout to a log file,
including output from Jetty's default StdErrLog logging.
+[tags]
+logging
+
[xml]
etc/stderrout-logging.xml