Skip to content

Redesign Maven console output: smart terminal, log file, structured summaries #11819

Closed as not planned

Description

@gnodet

Summary

Maven's current console output is excessively verbose and makes it hard to find relevant information. In large multi-module builds (100+ modules), users are overwhelmed with noise — plugin execution banners, download progress lines, and repetitive separators — while actual warnings and errors get buried.

This proposal redesigns Maven's default console output to be concise, informative, and modern, inspired by tools like maven-daemon (mvnd), Gradle, and Cargo.

Related Issues

Proposal

Mode 1: Smart/Rich Terminal Output (default when interactive TTY)

Using JLine (already a dependency), Maven uses a fixed-bottom status area with scrolling log above:

 ✓ my-core                                                     1.2s
 ✓ my-api                                                      0.8s
 Building my-app 2.0.0                                        [3/12]
   ✓ maven-clean-plugin:clean                                  0.1s
   ✓ maven-resources-plugin:resources                          0.3s
   ● maven-compiler-plugin:compile                             1.2s
   ↓ junit-jupiter-api-5.10.jar                          234/512 KB

────────────────────────────────────────────────────────────────────
 my-core ✓  my-api ✓  my-utils ✓  my-app ●  my-web ⏳  [5/12]  32s

Key principles:

  • Fixed status bar at the bottom showing currently building modules (parallel-aware), overall progress, elapsed time
  • Compact per-module output — module name, plugin goals completing (✓/✗), timing
  • Downloads shown inline with progress, then cleared when done
  • Warnings/errors always bubble up — never scrolled away
  • Full log written to target/build.log automatically

Mode 2: CI/Batch Output (default when CI env var set or --batch-mode)

[INFO] Building my-core 2.0.0 [1/12]
[INFO] Building my-api 2.0.0 [2/12]
[WARN] my-utils: maven-compiler-plugin: source/target 8 is deprecated
[INFO] Building my-app 2.0.0 [4/12]
[ERROR] my-app: maven-compiler-plugin:compile FAILED (1.2s)

── Build Summary ──────────────────────────────────────────────────
  my-core ..................... SUCCESS [  1.2s]
  my-api ...................... SUCCESS [  0.8s]
  my-utils .................... SUCCESS [  2.1s]  ⚠ 1 warning
  my-app ...................... FAILURE [  1.2s]

── Warnings ───────────────────────────────────────────────────────
  my-utils: source/target 8 is deprecated, use 11+

── Error ──────────────────────────────────────────────────────────
  my-app: compilation failure (3 errors)
    src/main/java/App.java:42: cannot find symbol

BUILD FAILURE  Total: 12.3s
Full log: target/build.log

Mode 3: Verbose (-X / --verbose)

Same as current Maven output — full scrolling output for debugging.

Design Choices

  1. Default to less, not more — most users only care about: what's building, did it succeed, and if not, what failed
  2. Log file by default — all [INFO]-level plugin output goes to a log file. Console shows only progress + warnings + errors
  3. Structured warnings/errors at the end — surfaces warnings that get buried in hundreds of lines ([MNG-7484] Collect warnings from different MOJO executions and give a comprehensive summary at the end of the build #8976)
  4. Parallel-aware — with parallel builds ([MNG-8071] Build in parallel by default #10872), the status bar shows multiple concurrent modules like mvnd does
  5. Progressive disclosure — mvn (concise) → mvn --verbose (full mojo output) → mvn -X (debug)

Implementation Notes

Building blocks already exist in the codebase:

  • JLine is already a dependency (maven-jline)
  • ExecutionEventLogger captures all lifecycle events
  • ConsoleMavenTransferListener does \r-based progress
  • CIDetector classes detect CI environments
  • mvnd's TerminalOutput provides a proven reference implementation

The core change: a new SmartExecutionEventLogger using JLine's Display API to manage a fixed status region, while delegating full output to a file-based log writer.

Activity

  1. cstamas commented on Mar 23, 2026

    @cstamas
    Member

    See also ideas from #1238

  2. coenraadhuman commented on Jun 29, 2026

    @coenraadhuman

    Would love to see this get merged, would be massive improvement to user experience.

  3. added
    enhancement
    on Jun 29, 2026
  4. added theissue type on Jun 29, 2026
  5. gnodet commented on Oct 14, 2026

    @gnodet
    ContributorAuthor

    Closing as superseded by #12571, which is a superset of this proposal — it adds the build report data model, DiagnosticCollector API, machine-readable output, and a phased implementation plan on top of the console redesign described here.

    Claude Code on behalf of Guillaume Nodet

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions