Files
NeitzelFXDesigner/docs/lombok-adoption.md
T

56 lines
3.1 KiB
Markdown

# Lombok adoption — 2026-11-14
Lombok is now a Java coding preference in the workspace and in both projects'
`AGENTS.md` files. The refactor preserves existing contracts rather than making
Models into value objects.
## Scope
NeitzelLib uses focused accessors for binding declarations, Model JavaBeans,
scanner results, messages and account settings; constructor annotations replace
assignment-only constructors in core, FX, Gson and the reference application.
The ViewModel logger uses `@Slf4j`. Constructor injection remains annotated.
Existing equality, masked account output, null/default behavior and JavaFX
property operations remain unchanged. ResultSet forwarding stays explicit;
experimental delegation was not introduced.
The Designer uses constructor annotations in worker/session, snapshot lease,
discovery and host document/diagnostic adapters. It retains records, concise
interface adapters and constructors that validate, acquire resources or install
listeners. The vendored Kit patch is unchanged.
Both checkouts stop external Lombok configuration inheritance. Maven and Gradle
explicitly select Lombok 1.18.42 as a processor and compile-time dependency. The
Model processor's own `proc=none` bootstrap remains intact. The example's normal
build now enables Lombok; its optional Designer profile selects both processors.
NeitzelLib expands Lombok into `target/delombok` for Javadoc, without compiling
those expanded files. This preserves generated accessors in the published API
documentation and supports generated constructors carrying `@Inject`.
## Validation
- NeitzelLib default reactor: 130 tests, no failures/errors/skips.
- NeitzelLib clean `designer-preview` reactor: 132 tests, no failures/errors/skips.
- Generated Person metadata contains all eight properties, with generated
reader/writer names and collection element types.
- Compiled member signatures/descriptors, including constructor visibility,
match the pre-refactor baseline across 84 affected classes (including nested
classes). Only the private logger name is excluded from the comparison.
- Generated getter/setter Javadoc and injected constructor annotations checked.
- Designer Maven: 148 tests; IntelliJ Gradle: 12 tests; no failures/errors/skips.
- Full `scripts/check-bootstrap.py`: bytecode baselines, target fixture matrix,
Build and Refresh, both host document adapters, native shared Kit in classpath
and module-path configurations, worker lifecycle/abrupt owner death, plugin
packaging and documentation checks pass.
- Packaged standalone host with the changed real `fx-example`: metadata, source
history/save, Component navigation and all five independent interactive samples
pass; workers exit with the host.
- Plugin ZIP inspected: Lombok is absent. Packaging checks now reject it in
both the IntelliJ plugin and standalone runtime dependencies.
The Designer's pinned NeitzelLib runtime artifacts are not replaced by this
source cleanup. The real example qualification builds a disposable copy of the
changed library, so it can exercise the new library and Designer together while
keeping that recorded baseline intact.