-
Notifications
You must be signed in to change notification settings - Fork 6
Description
Why
Today, MvnValidateAllocationByMaven3VersionTest
can be used to evaluate the heap allocation level for a range of Maven distributions.
To more easily spot the changes (the commits) responsible for an allocation increase, we would like to have a test bench to measure the heap allocation level between two Maven commits.
Possible implementation
We could add commit.first.hash
and commit.last.hash
properties in the maven-bench.properties
file.
The new test could execute the following steps:
-
Clone Maven with the hash of the first commit
You may execute Git commands with the help of a Java ProcessBuilder. A ProcessBuilder example can be found here. -
Build Maven
mvn -DdistributionTargetDir="{location}/apache-maven-head" clean package
You may execute this Maven command line from Java with the help of a MvnVerifier object (seeMvnValidateAllocationByMaven3VersionTest
) or with the help of a Java ProcessBuilder. A ProcessBuilder example can be found here. -
Measure heap allocation level in the same way it is done in MvnValidateAllocationByMaven3VersionTest
-
Update the local repository of Maven with the next commit
-
Build Maven
-
Measure heap allocation
...
N) Update the local repository of Maven with the last commit
N+1) Build Maven
N+2) Measure heap allocation
Don't hesitate to leave a comment to discuss about this feature!