A tiny, minimal overhead extension to create build metrics and timeline for projects being built.
Runtime requirement is Java 8 and Maven 3.6+.
To generate a timeline for your project add this to the build section of your pom.xml, or (recommended), create file .mvn/extensions.xml is project root with contents as below:
<?xml version="1.0" encoding="UTF-8"?>
<extensions>
<extension>
<groupId>io.takari.maven</groupId>
<artifactId>maven-timeline</artifactId>
<version>2.1.0</version>
</extension>
</extensions>Once your project has run you will have a target/timeline/timeline.html in the top-level of your project. The output will look something like the following:
Use following properties:
- Java System Property
maven-timeline.enabledto enable or disable Timeline creation and export, default istrue. - Maven Config Property
maven-timeline.discriminatorthat moves theoutputDirectory(default is build directory, ietarget/) with specified discriminator, default isnull(does not discriminate output). - Maven Config Property
maven-timeline.metrics.output.filethe output of metrics JSON file, default is top level project${outputDirectory}/execution-metrics.json - Maven Config Property
maven-timeline.timeline.output.filethe output of Timeline (data and HTML/JS), default is top level project${outputDirectory}/timeline/maven-timeline.js
Note: Java System Properties must be set via MAVEN_OPTS or via .mvn/jvm.config, while
Maven Config Property can be set via -D command line or in .mvn/maven.config, see https://maven.apache.org/configure.html
Build time requirement is Java 17+ and recent Maven (3.9+ recommended).
