src/main/java/org/azeckoski/reflectutils/hosts the runtime code; key subpackages includeconverters,transcoders(Jackson-backed JSON/XML support),annotations, andinterfaces.- Caching and core helpers live alongside the public APIs; caches prefer
WeakHashMap/ConcurrentHashMapimplementations—new utilities should follow this pattern. - Tests under
src/test/javamirror the production layout; reuse fixtures inclassesrather than inventing bespoke beans. - Build outputs land in
target/; always runmvn cleanbefore committing to avoid stray artifacts.
mvn clean verifycompiles against JDK 21, runs the JUnit 5 suite, and produces coverage via JaCoCo.mvn -DskipTests packageis handy for packaging when tests are covered elsewhere.mvn -P release deploysigns and stages artifacts to OSSRH; ensure credentials exist in~/.m2/settings.xml.
- Use 4-space indentation with braces on the same line; prefer explicit types over
varunless readability improves. - Embrace modern Java 21 features (records, pattern matching) when they simplify code, but keep APIs source-compatibility friendly.
- New subpackages should have concise, descriptive names (e.g.,
cache,transcoders.jackson). - Source files are UTF-8; group imports by domain and keep static imports separate.
- Tests are JUnit 5 (
@Test), usingorg.junit.jupiter.api.Assertionsstatics. - For JSON/XML scenarios, assert using decoded
Map<String,Object>representations rather than string equality. - Favor focused unit tests over giant integration fixtures; extend or reuse helpers in
classesandannotations. - Run
mvn clean verifybefore opening a PR; capture any CI-specific flakes in the PR description.
- Write imperative, scoped commit messages (e.g.,
Replace beanutils cache with WeakHashMap). - Reference GitHub issues in branch names or PR titles (e.g.,
modernize/jdk21-cache). - Document behavior or API changes in the PR body; include sample payloads when serializer output changes.
- Keep
target/and other build outputs out of commits; prefer smaller PRs that are easy to review.