-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'jetty-12.1.x' into fix/jetty-12.1.x/errorDispatch
- Loading branch information
Showing
153 changed files
with
30,312 additions
and
91 deletions.
There are no files selected for viewing
31 changes: 31 additions & 0 deletions
31
...mentation/src/main/asciidoc/operations-guide/modules/module-state-tracking.adoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
// | ||
// ======================================================================== | ||
// Copyright (c) 1995 Mort Bay Consulting Pty Ltd and others. | ||
// | ||
// This program and the accompanying materials are made available under the | ||
// terms of the Eclipse Public License v. 2.0 which is available at | ||
// https://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0 | ||
// which is available at https://www.apache.org/licenses/LICENSE-2.0. | ||
// | ||
// SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 | ||
// ======================================================================== | ||
// | ||
|
||
[[og-module-state-tracking]] | ||
===== Module `state-tracking` | ||
|
||
The `state-tracking` Jetty module inserts the `StateTrackingHandler` at the beginning of the Handler chain. | ||
|
||
`StateTrackingHandler` is a xref:og-troubleshooting[troubleshooting] `Handler` that tracks usages of `Handler`/`Request`/`Response` asynchronous APIs, and logs at warning level invalid usages of the APIs that may lead to blockages, deadlocks, or missing completion of ``Callback``s. | ||
|
||
This module can be enabled to troubleshoot web applications that do not behave as expected, for example: | ||
|
||
* That consume a lot of threads (possibly because they block). | ||
* That do not send responses (or send only partial responses) to clients. | ||
* That timeout when apparently they have received or have sent all data. | ||
|
||
The module properties are: | ||
|
||
---- | ||
include::{jetty-home}/modules/state-tracking.mod[tags=documentation] | ||
---- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
...rc/main/asciidoc/operations-guide/troubleshooting/troubleshooting-handlers.adoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// | ||
// ======================================================================== | ||
// Copyright (c) 1995 Mort Bay Consulting Pty Ltd and others. | ||
// | ||
// This program and the accompanying materials are made available under the | ||
// terms of the Eclipse Public License v. 2.0 which is available at | ||
// https://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0 | ||
// which is available at https://www.apache.org/licenses/LICENSE-2.0. | ||
// | ||
// SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 | ||
// ======================================================================== | ||
// | ||
|
||
[[og-troubleshooting-handlers]] | ||
==== Troubleshooting Handlers | ||
|
||
[[og-troubleshooting-handlers-state-tracking]] | ||
===== `StateTrackingHandler` | ||
|
||
Jetty's `StateTrackingHandler` (described in xref:og-module-state-tracking[this module]) can be used to troubleshoot problems in web applications. | ||
|
||
`StateTrackingHandler` tracks the usages of `Handler`/`Request`/`Response` asynchronous APIs by web applications, emitting events (logged at warning level) when an invalid usage of the APIs is detected. | ||
|
||
In conjunction with xref:og-troubleshooting-dump[dumping the Jetty component tree], it dumps the state of current requests, detailing whether they have reads or writes that are pending, whether callbacks have been completed, along with thread stack traces (including virtual threads) of operations that have been started but not completed, or are stuck in blocking code. | ||
|
||
You need to enable the `state-tracking` Jetty module, and configure it to track what you are interested in tracking (for more details, see the link:{javadoc-url}/org/eclipse/jetty/server/handler/StateTrackingHandler.html[javadocs]). | ||
|
||
// TODO: add a section about DebugHandler. |
Binary file added
BIN
+262 KB
...ty-documentation/src/main/asciidoc/programming-guide/images/jmc-server-dump.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/.asciidoctorconfig | ||
/provided-antora-playbook.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// | ||
// ======================================================================== | ||
// Copyright (c) 1995 Mort Bay Consulting Pty Ltd and others. | ||
// | ||
// This program and the accompanying materials are made available under the | ||
// terms of the Eclipse Public License v. 2.0 which is available at | ||
// https://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0 | ||
// which is available at https://www.apache.org/licenses/LICENSE-2.0. | ||
// | ||
// SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 | ||
// ======================================================================== | ||
// | ||
|
||
= Jetty Documentation | ||
|
||
This project is the root of the Jetty documentation. | ||
The content files in this project get sourced by the Antora playbook in the playbook repository that builds the website. | ||
|
||
In order to build the documentation locally, you first need to prepare a jetty-home directory by running the following command from the top-level folder of the Jetty project: | ||
|
||
$ mvn install -Dcollector -Pfast -am -pl documentation/jetty | ||
|
||
Then you can use the following command from this directory to prepare and run Antora using a preview profile: | ||
|
||
$ mvn antora -N | ||
|
||
If you don't run the first command, the Antora build will still succeed, but you will get warnings about missing includes for files taken from jetty-home. | ||
|
||
The `antora:antora` goal, which the `antora` lifecycle invokes, takes advantage of the playbook provider feature so the playbook for this branch can be centrally managed in the playbook repository. | ||
|
||
Note that this preview profile does not run the jetty blocks, so you will only see the configuration for those runs in the preview site. | ||
If you want to build the full site, use the build in the playbook repository. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: jetty | ||
version: '12' | ||
title: Eclipse Jetty | ||
asciidoc: | ||
attributes: | ||
javadoc-url: https://eclipse.dev/jetty/javadoc/jetty-12 | ||
jdurl: '{javadoc-url}' | ||
jetty-home: ${jetty.home}@ | ||
version: 12.0.10-SNAPSHOT | ||
idprefix: '' | ||
idseparator: '' | ||
ee-all: ee{8,9,10} | ||
ee-current: ee10 | ||
ee-current-caps: EE 10 | ||
run-jetty-classpath: ${settings.localRepository}/org/eclipse/jetty/tests/jetty-testers/${project.version}/jetty-testers-${project.version}.jar${path.separator}${run.jetty.classpath} | ||
nav: | ||
- modules/operations-guide/nav.adoc | ||
- modules/programming-guide/nav.adoc | ||
ext: | ||
collector: | ||
- run: | ||
command: mvn install -ntp -B -Dcollector -Pfast -am -pl documentation/jetty | ||
scan: | ||
dir: documentation/jetty/target/collector | ||
- scan: | ||
dir: jetty-core/jetty-server/src/main/java | ||
files: org/eclipse/jetty/server/CustomRequestLog.java | ||
base: modules/code/partials |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// | ||
// ======================================================================== | ||
// Copyright (c) 1995 Mort Bay Consulting Pty Ltd and others. | ||
// | ||
// This program and the accompanying materials are made available under the | ||
// terms of the Eclipse Public License v. 2.0 which is available at | ||
// https://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0 | ||
// which is available at https://www.apache.org/licenses/LICENSE-2.0. | ||
// | ||
// SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 | ||
// ======================================================================== | ||
// | ||
|
||
= Eclipse Jetty | ||
|
||
This section of the site contains the documentation for {page-component-title} {page-version}. | ||
|
||
== xref:operations-guide:index.adoc[] | ||
|
||
The Eclipse Jetty Operations Guide targets sysops, devops, and developers who want to install Eclipse Jetty as a standalone server to deploy web applications. | ||
|
||
== xref:programming-guide:index.adoc[] | ||
|
||
The Eclipse Jetty Programming Guide targets developers who want to use the Eclipse Jetty libraries in their applications, and advanced sysops/devops that want to customize the deployment of web applications. |
8 changes: 8 additions & 0 deletions
8
documentation/jetty/modules/code/examples/jetty-modules/jpms.mod
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
[description] | ||
JPMS Configuration Module | ||
|
||
[ini] | ||
--jpms | ||
|
||
[jpms] | ||
# Additional JPMS configuration. |
6 changes: 6 additions & 0 deletions
6
documentation/jetty/modules/code/examples/jetty-modules/jvm.mod
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[description] | ||
JVM Options Module | ||
|
||
[exec] | ||
-Xmx1g | ||
-Xlog:gc*,gc+stats=off:file=logs/gc.log:time,level,tags |
15 changes: 15 additions & 0 deletions
15
documentation/jetty/modules/code/examples/jetty-modules/postgresql.mod
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
[description] | ||
Postgres JDBC Driver Module | ||
|
||
[lib] | ||
lib/postgresql-${postgresql-version}.jar | ||
|
||
[files] | ||
maven://org.postgresql/postgresql/${postgresql-version}|lib/postgresql-${postgresql-version}.jar | ||
|
||
[ini] | ||
postgresql-version?=42.6.0 | ||
|
||
[ini-template] | ||
## Postgres JDBC version. | ||
# postgresql-version=42.6.0 |
5 changes: 5 additions & 0 deletions
5
documentation/jetty/modules/code/examples/jetty-modules/remote-debug.mod
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[description] | ||
Enables remote debugging | ||
|
||
[exec] | ||
-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005 |
Oops, something went wrong.