Release v1.2.0 — DataAddon Performance Overhaul & Increment Protocol
Release v1.2.0 — DataAddon Performance Overhaul & Increment Protocol
Released: 2026-04-26
────────────────────────────────────────
WHAT'S NEW
INCREMENT_DATA Protocol
A new request type that allows atomic numeric field increments directly
over the network without a full SET_DATA round-trip. Supports both
integer (long) and floating-point (double) fields. Invalid fields,
missing keys, and null values are rejected early with structured warnings.
────────────────────────────────────────
PERFORMANCE IMPROVEMENTS
Shared ObjectMapper
ObjectMapper is now a static final constant shared across all DataAddon
instances. Previously a new instance was created per subclass, generating
unnecessary GC pressure under load.
Reflection Cache
Field scanning via getDeclaredFields() is now performed once and cached
per instance. getIdFieldName(), getIdClassName(), and getAnnotatedFields()
all benefit from lazy double-checked locking — repeated calls are now
effectively free.
L1 Cache Short-Circuit
getData() no longer runs modelInitComp() on memory-cached (L1) models.
modelInitComp() now only runs on Redis (L2) and MongoDB (L3) loads where
schema migration is actually needed.
────────────────────────────────────────
BUG FIXES
State Corruption in modelInit()
modelInit() was writing back to instance fields via field.set(this, ...)
as a side effect of JSON generation. Under concurrent load this caused
silent data corruption. modelInit() is now purely functional.
Race Condition in handleIncrementData()
Concurrent increments on the same key were overwriting each other.
A per-key ConcurrentHashMap lock now serializes the read-mutate-write
sequence atomically.
NullPointerException in handleRemove()
Boolean unboxing on a potentially null value from the JSON container
could throw NPE. Replaced with Boolean.TRUE.equals() for null-safe check.
Missing Primitive Types in convertToType()
long / Long and double / Double were not handled explicitly and fell
through to the reflection path unnecessarily. Both are now covered.
────────────────────────────────────────
INTERNAL / HOUSEKEEPING
- All logging migrated from System.out and e.printStackTrace()
to java.util.logging with structured [DataAddon/] prefixes - Log levels: SEVERE for unrecoverable errors, WARNING for bad input
- All log messages and inline comments translated to English
────────────────────────────────────────
MIGRATION NOTES
No API changes. DataAddon subclasses require no modifications.
The INCREMENT_DATA handler is opt-in via handleRequest() routing.
────────────────────────────────────────
FULL CHANGELOG
v1.1.0 → v1.2.0
https://github.com/darkland/nexus/compare/v1.1.0...v1.2.0