unknown properties
JSON fields in incoming data that the target Java type does not declare, which a mapper can either reject or ignore.
In more detail
Rejecting them catches client typos; ignoring them lets old clients or servers tolerate newer fields. Jackson rejects them by default, while Spring Boot configures it to ignore them. Choose deliberately and document it as part of the contract.
Related terms
- ObjectMapper — Jackson's main class, which converts objects to JSON with writeValueAsString and JSON to typed objects with readValue, following its configured rules.
- API contract — The written promise an API makes about its operations, inputs, outputs and errors, which callers rely on while the code behind it changes.
Taught in
- Serialization And JSON — Modern Java: Virtual Threads & High-Throughput Services
- Working With Jackson — Modern Java: Virtual Threads & High-Throughput Services