Each push to the repository will trigger a benchmark run. The project uses a special build task which merges all the benchmark results into a single report file. Latest benchmark results will be viewable via GitHub Pages: https://joel-jeremy.github.io/java-config-library-benchmarks/
(Alphabetical order)
- Cfg4j
- Externalized Properties
- Gestalt Config
- Lightbend Config
- MicroProfile Config - Geronimo
- MicroProfile Config - Helidon
- MicroProfile Config - KumuluzEE
- MicroProfile Config - MicroBean
- MicroProfile Config - SmallRye
- Owner
- Spring Core (Directly using Spring's Environment)
Each library is setup with its "default" configurations. In addition to the defaults, additional configuration/setup is done to "load" a single .properties file. For the benchmark runs, each library will load properties/configuration from the loaded .properties file (all with exactly the same file contents).
Benchmarks require Java 25.
To run the benchmarks and generate reports locally, use the runAllJmh.sh script.
To introduce a new benchmark, create a new gradle subproject and:
- Create an
Benchmarkabstract class underio.github.joeljeremy7.java.config.lib.benchmarkspackage. - Create benchmark methods in
Benchmarkclass- Minimum required methods are:
- Retrieve a
Stringproperty/configuration - Retrieve an
intproperty/configuration
- Retrieve a
- Minimum required methods are:
- Create an
AvgtandThrptnested class withinBenchmarkwhich extends the abstractBenchmarkclass so that they execute the same benchmarks. - Annotate
AvgtandThrptnested classes with appropriate JMH annotations to record results: avgt (ns) and thrpt (ms). - Add the subproject's
jmhtask to therunAllJmh.shscript. - Add the subproject's folder name to the
benchmarks.yamlGitHub Actions workflow:jmh: needs: build runs-on: ubuntu-latest strategy: matrix: module: - ... - my-config-library
- Add project repository link to Libraries section.