Skip to content

RC-356 Extract Jetty incremental analysis into plugin integration tests - #6298

Draft
romainbrenguier wants to merge 8 commits into
masterfrom
romain/rc-356-extract-incremental-analysis
Draft

romainbrenguier wants to merge 8 commits into
masterfrom
romain/rc-356-extract-incremental-analysis

Conversation

@romainbrenguier

@romainbrenguier romainbrenguier commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Extract Eclipse Jetty main-branch / large-PR / small-PR cache-reuse and timing checks into a dedicated IncrementalAnalysisTest in its/plugin/tests.
  • Keep the existing cache thresholds (50% for the large PR, 90% for the small PR) and relative timing assertions, aggregating cache counts across all Jetty modules.
  • Use an isolated Enterprise Edition Orchestrator and the built-in Sonar way profile for the incremental integration scenario; honor communityEditionTestsOnly without starting a server.
  • Retain all three Jetty issue-baseline comparisons in JavaRulingTest.eclipse_jetty, with caching and unchanged-file skipping disabled. Fixtures and expected baselines stay in their existing locations.
  • Document the distinction between plugin incremental integration coverage and ruling baseline coverage.

This branch is based directly on master and does not include the RC-442 changes.

Validation

  • PASS: mvn -o -pl its/plugin/tests,its/ruling -am test-compile -DskipTests -Ddownload.skip=true -Dcheckstyle.skip=true -Dlicense.skip=true -Dspotless.skip=true
  • PASS: mvn -o -pl its/plugin/tests -am test -Pit-plugin -Dtest=IncrementalAnalysisTest -Dsurefire.failIfNoSpecifiedTests=false -DcommunityEditionTestsOnly=true -Ddownload.skip=true -Dcheckstyle.skip=true -Dlicense.skip=true -Dspotless.skip=true (test discovery and Community Edition guard only).
  • PASS: git diff --check.
  • Full Enterprise Edition incremental analysis and ruling execution are left to CI; ruling tests were not run locally.
  • Deep Vortex analysis found no issues in the new test or changed lines. It reported these pre-existing findings on untouched lines in its/ruling/src/test/java/org/sonar/java/it/JavaRulingTest.java:
[1] line 419  Format specifiers should be used instead of string concatenation.  java:S3457
[2] line 420  Format specifiers should be used instead of string concatenation.  java:S3457
[3] line 421  Format specifiers should be used instead of string concatenation.  java:S3457

Summary by Gitar

  • CI workflow:
    • ruling-update-notify now runs when ruling-qa succeeds or fails, and flags ruling failure only on a failure result
  • Ruling baselines:
    • Refreshed eclipse-jetty-similar-to-main expected baselines and added new ruling expected files
  • Ruling error collection:
    • Added ErrorCollector so all three Jetty comparisons run and report failures together

This will update automatically on new commits.

Agent workflow

Tool link: https://github.com/SonarSource/languages-experimental-tooling/tree/romain/my-tickets/personal/romain-brenguier
PR updated using uv run update_with_claude.py --prompt "Implement the action plan described in the document Rebase on origin master fixing conflicts.." -a "Rebase on origin master fixing conflicts." -g "claude"

@hashicorp-vault-sonar-prod

hashicorp-vault-sonar-prod Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

RC-356

@datadog-sonarsource

datadog-sonarsource Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

Pipelines

❌ Errors

Your PR has failed checks. Please review the issues below and take necessary action before merging.

🚦 2 Pipeline jobs failed

Build | Ruling QA (warp-custom-ubuntu-24-04, without-sonarqube-project, LATEST_RELEASE)

View more details · View in GitHub Actions

Build | Ruling QA (warp-custom-windows-2022-l, without-sonarqube-project, LATEST_RELEASE)

View more details · View in GitHub Actions

Useful? React with 👍 / 👎

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 0403eb3 | Docs | View more details | Give us feedback!

Comment thread its/ruling/src/test/java/org/sonar/java/it/JavaRulingTest.java
@github-actions

