TearDown Level coarser than Trial
Håvard Ottestad
hmottestad at gmail.com
Wed Dec 11 10:31:59 UTC 2019
Hi,
I’m creating some benchmarks for a database I’m working on for Eclipse RDF4J and I’ve started wondering if there is a way to make my benchmarks more efficient.
Essentially I’m adding a large dataset to my database and benchmarking some queries. At the end of the benchmark I would like to clean up and delete the database.
I have been using "@TearDown(Level.Trial)” to clean up. It would however be great with a Level.Class or something equivalent to the junit @AfterClass. This way I could set up the underlying database, populate it, run all the benchmarks and finally shutdown and cleanup the database and delete the files from the disk.
Is there some intuitive way that I’m overlooking to get this working the way I want? Or is it just not possible due to the isolation between trials?
Regards,
Håvard M. Ottestad
More information about the jmh-dev
mailing list