benchmarks: BenchmarkDiffTool test coverage + JasperReports 7 PDF export fix#133
Merged
Merged
Conversation
…iveBenchmark
JasperReports 7 modularised PDF export out of the core jasperreports jar into a separate jasperreports-pdf extension. ComparativeBenchmark#benchmarkJasper calls JasperExportManager.exportReportToPdf, which failed at runtime with "Missing JasperReports PDF Extension (jasperreports-pdf-x.x.x.jar)" because only the core artifact was on the classpath.
Add jasperreports-pdf at the same ${jasperreports.version} (7.0.7). The current-speed suite was unaffected; only the comparative step (03-comparative in run-benchmarks.ps1) was broken.
…t runner BenchmarkDiffToolTest exercises the diff engine end-to-end through main(): two report JSONs in, one diffs/<suite>/latest.json out. Covers signed percent deltas (latency + throughput + comparative), the divide-by-zero contract (0->5 = +100, 0->0 = 0), the baseline<->candidate join dropping one-sided scenarios/libraries, and the profile / schema-mismatch / unknown-schema guards. run-benchmark-tests.ps1 runs the benchmarks-module JUnit tests via the Maven wrapper (the module is not part of the main reactor), with -Test and -Install switches.
794d946 to
f76e7d7
Compare
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.
Summary
Two independent benchmarks-module changes:
BenchmarkDiffTool(the run-to-run comparison engine) and add a runner script.1. fix(benchmarks): JasperReports 7 PDF export
ComparativeBenchmark#benchmarkJaspercallsJasperExportManager.exportReportToPdf, which fails at runtime withMissing JasperReports PDF Extension (jasperreports-pdf-x.x.x.jar). JasperReports 7 split PDF export out of the core jar into a separatejasperreports-pdfmodule that was not on the classpath, soscripts/run-benchmarks.ps1died at step03-comparative. The current-speed suite was unaffected.Fix: add
net.sf.jasperreports:jasperreports-pdfat the same${jasperreports.version}(7.0.7).2. test(benchmarks): BenchmarkDiffTool coverage
Previously only
BenchmarkDiffTool's file selection was tested (BenchmarkDiffToolSelectionTest); the actual comparison math was not.BenchmarkDiffToolTestdrives the engine end-to-end throughmain()— two report JSONs in, onediffs/<suite>/latest.jsonout — and covers:0 -> 5 = +100%,0 -> 0 = 0%Plus
scripts/run-benchmark-tests.ps1to run the benchmarks-module JUnit tests (the module is not part of the main reactor), with-Testand-Installswitches.Verification
./mvnw -f benchmarks/pom.xml test-> 11/11 green (7 new + 2 selection + 2 median)ComparativeBenchmarkruns clean: GraphCompose ~2.4 ms / iText ~1.6 ms / JasperReports ~4.4 msNote
Targeted at
develop(integration branch). The JasperReports bug also affects the releasedmainline; it will reachmainat the next release — a direct hotfix PR tomaincan be cut separately if it is needed there sooner.