Copy link
Copy Markdown
Contributor

⚖️ Ruling update ready for review: #6325

@github-actions

github-actions Bot commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Ruling Diff Summary

Detected changes in 8 rule files: 34 issues removed, 194 issues added.

S9434 (java) on eclipse-jetty-similar-to-main - 3 issues removed, 8 issues added

Added jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 371)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Added jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 380)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/HttpChannel.java (line 370)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/HttpChannel.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java (line 410)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java (line 411)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java (line 412)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/ssl/SslSelectionDump.java (line 46)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/ssl/SslSelectionDump.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/thread/ScheduledExecutorScheduler.java (line 99)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/thread/ScheduledExecutorScheduler.java)

Removed jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 371)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Removed jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 380)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Removed jetty-server/src/main/java/org/eclipse/jetty/server/HttpChannel.java (line 370)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/HttpChannel.java)
S9436 (java) on eclipse-jetty-similar-to-main - 1 issues removed, 1 issues added

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java (line 207)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java)

Removed jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java (line 207)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java)
S9438 (java) on eclipse-jetty-similar-to-main - 17 issues removed, 34 issues added

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpCookie.java (line 60)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpCookie.java)

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java (line 171)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java)

Added jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 124)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java (line 59)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java (line 496)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/MultiPartParser.java (line 82)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/MultiPartParser.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/DebugHandler.java (line 46)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/DebugHandler.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/InetAccessSet.java (line 35)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/InetAccessSet.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/ThreadLimitHandler.java (line 335)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/ThreadLimitHandler.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java (line 36)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java (line 38)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java (line 39)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionHandler.java (line 1067)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionHandler.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java (line 30)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java (line 31)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java)
S9439 (java) on eclipse-jetty-similar-to-main - 13 issues removed, 54 issues added

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java (line 50)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java)

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java (line 821)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java (line 374)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java (line 379)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java (line 748)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/pathmap/UriTemplatePathSpecBadSpecsTest.java (line 36)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/pathmap/UriTemplatePathSpecBadSpecsTest.java)

Added jetty-io/src/main/java/org/eclipse/jetty/io/WriteFlusher.java (line 50)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/WriteFlusher.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/ProxyConnectionFactory.java (line 374)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/ProxyConnectionFactory.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpOutputInterceptor.java (line 47)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpOutputInterceptor.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/HttpChannelEventTest.java (line 111)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/HttpChannelEventTest.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java (line 598)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java (line 630)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/MultiPartParserTest.java (line 477)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/MultiPartParserTest.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java (line 124)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java (line 125)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java)
S9434 (java) on eclipse-jetty-similar-to-main-small - 0 issues removed, 8 issues added - new ruling file

Added jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 371)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Added jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 380)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/HttpChannel.java (line 370)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/HttpChannel.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java (line 410)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java (line 411)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java (line 412)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/ssl/SslSelectionDump.java (line 46)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/ssl/SslSelectionDump.java)

Added jetty-util/src/main/java/org/eclipse/jetty/util/thread/ScheduledExecutorScheduler.java (line 99)

(source file not found at this revision: jetty-util/src/main/java/org/eclipse/jetty/util/thread/ScheduledExecutorScheduler.java)
S9436 (java) on eclipse-jetty-similar-to-main-small - 0 issues removed, 1 issues added - new ruling file

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java (line 207)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java)
S9438 (java) on eclipse-jetty-similar-to-main-small - 0 issues removed, 34 issues added - new ruling file

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpCookie.java (line 60)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpCookie.java)

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java (line 171)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java)

Added jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java (line 124)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java (line 59)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java (line 496)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/LowResourceMonitor.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/MultiPartParser.java (line 82)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/MultiPartParser.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/DebugHandler.java (line 46)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/DebugHandler.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/InetAccessSet.java (line 35)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/InetAccessSet.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/ThreadLimitHandler.java (line 335)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/ThreadLimitHandler.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java (line 36)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java (line 38)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java (line 39)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionContext.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionHandler.java (line 1067)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionHandler.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java (line 30)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java (line 31)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/session/UnreadableSessionDataException.java)
S9439 (java) on eclipse-jetty-similar-to-main-small - 0 issues removed, 54 issues added - new ruling file

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java (line 50)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java)

Added jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java (line 821)

(source file not found at this revision: jetty-http/src/main/java/org/eclipse/jetty/http/HttpGenerator.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java (line 374)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java (line 379)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java (line 748)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/HttpParserTest.java)

Added jetty-http/src/test/java/org/eclipse/jetty/http/pathmap/UriTemplatePathSpecBadSpecsTest.java (line 36)

(source file not found at this revision: jetty-http/src/test/java/org/eclipse/jetty/http/pathmap/UriTemplatePathSpecBadSpecsTest.java)

Added jetty-io/src/main/java/org/eclipse/jetty/io/WriteFlusher.java (line 50)

(source file not found at this revision: jetty-io/src/main/java/org/eclipse/jetty/io/WriteFlusher.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/ProxyConnectionFactory.java (line 374)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/ProxyConnectionFactory.java)

Added jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpOutputInterceptor.java (line 47)

(source file not found at this revision: jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip/GzipHttpOutputInterceptor.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/HttpChannelEventTest.java (line 111)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/HttpChannelEventTest.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java (line 598)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java (line 630)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/HttpServerTestBase.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/MultiPartParserTest.java (line 477)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/MultiPartParserTest.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java (line 124)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java)

Added jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java (line 125)

(source file not found at this revision: jetty-server/src/test/java/org/eclipse/jetty/server/ProxyProtocolTest.java)

@github-actions

Copy link
Copy Markdown
Contributor

⚖️ Ruling update ready for review: #6325

@romainbrenguier
romainbrenguier force-pushed the romain/rc-356-extract-incremental-analysis branch from fc08a49 to e37fa35 Compare October 13, 2026 08:39
@romainbrenguier

Copy link
Copy Markdown
Contributor Author

RC-356 ruling audit: the large added-issue diff is the intentional conversion of the two Jetty PR corpora from PR-only dumps into independent full ruling scans, not an analyzer change. The ruling_java submodules explicitly use eclipse-jetty-same-issues-as-main and eclipse-jetty-same-issues-as-main-small; their full scans should match the main corpus. All three baselines contain 273 rule files / 39,264 issues and have been validated for unique JSON component keys, valid LITS lines (including project-level line 0), and the correct corpus project prefix. The rebase now provisions each full-scan corpus with its own key and preserves master’s RC-442 naming. Current-head ruling CI is the remaining end-to-end confirmation.

Auto-created #6325 is already CLOSED and unmerged. It is not a valid update to apply: its files are under its/ruling/src/test/resources// rather than the expected// root, and its old project keys predate the rebase. I have not merged or imported it. #6298 remains draft.

@sonarqube-next

Copy link
Copy Markdown
Contributor

@github-actions

Copy link
Copy Markdown
Contributor

This PR is stale because it has been open 7 days with no activity. If there is no activity in the next 7 days it will be closed automatically

@github-actions github-actions Bot added the stale label Oct 21, 2026
@romainbrenguier
romainbrenguier force-pushed the romain/rc-356-extract-incremental-analysis branch from cf9c7af to 319115d Compare October 26, 2026 15:20
@romainbrenguier
romainbrenguier force-pushed the romain/rc-356-extract-incremental-analysis branch from 319115d to 0403eb3 Compare October 26, 2026 15:21
@gitar-bot

gitar-bot Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
CI failed: Ruling QA for the Jetty incremental-analysis change failed on Windows: Sonar Maven reported 23 expected Jetty files not analyzed, and a separate ruling test reported 97 issue differences. Whether this PR caused it is unclear; the Linux job only generated a diff report without a shown failure.

Overview

Two unique error templates were analyzed across 8 logs. The Windows Ruling QA job shows a concrete test failure (expected files not analyzed, 97 issue differences), while the Linux Ruling QA excerpt only shows a diff report generation step with no explicit failing check. Neither finding establishes that this PR's changes caused the failure.

Failures

Jetty ruling test failure: expected files not analyzed and 97 issue differences (confidence: medium)

  • Type: test
  • Affected jobs: 121665190029
  • Related to change: unclear
  • Root cause: The sonar-maven-plugin goal failed with "Files listed in Expected directory were not analyzed" for 23 eclipse-jetty files (jetty-server, jetty-io, jetty-http). A separate JavaRulingTest.eclipse_jetty run failed with "Issues differences: 97". The subsequent skipped reactor modules are a consequence of the Maven goal failure. The excerpt does not show which expected files were missing from analysis or which issue baselines changed, so causation cannot be confirmed.
  • Suggested fix: Compare the actual Jetty analysis inputs under its/sources/eclipse-jetty-similar-to-main against the expected directory (its/ruling/src/test/resources/expected/eclipse-jetty-similar-to-main*). Make sure the analyzed file set matches the expected entries; remove stale expected entries only if those files are intentionally out of scope. Update expected issue baselines for the 97 differences only after confirming the actual results are intended.

Linux Ruling QA diff report with no shown failure (confidence: low)

  • Type: test
  • Affected jobs: 121665192632
  • Related to change: unclear
  • Root cause: The job runs diff --unified --recursive between its/ruling/src/test/resources/expected and its/ruling/target/actual, followed by || true, and uploads a diff report artifact. The excerpt contains no explicit failing test or non-zero job conclusion, and the diff contents are not shown.
  • Suggested fix: Open the uploaded diff_warp-custom-ubuntu-24-04_without-sonarqube-project artifact and the omitted test output to identify any actual failing check. If the Jetty ruling results differ from the intended baselines, update the corresponding expected JSON files under its/ruling/src/test/resources/expected.

Summary

  • Change-related failures: None confirmed. Both findings are marked unclear.
  • Infrastructure/flaky failures: None identified.
  • Recommended action: Investigate the Windows Jetty ruling mismatch first (missing analyzed files and 97 issue differences). Verify whether the expected Jetty baselines match the intended analysis scope, then review the Linux diff artifact to confirm whether it reflects a real failure.
Code Review 👍 Approved with suggestions 3 closed / 4 findings

🟡 Medium risk · Moving Jetty incremental checks into plugin tests and refreshing hundreds of ruling baselines could let incorrect analysis results pass unnoticed.

Extracts Eclipse Jetty incremental analysis cache-reuse and timing checks into a dedicated IncrementalAnalysisTest in its/plugin/tests, with Jetty baselines and CI ruling updates refreshed. Approved with suggestions: the new incremental-analysis surefire execution is not excluded when -Dtest is passed, so a targeted run like -Dtest=IncrementalAnalysisTest executes the selected class twice, once in default-test under -Dparallel=classes. Consider skipping one execution when test is set in its/plugin/tests/pom.xml. Resolved items include the missing license header, the skipUnchanged baseline mismatch, and parallel timing interference.

💡 Edge Case: -Dtest runs selected IT twice, once per surefire execution

📄 its/plugin/tests/pom.xml:121-135

The new incremental-analysis execution separates IncrementalAnalysisTest from the other tests using only <includes>/<excludes>. Surefire ignores both of those whenever -Dtest is passed (surefire test parameter), so a targeted run executes the selected class in both default-test and incremental-analysis. For example, the PR's own validation command -Dtest=IncrementalAnalysisTest runs the Jetty main-branch and PR analyses twice, and the default-test copy uses CI's -Dparallel=classes setting, which is the timing interference this change is meant to avoid. Any other -Dtest=FooTest run also executes FooTest a second time. Possible fixes: skip one execution when test is set (e.g. <skip> bound to a property), or move the incremental execution into its own profile or a property-gated execution.

