{"record":{"id":"f54ee689bbd59c74","repo":"apache/maven","slug":"enable-verbose-output-x-to-see-precisely-which","errorCode":null,"errorMessage":"Enable verbose output (-X) to see precisely which goals are not marked as thread-safe.","messagePattern":"Enable verbose output \\(-X\\) to see precisely which goals are not marked as thread-safe\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"info","filePath":"impl/maven-core/src/main/java/org/apache/maven/lifecycle/internal/builder/BuilderCommon.java","lineNumber":137,"sourceCode":"                                + \"plugin(s) that have goals not marked as thread-safe to support parallel execution.\",\n                        \"While this /may/ work fine, please look for plugin updates and/or \"\n                                + \"request plugins be made thread-safe.\",\n                        \"If reporting an issue, report it against the plugin in question, not against Apache Maven.\")) {\n                    logger.warn(s);\n                }\n                if (logger.isDebugEnabled()) {\n                    final Set<MojoDescriptor> unsafeGoals = executionPlan.getNonThreadSafeMojos();\n                    logger.warn(\"The following goals are not marked as thread-safe in \" + project.getName() + \":\");\n                    for (MojoDescriptor unsafeGoal : unsafeGoals) {\n                        logger.warn(\"  \" + unsafeGoal.getId());\n                    }\n                } else {\n                    logger.warn(\"The following plugins are not marked as thread-safe in \" + project.getName() + \":\");\n                    for (Plugin unsafePlugin : unsafePlugins) {\n                        logger.warn(\"  \" + unsafePlugin.getId());\n                    }\n                    logger.warn(\"\");\n                    logger.warn(\"Enable verbose output (-X) to see precisely which goals are not marked as\"\n                            + \" thread-safe.\");\n                }\n                logger.warn(MultilineMessageHelper.separatorLine());\n            }\n        }\n\n        final String defaulModelId = DefaultLifecycleRegistry.DEFAULT_LIFECYCLE_MODELID;\n\n        List<String> unversionedPlugins = executionPlan.getMojoExecutions().stream()\n                .map(MojoExecution::getPlugin)\n                .filter(p -> p.getLocation(\"version\") != null\n                        && p.getLocation(\"version\").getSource() != null\n                        && defaulModelId.equals(\n                                p.getLocation(\"version\").getSource().getModelId()))\n                .distinct()\n                .map(Plugin::getArtifactId) // managed by us, groupId is always o.a.m.plugins\n                .toList();\n","sourceCodeStart":119,"sourceCodeEnd":155,"githubUrl":"https://github.com/apache/maven/blob/e4093d4e120eac99d6bdce5ba67cace2f3085c97/impl/maven-core/src/main/java/org/apache/maven/lifecycle/internal/builder/BuilderCommon.java#L119-L155","documentation":"Trailing hint line of BuilderCommon's non-debug thread-safety report: after listing unsafe plugins, Maven logs 'Enable verbose output (-X) to see precisely which goals are not marked as thread-safe.' and a separator line. It exists because without -X the report is aggregated at plugin level, hiding which specific goals/bindings are the problem.","triggerScenarios":"Automatically printed whenever the plugin-level non-thread-safe list is shown (parallel build, multi-module, unsafe plugins present, debug disabled).","commonSituations":"Developers needing per-goal detail before changing POM bindings; support tickets asking 'which goal exactly is unsafe' from plugin-level output.","solutions":["Re-run the same command with -X (mvn -X -T ...) and read the 'The following goals are not marked as thread-safe' section.","Upgrade/pin the plugins identified from the debug output.","Alternatively inspect the plugin's goal annotations directly: mvn help:describe -Dplugin=<g:a> -Dgoal=<goal> -Ddetail shows 'Thread Safe' status."],"exampleFix":"# before\nmvn -T 4 install   # 'Enable verbose output (-X) ...'\n\n# after\nmvn -X -T 4 install 2>&1 | grep -A15 'goals are not marked as thread-safe'","handlingStrategy":"validation","validationCode":"# guard: always make the per-goal report available in CI artifacts\nmvn -T 1C package 2>&1 | tee build.log || true\ngrep -A30 'not marked as thread-safe' build.log > unsafe-goals.txt || true","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Keep -X logs of one parallel run per project as a known-good baseline of unsafe goals.","Teach teams the difference: plugin-level list by default, goal-level with -X."],"tags":["maven","parallel-build","thread-safety","verbose-logging","diagnostics"],"backgroundTag":"maven-plugin-not-thread-safe","analyzedSha":"e4093d4e120eac99d6bdce5ba67cace2f3085c97","analyzedAt":"2026-08-21T22:58:24.034Z","schemaVersion":2},"datasetVersion":"2026-08-21T23:17:16.201Z"}