Run the "invoker" Maven executor through maven-executor - #1504
Draft
slachiewicz wants to merge 1 commit into
Draft
slachiewicz wants to merge 1 commit into
slachiewicz wants to merge 1 commit into
Conversation
maven-invoker is deprecated (apache/maven-invoker#164). The executor keeps its "invoker" id and behaviour: same options, the additional arguments split the way the forked executor splits them, the build's output on the plugin's logger.
This was referenced Sep 21, 2026
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
maven-invoker is deprecated in favour of maven-executor (apache/maven-invoker#164).
InvokerMavenExecutor, the defaultmavenExecutorId, keeps its id and behaviour but runs Maven withForkedMavenExecutoron the release environment's Maven home: the invoker's setters become options (-Xin debug,-Bunless interactive,-Dmaven.repo.local,-f,-sfor the encrypted settings copy),JAVA_HOMEgoes through the request's environment,additionalArgumentsare split with plexus-utilstranslateCommandline, the same splitting theforkedexecutor uses, and the build's stdout and stderr reach the plugin's logger line by line as before. Interactive mode still handsSystem.into the build.Three ITs (MRELEASE-533, MRELEASE-618, MRELEASE-966) assert the invoker's debug line about a POM not named
pom.xml; the executor logs the same sentence when it adds-f, and also the full command line at debug level.Verified:
mvn -Prun-its install→ 55 ITs passed; maven-release-manager unit tests → 769 passed.Not ready to merge until apache/maven-executor#50 is fixed. All 55 ITs run in batch mode. In interactive mode the executor is handed
System.in, and maven-executor 1.0.0 waits for that stream to reach EOF beforeexecute()returns, so an interactiverelease:preparewould hang after the forked build finishes. maven-invoker returned as soon as the process ended.