Skip to content

Jackson Release 2.20

Tatu Saloranta edited this page Aug 17, 2025 · 42 revisions

Status

Branch is being prepared for release as of August 2025.

One release candidate (2.20.0-rc1) has been released prior to final 2.20.0.

Patches

No release yet

Documentation

Articles, Blog posts

New Modules

Hibernate 7 support

New datatype module added in jackson-datatype-hibernate:

Changes, compatibility

Compatibility: platform requirements

Android

Same as Jackson 2.19, SDK 26

JDK

Same as Jackson 2.19 (mostly Java 8) except:

  • jackson-annotations now requires Java 8 (no more Java 6 baseline)

Kotlin

Same as Jackson 2.19?

Compatibility: versioning

  • jackson-annotations no longer uses patch number: so we have version 2.20 (instead of 2.19.0 and so on)

Compatibility: datatype modules

Guava

Minimum supported Guava version now 22.0 (from 20.0 with 2.19 and prior) -- see guava#158

Changes, behavior

None


Major focus area(s)

Most wanted Features implemented

  • databind#5152: Support "iPhone" style capitalized properties (add MapperFeature.FIX_FIELD_NAME_UPPER_CASE_PREFIX)

Full Change list

Changes, core

  • #291: Add optional property for @JacksonInject to allow optionally injected values
  • #293: Improve duplicate Id with different associated object error message
  • #294: Drop patch number from version for 2.20 and later (no more 2.20.0)
  • #296: Drop Java 6 compatibility for 2.20 (Java 8 baseline)
  • #1438: ParserBase.close() does not clear _currToken
  • #1441: Add StreamReadFeature.CLEAR_CURRENT_TOKEN_ON_CLOSE (default: true)
  • #1448: Upgrade FastDoubleParser to 2.0.1
  • #1462: Deprecate URL-taking factory method of JsonFactory
  • #2692: Should never call set() on setterless property during deserialization
  • #3072: Allow specifying @JacksonInject does not fail when there's no corresponding value
  • #4136: Drop deprecated (in 2.12) PropertyNamingStrategy implementations from 2.20
  • #4656: DeserializationProblemHandler.handleUnexpectedToken() cast Object to String
  • #5103: Use writeStartObject(Object forValue, int size) for ObjectNode serialization
  • #5151: Add new exception type, MissingInjectValueException, to be used for failed @JacksonInject
  • #5152: Support "iPhone" style capitalized properties (add MapperFeature.FIX_FIELD_NAME_UPPER_CASE_PREFIX)
  • #5192: Record types are broken on Android when using R8
  • #5194: Custom Throwable not serializable if using JsonAutoDetect settings that only detect Fields
  • #5197: Add more informative exception for back-references with record type
  • #5237: Failing @JsonMerge with a custom Map with a @JsonCreator constructor
  • #5242: Support "binary vectors": @JsonFormat(shape = Shape.BINARY) for float[], double[]
  • #5257: Deprecate URL-taking readValue() methods in ObjectMapper, ObjectReader

Changes, data formats

CBOR

  • #137: Allow exposing CBOR "undefined" value as JsonToken.VALUE_EMBEDDED_OBJECT (with embedded value of null)
  • #431: Negative BigInteger values not encoded/decoded correctly
  • #587: Allow exposing CBOR Simple values as JsonToken.VALUE_EMBEDDED_OBJECT with a feature flag
  • #603: Add support for writing unsigned numbers to CBOR

CSV

  • #497: UTF8Reader throws "Need to move partially decoded character; buffer not modifiable" when read only one chinese char
    • NOTE: actual fix already merged in 2.19.0, marked as fixed in 2.20.0
  • #564: CsvParser.getNumberValue(), related, do not throw exception for non-numeric tokens

TOML

  • #497: UTF8Reader throws "Need to move partially decoded character; buffer not modifiable" when read only one chinese char
    • NOTE: TOML part fixed in 2.20, CSV part earlier (in 2.19.0)
  • 768: FromXmlParser lacks extension point for passing custom XmlTokenStream

YAML

  • #497: UTF8Reader throws "Need to move partially decoded character; buffer not modifiable" when read only one chinese char
    • NOTE: YAML part fixed in 2.20, CSV part earlier (in 2.19.0)

Changes, data types

Guava

  • #158: Increase minimum supported Guava from 20.x to 22.x for Jackson 2.20
  • #184: Add jackson-datatype-hibernate7 module for Hibernate version 7
  • #186: Update hibernate 6 code to avoid deprecated code
  • #92: DateTime serialization result is not same as Java 8 ZonedDateTime
  • #146: DateTime can't be serialized with its own zone (WRITE_DATES_WITH_CONTEXT_TIME_ZONE not respected)

Changes, other

  • #196: float[] and double[] are serialized to JSON as { }
  • #201: Support for OffsetDateTime and ZonedDateTime in jackson-jr-extension-javatime
Clone this wiki locally