{"record":{"id":"9f6b6725970b4a88","repo":"quarkusio/quarkus","slug":"aggregated-maven-build-error-messages-accumulated","errorCode":null,"errorMessage":"(aggregated Maven build error messages accumulated in the error handler, rethrown verbatim)","messagePattern":"\\(aggregated Maven build error messages accumulated in the error handler, rethrown verbatim\\)","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"independent-projects/bootstrap/maven-resolver/src/main/java/io/quarkus/bootstrap/resolver/maven/FailAtCompletionErrorHandler.java","lineNumber":62,"sourceCode":"            log.error(prefix, error);\n            sb.append(System.lineSeparator()).append(prefix).append(\" \").append(error.getLocalizedMessage());\n            for (var e : error.getStackTrace()) {\n                sb.append(System.lineSeparator());\n                for (int j = 0; j < prefix.length(); ++j) {\n                    sb.append(\" \");\n                }\n                sb.append(\"at \").append(e);\n                if (e.getClassName().contains(\"io.quarkus\")) {\n                    sb.append(System.lineSeparator());\n                    for (int j = 0; j < prefix.length(); ++j) {\n                        sb.append(\" \");\n                    }\n                    sb.append(\"...\");\n                    break;\n                }\n            }\n        }\n        throw new RuntimeException(sb.toString());\n    }\n}\n","sourceCodeStart":44,"sourceCodeEnd":65,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/independent-projects/bootstrap/maven-resolver/src/main/java/io/quarkus/bootstrap/resolver/maven/FailAtCompletionErrorHandler.java#L44-L65","documentation":"FailAtCompletionErrorHandler accumulates Maven build task errors and, in throwFailureReport (invoked from allTasksFinished), rethrows them as a single RuntimeException whose message is the aggregated multi-error report. There is one distinct message per accumulated underlying failure.","triggerScenarios":"A Maven build session using this error handler finishing with one or more task failures: allTasksFinished detects non-empty error state and calls throwFailureReport, throwing the concatenated report verbatim.","commonSituations":"Multi-module builds where several modules fail (compile/test/deploy), CI runs that surface all accumulated failures at once, dependency resolution errors during a reactor build with --fail-at-end semantics.","solutions":["Read each section of the aggregated message — every underlying failure is listed with its module and cause","Fix the root failures module by module, starting with the earliest ones since later failures are often cascades","Re-run with -fae/--fail-at-end or per-module builds to isolate independent failures","Check build logs above the report for the first ERROR line, which usually identifies the true root cause"],"exampleFix":"// before: report shows 3 module failures, only 1 real\n// after: fix root module first\nmvn install -pl core/  // then rebuild dependents\nmvn install","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n    buildSession.execute(...); // may throw aggregated report on completion\n} catch (RuntimeException e) {\n    // report is verbatim aggregated text: parse per-module sections\n    for (String section : e.getMessage().split(\"(?m)^\\\\[ERROR\\\\]\")) {\n        logger.error(section);\n    }\n    throw e;\n}","preventionTips":["Fix the first ERROR in the report — later failures are usually cascades","Build modules individually to isolate independent failures","Keep reactor module dependency order correct so build state stays clean"],"tags":["maven","build","aggregated-errors"],"backgroundTag":"maven-build-failed","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}