Gate the dedicated execution behind a property so targeted -Dtest runs (with -DskipIncrementalAnalysis) don't execute twice
<execution>
  <id>incremental-analysis</id>
  <goals>
    <goal>test</goal>
  </goals>
  <configuration>
    <skip>${skipIncrementalAnalysis}</skip>
    <parallel>none</parallel>
    <useUnlimitedThreads>false</useUnlimitedThreads>
    <includes combine.self="override">
      <include>com/sonar/it/java/IncrementalAnalysisTest.java</include>
    </includes>
  </configuration>
</execution>
✅ 3 closed
✅ Quality: New test file is missing the SSAL license header

📄 its/plugin/tests/src/test/java/com/sonar/it/java/IncrementalAnalysisTest.java:1
Every other Java file under its/plugin/tests/src/test/java begins with the SonarQube Java / Sonar Source-Available License header (for example JspTest.java). IncrementalAnalysisTest.java starts directly with package. The PR's own validation commands passed -Dlicense.skip=true, so this was not caught. Add the standard header.

✅ Bug: Jetty PR baselines were recorded with skipUnchanged; full analysis breaks them

📄 its/ruling/src/test/java/org/sonar/java/it/JavaRulingTest.java:237-251
eclipse_jetty now analyzes eclipse-jetty-similar-to-main and eclipse-jetty-similar-to-main-small with sonar.java.skipUnchanged=false and caching off, but compares against the existing baselines. Those baselines were recorded during incremental PR analysis. expected/eclipse-jetty-similar-to-main-small has 6 rule files, all for one changed file (jetty-http/.../pathmap/AbstractPathSpec.java), totalling about 600 bytes. expected/eclipse-jetty has 273 rule files and about 890 KB. expected/eclipse-jetty-similar-to-main has 219 files. A full, non-incremental analysis of a near-copy of Jetty will report roughly the main-branch issue set, so LITS will report large differences and the ruling job will fail. This contradicts the claim that the baselines are kept unchanged. Fix: regenerate the two PR baselines from a full analysis, or drop those two comparisons, since they now duplicate the main one.

✅ Edge Case: Timing assertions run alongside other IT classes under parallel=classes

