Skip to content

chore(engine): deprecate the legacy ECS PDF renderer (F11 follow-up)#150

Merged
DemchaAV merged 3 commits into
developfrom
chore/split-legacy-ecs-pdf-render
Jun 9, 2026
Merged

chore(engine): deprecate the legacy ECS PDF renderer (F11 follow-up)#150
DemchaAV merged 3 commits into
developfrom
chore/split-legacy-ecs-pdf-render

Conversation

@DemchaAV

@DemchaAV DemchaAV commented Jun 9, 2026

Copy link
Copy Markdown
Owner

Follow-up to #148 (F11), which deprecated the engine.core / engine.layout / engine.pagination ECS packages. This continues the ECS phase-out into the PDF render pipeline.

Why a package split (not class-level @Deprecated)

engine.render.pdf is a canonical-mixed package: alongside the legacy renderer it holds the canonical-shared PdfFont, GlyphFallbackLogger, and the header/footer + watermark renderers that document.backend.fixed.pdf depends on. A package-level @Deprecated (F11's no-cascade pattern) wasn't possible without dragging those along, and class-level @Deprecated would cascade deprecation warnings across the legacy engine and the 64-file test harness.

Investigation also corrected the original framing: the handlers/ subpackage (all 13, typed RenderHandler<…, PdfRenderingSystemECS>) and helpers/TableCellBox + helpers/PdfBookmarkBuilder are legacy ECS too, not canonical — the canonical pipeline uses its own document.backend.fixed.pdf.handlers.*. The genuinely canonical-shared set is only 4 classes.

What moved

Into new @Deprecated packages engine.render.pdf.ecs / .handlers / .helpers:

  • 7 top-level: PdfRenderingSystemECS, PdfRenderSession, PdfCanvas, PdfStream, PdfImageCache, PdfFileManagerSystem, PdfGuidesRenderer
  • 13 render-marker handlers
  • 2 helpers: TableCellBox, PdfBookmarkBuilder
  • 5 colocated tests (moved with the package-private classes)

Left in engine.render.pdf (canonical-shared, not deprecated): PdfFont, GlyphFallbackLogger, helpers/PdfHeaderFooterRenderer, helpers/PdfWatermarkRenderer.

Binary compatibility

The relocated renderer has no public entry point (canonical PDF output goes through document.backend.fixed.pdf) and carries no binary-compatibility promise, so the move is excluded from the japicmp gate — relocated .ecs* packages + vacated original FQNs — rather than treated as a breaking removal, the same rationale as the existing document.layout.payloads exclude.

Verification

./mvnw -B -ntp verify -pl . -P japicmp green: 1152 tests, 0 failures/errors/skipped, guards + japicmp pass. Pure mechanical move (zero non-import content changes in the moved files); canonical document.* untouched. Package docs (engine.render.pdf package-info, package-map.md, implementation-guide.md) updated to reflect the canonical/legacy split.

DemchaAV added 2 commits June 9, 2026 12:55
Follow-up to F11/PR #148, which deprecated the engine.core/layout/pagination ECS packages. engine.render.pdf is a canonical-mixed package -- it also holds the canonical-shared PdfFont, GlyphFallbackLogger, and the header/footer + watermark renderers used by document.backend.fixed.pdf -- so the legacy Entity-based PDF renderer could not be marked @deprecated at package level without dragging those along.

Physically split it: move the dead ECS renderer (PdfRenderingSystemECS plus PdfRenderSession/PdfCanvas/PdfStream/PdfImageCache/PdfFileManagerSystem/PdfGuidesRenderer, the 13 render-marker handlers, and the TableCellBox/PdfBookmarkBuilder helpers) into a new engine.render.pdf.ecs with .handlers/.helpers sub-packages, then mark those three packages @deprecated at package level (no deprecation-warning cascade, same pattern as F11). The four canonical-shared types stay in engine.render.pdf; colocated tests move with the package-private classes.

The relocated renderer has no public entry point (canonical PDF output goes through document.backend.fixed.pdf) and carries no binary-compatibility promise, so the package move is excluded from the japicmp gate rather than treated as a breaking removal. Package docs (engine.render.pdf, package-map, implementation-guide) updated to reflect the canonical/legacy split.

No behaviour change; verify -P japicmp green (1152 tests + guards + japicmp).
Follow-up to the legacy ECS PDF renderer split: CONTRIBUTING.md and docs/architecture/overview.md still pointed at the vacated engine.render.pdf.handlers / .helpers locations, and CONTRIBUTING + implementation-guide had broken links to the moved PdfRenderingSystemECSDispatchTest and TableCellBox. Repath to engine.render.pdf.ecs.* and frame the ECS renderer guidance as legacy (canonical PDF output is document.backend.fixed.pdf). Doc-only; guard suite (DocumentationCoverageTest, CanonicalSurfaceGuardTest, DocumentationExamplesTest, PDF boundary guards) green.

Surfaced by an independent review of the package-split PR.
…-ecs-pdf-render

# Conflicts:
#	CHANGELOG.md
#	pom.xml
@DemchaAV DemchaAV merged commit 587cc8c into develop Jun 9, 2026
11 checks passed
@DemchaAV DemchaAV deleted the chore/split-legacy-ecs-pdf-render branch June 9, 2026 13:39
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