Skip to content

refactor(templates): remove the V1 invoice/proposal builtins#273

Merged
DemchaAV merged 2 commits into
2.0-devfrom
refactor/2.0-remove-v1-builtins
Jun 29, 2026
Merged

refactor(templates): remove the V1 invoice/proposal builtins#273
DemchaAV merged 2 commits into
2.0-devfrom
refactor/2.0-remove-v1-builtins

Conversation

@DemchaAV

Copy link
Copy Markdown
Owner

Why

InvoiceTemplateV1 / ProposalTemplateV1 are pre-rebuild builtins superseded by the layered v2 presets (ModernInvoice / ModernProposal), which render the same InvoiceDocumentSpec / ProposalDocumentSpec. They still had live consumers, so this de-consumes before deleting.

What

  • Delete builtins.{InvoiceTemplateV1,ProposalTemplateV1} and the two V1-only file examples (InvoiceFileExample, ProposalFileExample). The cinematic/v2 examples cover invoice & proposal in the gallery.
  • Repoint the three benchmarks (AllocationRateProbe, CurrentSpeedBenchmark, ColdStartJmhBenchmark) and DocumentationExamplesTest onto ModernInvoice.create() / ModernProposal.create() (same spec, DocumentTemplate.compose(session, spec) contract). The benchmarks now exercise the v2 presets — a different renderer, so absolute numbers shift.
  • Clean the dropped examples out of GenerateAllExamples, ShowcaseMetadata, and the examples README; point the surviving InvoiceTemplate/ProposalTemplate Javadoc snippets at the V2 implementer.

The InvoiceTemplate/ProposalTemplate interfaces and the V2 builtins are untouched (a later step). web/examples.json is generated by ShowcaseSync and regenerates at release.

Tests

./mvnw verify javadoc:javadoc -pl . — 1621 tests, 0 failures, javadoc gate clean. examples and benchmarks modules compile against the new jar. japicmp runs report-only on this line.

DemchaAV added 2 commits June 29, 2026 21:24
InvoiceTemplateV1 and ProposalTemplateV1 are pre-rebuild builtins
superseded by the layered v2 presets (ModernInvoice / ModernProposal),
which render the same InvoiceDocumentSpec / ProposalDocumentSpec. They
still had live consumers, so de-consume before deleting.

Delete the two V1 builtins and the two V1-only file examples. Repoint the
three benchmarks (AllocationRateProbe, CurrentSpeedBenchmark,
ColdStartJmhBenchmark) and the documentation example test onto
ModernInvoice/ModernProposal — the benchmarks now exercise the v2 presets
(the workload renderer changes, so absolute numbers shift). Clean the
dropped examples out of GenerateAllExamples, ShowcaseMetadata, and the
examples README, and point the surviving InvoiceTemplate/ProposalTemplate
Javadoc snippets at the V2 implementer.

Tests: ./mvnw verify javadoc:javadoc -pl . — 1621 tests, 0 failures,
javadoc gate clean; examples and benchmarks compile against the new jar.
ModernProposal sizes its timeline and pricing description columns to their
content with no wrap, so once the proposal benchmark moved onto the v2
preset the long-form fixture overflowed the page ("Table ProposalTimeline
width 826.5 exceeds available 551.3") and failed the perf-smoke run.

Shorten the timeline and pricing-row descriptions in the benchmark proposal
fixture so both tables fit A4 at the benchmark's 22pt margin. The long
section paragraphs that drive the multi-page pagination workload are
unchanged, so the benchmark still exercises long content. longProposal()
has no other live consumer (canonicalProposalData() is uncalled; the v2
parity test builds its own data).

Tests: ./mvnw -f benchmarks/pom.xml -DskipTests exec:java
-Dexec.mainClass=com.demcha.compose.CurrentSpeedBenchmark
-Dgraphcompose.benchmark.profile=smoke now renders invoice/cv/proposal
(BUILD SUCCESS); engine verify + benchmark gates green.
@DemchaAV DemchaAV merged commit bb0ccab into 2.0-dev Jun 29, 2026
11 checks passed
@DemchaAV DemchaAV deleted the refactor/2.0-remove-v1-builtins branch June 29, 2026 21:03
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.

1 participant