Skip to content

test: use Jetty EMBED for IDE debugging, FORK for CI#23416

Merged
mcollovati merged 3 commits into
mainfrom
spikes/jetty-12.1.6-fork-mode
Mar 12, 2026
Merged

test: use Jetty EMBED for IDE debugging, FORK for CI#23416
mcollovati merged 3 commits into
mainfrom
spikes/jetty-12.1.6-fork-mode

Conversation

@mcollovati

@mcollovati mcollovati commented Feb 5, 2026

Copy link
Copy Markdown
Collaborator

Jetty uses SLF4J 2.x fluent logging APIs (e.g., atDebug()) that
are not available in the legacy SLF4J 1.x implementation provided by
Maven's classloader. This can potentially cause NoSuchMethodError
when running Jetty in EMBED mode.

See jetty/jetty.project#14435

FORK mode isolates Jetty in a separate JVM with its own classloader,
avoiding the conflict between Maven's legacy SLF4J and Jetty's SLF4J 2.x
requirements.

This change moves FORK-specific Jetty config (deployMode, jvmArgs,
maxChildStartChecks, maxChildStartCheckMs) from plugin-level
configuration to the start-jetty execution only. This way
mvn jetty:run uses EMBED mode (debuggable from IDE), while
mvn verify still uses FORK mode (avoids SLF4J classloader conflict).

@github-actions github-actions Bot added the +0.0.1 label Feb 5, 2026
@github-actions

github-actions Bot commented Feb 5, 2026

Copy link
Copy Markdown

Test Results

 1 382 files  ±0   1 382 suites  ±0   1h 28m 49s ⏱️ + 2m 32s
 9 903 tests ±0   9 832 ✅ ±0  71 💤 ±0  0 ❌ ±0 
10 376 runs  ±0  10 296 ✅ ±0  80 💤 ±0  0 ❌ ±0 

Results for commit ecdb697. ± Comparison against base commit 84c7e12.

♻️ This comment has been updated with latest results.

@sonarqubecloud

sonarqubecloud Bot commented Feb 6, 2026

Copy link
Copy Markdown

Jetty uses SLF4J 2.x fluent logging APIs (e.g., `atDebug()`) that
are not available in the legacy SLF4J 1.x implementation provided by
Maven's classloader. This can potentially cause `NoSuchMethodError`
when running Jetty in EMBED mode.

See jetty/jetty.project#14435

FORK mode isolates Jetty in a separate JVM with its own classloader,
avoiding the conflict between Maven's legacy SLF4J and Jetty's SLF4J 2.x
requirements.

This change moves FORK-specific Jetty config (`deployMode`, `jvmArgs`,
`maxChildStartChecks`, `maxChildStartCheckMs`) from plugin-level
configuration to the `start-jetty` execution only. This way
`mvn jetty:run` uses EMBED mode (debuggable from IDE), while
`mvn verify` still uses FORK mode (avoids SLF4J classloader conflict).
@mcollovati mcollovati force-pushed the spikes/jetty-12.1.6-fork-mode branch from 2d8fe4f to c819c76 Compare March 10, 2026 15:46
@mcollovati mcollovati changed the title test: configure FORK mode for Jetty Maven plugin test: use Jetty EMBED for IDE debugging, FORK for CI Mar 10, 2026
@mcollovati mcollovati marked this pull request as ready for review March 10, 2026 15:47
Comment thread pom.xml Outdated
Comment thread pom.xml Outdated
@github-actions github-actions Bot added +1.0.0 and removed +0.0.1 labels Mar 12, 2026
@github-actions github-actions Bot added +0.0.1 and removed +1.0.0 labels Mar 12, 2026
@sonarqubecloud

Copy link
Copy Markdown

@mcollovati mcollovati enabled auto-merge (squash) March 12, 2026 16:31
@mcollovati mcollovati merged commit 6a63221 into main Mar 12, 2026
49 of 51 checks passed
@mcollovati mcollovati deleted the spikes/jetty-12.1.6-fork-mode branch March 12, 2026 16:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants