Skip to content

feat: JMH benchmarks for DataDictionaryGenerator and CodeGeneratorJ - #69

Draft
chrjohn with Copilot wants to merge 4 commits into
masterfrom
copilot/performance-test-jmh-quickfixj
Draft

feat: JMH benchmarks for DataDictionaryGenerator and CodeGeneratorJ#69
chrjohn with Copilot wants to merge 4 commits into
masterfrom
copilot/performance-test-jmh-quickfixj

Conversation

Copilot AI commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Adds a self-contained JMH benchmark module to measure the generation pipeline cost targeted by PR #68 (cached JAXBContext, cached XPathExpression, buffered I/O).

New module: quickfixj-from-fix-orchestra-benchmarks

  • DataDictionaryGeneratorBenchmark — measures DataDictionaryGenerator.generate(InputStream, File): covers the double JAXBContext.newInstance(), per-call XPath compile, and unbuffered FileWriter that PR perf: DataDictionaryGenerator — buffer output, cache JAXBContext and XPathExpression #68 eliminates
  • CodeGeneratorJBenchmark — measures CodeGeneratorJ.generate(InputStream, File): covers the JAXBContext.newInstance() and per-file unbuffered writes
  • pom.xml — JMH 1.37 deps + maven-shade-plugin; builds a self-contained benchmarks.jar via mvn package -DskipTests
  • trade.xml — FIX Orchestra input resource (copied from generator test resources)

Usage

# Build
mvn -pl quickfixj-from-fix-orchestra-repository/quickfixj-from-fix-orchestra-benchmarks \
    -am package -DskipTests

# Full run (3 warmup + 5 measurement, 1 fork)
java -jar .../benchmarks.jar

# Quick smoke-check
java -jar .../benchmarks.jar -wi 1 -i 1 -f 1

To verify PR #68: run on master (baseline) then on copilot/improve-code-generation-performance and compare the Score column — lower ms/op confirms the improvement.

Copilot AI changed the title feat: add JMH performance benchmarks for DataDictionaryGenerator and CodeGeneratorJ feat: JMH benchmarks for DataDictionaryGenerator and CodeGeneratorJ Jul 21, 2026
Copilot AI requested a review from chrjohn July 21, 2026 13:35
@chrjohn

chrjohn commented Jul 21, 2026

Copy link
Copy Markdown
Member

@copilot target release needs to be JDK8.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants