Skip to content

build: enforce NullAway and tighten nullability contracts across modules#19

Merged
limehee merged 9 commits intomainfrom
feat/#17
Mar 4, 2026
Merged

build: enforce NullAway and tighten nullability contracts across modules#19
limehee merged 9 commits intomainfrom
feat/#17

Conversation

@limehee
Copy link
Copy Markdown
Owner

@limehee limehee commented Mar 4, 2026

Summary

Enforced NullAway checks for production source sets and aligned nullability contracts across core/autoconfigure internals.
Also applied module-level formatting updates for jsonrpc-core, jsonrpc-spring-webmvc, jsonrpc-spring-boot-autoconfigure, jsonrpc-spring-boot-starter, samples, and docs.

Key changes:

  • Build quality gate:
    • Added Error Prone + NullAway in Gradle version catalog and root build.
    • Enabled NullAway for production Java compile tasks and excluded test source sets.
  • Core nullability alignment:
    • Kept defensive runtime guards on public entry points.
    • Removed impossible internal null branches where flow already guarantees non-null.
    • Added/updated tests for binder/dispatcher/exception resolver behavior.
  • Auto-configuration/support alignment:
    • Normalized nullable/non-null contracts in interceptor/metrics/observer/executor paths.
    • Added explicit non-null constructor guards for required collaborators.
  • Formatting-only normalization:
    • core, webmvc, autoconfigure, starter, samples, and docs.

Related Issues

Change Type

  • Bug fix
  • Feature
  • Refactor
  • Documentation
  • Test
  • Build/CI

JSON-RPC Impact

Describe protocol-level impact, if any:

  • No protocol behavior change
  • Request validation behavior changed
  • Error mapping behavior changed
  • Method registration/dispatch behavior changed

Details:

  • This PR strengthens compile-time null-safety and code consistency; JSON-RPC protocol semantics remain unchanged.

Validation

  • ./gradlew test
  • ./gradlew check
  • Added/updated tests for new behavior

Documentation

  • Updated README (if needed)
  • Added migration notes for breaking changes (if any)

@limehee limehee marked this pull request as ready for review March 4, 2026 04:11
@limehee limehee self-assigned this Mar 4, 2026
@limehee limehee added the type: feature New feature specification and implementation. label Mar 4, 2026
@limehee limehee merged commit 82b50f0 into main Mar 4, 2026
5 checks passed
@limehee limehee deleted the feat/#17 branch March 4, 2026 04:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: feature New feature specification and implementation.

Projects

None yet

1 participant