Skip to content

Commit

Permalink
#9145 fix ee8,ee9 and core stats modules
Browse files Browse the repository at this point in the history
Signed-off-by: Ludovic Orban <[email protected]>
  • Loading branch information
lorban committed Jan 11, 2023
1 parent 748cb42 commit 47f58d6
Show file tree
Hide file tree
Showing 5 changed files with 92 additions and 7 deletions.
7 changes: 0 additions & 7 deletions jetty-core/jetty-server/src/main/config/modules/stats.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,10 @@ server

[depend]
server
servlet

[lib]
lib/jetty-util-ajax-${jetty.version}.jar

[xml]
etc/jetty-stats.xml

[ini]
jetty.webapp.addServerClasses+=,-org.eclipse.jetty.ee9.servlet.StatisticsServlet

[ini-template]

## If the Graceful shutdown should wait for async requests as well as the currently dispatched ones.
Expand Down
21 changes: 21 additions & 0 deletions jetty-ee8/jetty-ee8-nested/src/main/config/etc/ee8-jetty-stats.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?xml version="1.0"?>
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "https://www.eclipse.org/jetty/configure_10_0.dtd">

<!-- =============================================================== -->
<!-- Mixin the Statistics Handler -->
<!-- =============================================================== -->

<Configure id="Server" class="org.eclipse.jetty.server.Server">
<Call name="insertHandler">
<Arg>
<New id="StatsHandler" class="org.eclipse.jetty.ee8.nested.StatisticsHandler">
<Set name="gracefulShutdownWaitsForRequests"><Property name="jetty.statistics.gracefulShutdownWaitsForRequests" default="true"/></Set>
</New>
</Arg>
</Call>
<Call name="addBeanToAllConnectors">
<Arg>
<New class="org.eclipse.jetty.io.ConnectionStatistics"/>
</Arg>
</Call>
</Configure>
25 changes: 25 additions & 0 deletions jetty-ee8/jetty-ee8-nested/src/main/config/modules/ee8-stats.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# DO NOT EDIT - See: https://www.eclipse.org/jetty/documentation/current/startup-modules.html

[description]
Enables detailed statistics collection for the server.

[environment]
ee8

[depend]
server
ee8-servlet

[lib]
lib/jetty-util-ajax-${jetty.version}.jar

[xml]
etc/ee8-jetty-stats.xml

[ini]
jetty.webapp.addServerClasses+=,-org.eclipse.jetty.ee8.servlet.StatisticsServlet

[ini-template]

## If the Graceful shutdown should wait for async requests as well as the currently dispatched ones.
# jetty.statistics.gracefulShutdownWaitsForRequests=true
21 changes: 21 additions & 0 deletions jetty-ee9/jetty-ee9-nested/src/main/config/etc/ee9-jetty-stats.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?xml version="1.0"?>
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "https://www.eclipse.org/jetty/configure_10_0.dtd">

<!-- =============================================================== -->
<!-- Mixin the Statistics Handler -->
<!-- =============================================================== -->

<Configure id="Server" class="org.eclipse.jetty.server.Server">
<Call name="insertHandler">
<Arg>
<New id="StatsHandler" class="org.eclipse.jetty.ee9.nested.StatisticsHandler">
<Set name="gracefulShutdownWaitsForRequests"><Property name="jetty.statistics.gracefulShutdownWaitsForRequests" default="true"/></Set>
</New>
</Arg>
</Call>
<Call name="addBeanToAllConnectors">
<Arg>
<New class="org.eclipse.jetty.io.ConnectionStatistics"/>
</Arg>
</Call>
</Configure>
25 changes: 25 additions & 0 deletions jetty-ee9/jetty-ee9-nested/src/main/config/modules/ee9-stats.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# DO NOT EDIT - See: https://www.eclipse.org/jetty/documentation/current/startup-modules.html

[description]
Enables detailed statistics collection for the server.

[environment]
ee9

[depend]
server
ee9-servlet

[lib]
lib/jetty-util-ajax-${jetty.version}.jar

[xml]
etc/ee9-jetty-stats.xml

[ini]
jetty.webapp.addServerClasses+=,-org.eclipse.jetty.ee9.servlet.StatisticsServlet

[ini-template]

## If the Graceful shutdown should wait for async requests as well as the currently dispatched ones.
# jetty.statistics.gracefulShutdownWaitsForRequests=true

0 comments on commit 47f58d6

Please sign in to comment.