📄 its/plugin/tests/src/test/java/com/sonar/it/java/IncrementalAnalysisTest.java:75-82
Plugin QA runs mvn package -Pit-plugin -Dparallel=classes -DuseUnlimitedThreads=true. The surefire includes (suite/*TestSuite.java, SonarLintIntegrationTest.java, com/sonar/it/java/*Test.java) cover IncrementalAnalysisTest, so it runs at the same time as JavaTestSuite, JspTest and SonarLintIntegrationTest. Each of these runs its own SonarQube server and Maven analyses. The new test asserts wall-clock ratios (small PR < 0.90× main and < 0.95× large PR; large PR < 1.25× main). How much CPU and IO the other classes use during each of the three Jetty builds is uncontrolled, so these assertions will be flaky. In the ruling suite they ran sequentially. Fix: run this class on its own (separate surefire execution or job without parallel), or drop or loosen the timing checks in the plugin IT.

🤖 Prompt for agents
Code Review: Extracts Eclipse Jetty incremental analysis cache-reuse and timing checks into a dedicated `IncrementalAnalysisTest` in `its/plugin/tests`, with Jetty baselines and CI ruling updates refreshed. Approved with suggestions: the new `incremental-analysis` surefire execution is not excluded when `-Dtest` is passed, so a targeted run like `-Dtest=IncrementalAnalysisTest` executes the selected class twice, once in `default-test` under `-Dparallel=classes`. Consider skipping one execution when `test` is set in `its/plugin/tests/pom.xml`. Resolved items include the missing license header, the skipUnchanged baseline mismatch, and parallel timing interference.

1. 💡 Edge Case: -Dtest runs selected IT twice, once per surefire execution
   Files: its/plugin/tests/pom.xml:121-135

   The new `incremental-analysis` execution separates `IncrementalAnalysisTest` from the other tests using only `<includes>`/`<excludes>`. Surefire ignores both of those whenever `-Dtest` is passed ([surefire `test` parameter](https://maven.apache.org/surefire/maven-surefire-plugin/test-mojo.html#test)), so a targeted run executes the selected class in both `default-test` and `incremental-analysis`. For example, the PR's own validation command `-Dtest=IncrementalAnalysisTest` runs the Jetty main-branch and PR analyses twice, and the `default-test` copy uses CI's `-Dparallel=classes` setting, which is the timing interference this change is meant to avoid. Any other `-Dtest=FooTest` run also executes FooTest a second time. Possible fixes: skip one execution when `test` is set (e.g. `<skip>` bound to a property), or move the incremental execution into its own profile or a property-gated execution.

   Fix (Gate the dedicated execution behind a property so targeted -Dtest runs (with -DskipIncrementalAnalysis) don't execute twice):
   <execution>
     <id>incremental-analysis</id>
     <goals>
       <goal>test</goal>
     </goals>
     <configuration>
       <skip>${skipIncrementalAnalysis}</skip>
       <parallel>none</parallel>
       <useUnlimitedThreads>false</useUnlimitedThreads>
       <includes combine.self="override">
         <include>com/sonar/it/java/IncrementalAnalysisTest.java</include>
       </includes>
     </configuration>
   </execution>

Verification Rules 2/2 met Knowledge ✅ 1

Functional validation No results

Rules 2 passed 1 not applicable

✅ Internal artifact registries
✅ Repository license compliance

Knowledge ✅ 1 expectation met

Expectation met Ruling baseline project-key format expectation met

Auto-approval Not enabled

Set up

For more verification details, comment gitar display:verbose.

Tip

Comment Gitar fix CI or enable auto-apply: gitar auto-apply:on

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Showing compact verification results.

Comment with these commands to change the behavior for this request:

Auto-apply Compact
gitar auto-apply:on         
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

@sonarqube-next

Copy link
Copy Markdown
Contributor

@github-actions

Copy link
Copy Markdown
Contributor

⚖️ Ruling update ready for review: #6410

Comment thread its/plugin/tests/pom.xml
Comment on lines +121 to +135
<executions>
<execution>
<id>default-test</id>
<configuration>
<excludes>
<exclude>com/sonar/it/java/IncrementalAnalysisTest.java</exclude>
</excludes>
</configuration>
</execution>
<execution>
<id>incremental-analysis</id>
<goals>
<goal>test</goal>
</goals>
<configuration>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Edge Case: -Dtest runs selected IT twice, once per surefire execution

The new incremental-analysis execution separates IncrementalAnalysisTest from the other tests using only <includes>/<excludes>. Surefire ignores both of those whenever -Dtest is passed (surefire test parameter), so a targeted run executes the selected class in both default-test and incremental-analysis. For example, the PR's own validation command -Dtest=IncrementalAnalysisTest runs the Jetty main-branch and PR analyses twice, and the default-test copy uses CI's -Dparallel=classes setting, which is the timing interference this change is meant to avoid. Any other -Dtest=FooTest run also executes FooTest a second time. Possible fixes: skip one execution when test is set (e.g. <skip> bound to a property), or move the incremental execution into its own profile or a property-gated execution.

Gate the dedicated execution behind a property so targeted -Dtest runs (with -DskipIncrementalAnalysis) don't execute twice:

<execution>
  <id>incremental-analysis</id>
  <goals>
    <goal>test</goal>
  </goals>
  <configuration>
    <skip>${skipIncrementalAnalysis}</skip>
    <parallel>none</parallel>
    <useUnlimitedThreads>false</useUnlimitedThreads>
    <includes combine.self="override">
      <include>com/sonar/it/java/IncrementalAnalysisTest.java</include>
    </includes>
  </configuration>
</execution>
  • Apply fix

Check the box to apply the fix or reply for a change | Was this helpful? React with 👍 / 👎

@github-actions github-actions Bot removed the stale label Oct 27, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant