-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
JacksonRelease1.9
Version 1.9 was released October 4, 2011, about 6 months after 1.8.
The biggest general feature implemented was a complete rewrite of Bean Property introspection logic (see '''JACKSON-242''' below), which conceptually binds distinct accessors (getter, setter, field, constructor parametre) of a logical property, and merges all relevant annotations. This is good in that it removes need for redudant annotatons when renaming or ignoring properties, or defining type information.
In addition to multiple other features, the main focus was to plan for upcoming 2.0, which is likely to be less backwards-compatible release. The goal was to try to add deprecation warnings as early as possible, to try to minimize eventual changes needed to upgrade code relies on 1.9, to use 2.0. As a result, number of deprecated methods and classes increased significantly.
The last bigger general change was the introduction of ValueInstantatior
s (see below), which finally allows for custom handling of POJO creation, above and beyond ability to use @JsonCreator
annotation.
- Jackson 1.9 feature overview (at Cowtalk)
- http://jira.codehaus.org/browse/JACKSON-132 Allow JacksonFeatureUnwrapping of child objects using {{{@JsonUnwrapped}}}.
- http://jira.codehaus.org/browse/JACKSON-242 Rewrite property introspection part of framework to combine getter/setter/field annotations
- http://jira.codehaus.org/browse/JACKSON-406: Allow JacksonFeatureValueInjection during deserialization.
- http://jira.codehaus.org/browse/JACKSON-453: Support for 'external type id' by adding {{{@JsonTypeInfo.As.EXTERNAL_PROPERTY}}} to indicate that property should be added at parent (i.e. as sibling to value being typed)
- http://jira.codehaus.org/browse/JACKSON-580 Allow registering instantiators (ValueInstantiator) for types (classes)
- Related: http://jira.codehaus.org/browse/JACKSON-633 add {{{@JsonValueInstantiator}}} to specify instantiator for a class.
- http://jira.codehaus.org/browse/JACKSON-517 Create "mini-core" ("{{{jackson-mini-VERSION.jar}}}") jar that trims down as much weight from standard jackson-core jar as possible
- http://jira.codehaus.org/browse/JACKSON-558 Implement JacksonFeaturesDeserialization.{{{UNWRAP_ROOT_VALUE}}} (as counterpart to {{{SerializationConfig.Feature.WRAP_ROOT_VALUE}}}))
- http://jira.codehaus.org/browse/JACKSON-578 Add support to mark JAX-RS methods to return a specific JacksonJsonViews
- http://jira.codehaus.org/browse/JACKSON-594 Support deserializing of non-static inner classes
- http://jira.codehaus.org/browse/JACKSON-595 Terse(r) Visibility Config: add ObjectMapper.{{{setVisibility}}}()
- https://jira.codehaus.org/browse/JACKSON-598 Add set of standard naming-strategy implementations
- https://jira.codehaus.org/browse/JACKSON-602 Add {{{JsonSerialize.Inclusion.NON_EMPTY}}} option
- https://jira.codehaus.org/browse/JACKSON-614 Add JsonTypeInfo.defaultSubType property to indicate type to use if class id/name missing
- http://jira.codehaus.org/browse/JACKSON-254 Add JacksonFeaturesSerialization.{{{WRITE_EMPTY_JSON_ARRAYS}}}, to allow suppressing serialization of empty Collections/arrays.
- http://jira.codehaus.org/browse/JACKSON-531 Comparing actual and default value (for JsonSerialize.Inclusion.NON_DEFAULT) should check array contents
- http://jira.codehaus.org/browse/JACKSON-584 Serialize type info for non-static anonymous inner classes as that of declared (static) type
- http://jira.codehaus.org/browse/JACKSON-593 Add more convenience methods in ObjectMapper for reading values as JSON trees ({{{readTree(URL)}}}, {{{readTree(byte[])}}})
- https://jira.codehaus.org/browse/JACKSON-606 Add proper support for serializing Java Date values as Map keys
- http://jira.codehaus.org/browse/JACKSON-620 Allow empty String to mean null Map, Collection, array, if 'DeserializationConfig.Feature.ACCEPT_EMPTY_STRING_AS_NULL_OBJECT' enabled
- http://jira.codehaus.org/browse/JACKSON-621 Add new fluent method, VisibilityChecker.with(Visibility)
- http://jira.codehaus.org/browse/JACKSON-648 Add 'ObjectMapper.writer(DateFormat)', 'ObjectWriter.withDateFormat()' to allow per-call override of the date format to use (or serialize-as-timestamp if null passed)
- http://jira.codehaus.org/browse/JACKSON-650 Add 'SimpleFilterProvider.setFailOnUnknownId()' to disable throwing exception on missing filter id.
- http://jira.codehaus.org/browse/JACKSON-652 Add JacksonFeaturesDeserialization.USE_JAVA_ARRAY_FOR_JSON_ARRAY
-
http://jira.codehaus.org/browse/JACKSON-653 Add efficient
JsonParser.nextFieldName()
andJsonParser.nextXxxValue()
methods. - http://jira.codehaus.org/browse/JACKSON-666 Add JacksonFeaturesSerialization.{{{REQUIRE_SETTERS_FOR_GETTERS}}} to only auto-detect getters for which there is a setter (or field, constructor parameter)
Following features were considered for inclusion, but ended up getting deferred:
- http://jira.codehaus.org/browse/JACKSON-275: Support multi-argument setters (to allow co-constraints)
- http://jira.codehaus.org/browse/JACKSON-437: Support to set logical property with value of type id that was used for deserialization
- http://jira.codehaus.org/browse/JACKSON-469 Support "builder pattern" for deserialization, @JsonCreator
- http://jira.codehaus.org/browse/JACKSON-490 Allow subclasses to "inherit" @JsonCreator annotation from superclass constructor
- NOTE: should be high priority since it was already deferred from 1.8
- http://jira.codehaus.org/browse/JACKSON-592 Allow inlining/unwrapping of value from single-component JSON array