Below you will find pages that utilize the taxonomy term “Jackson-Json”
Jackson Bug Update
Well that was fast. I didn’t expect the day after the post to have an update but here it is. One thing I love about open source it is possible to find answers quickly. So it turns out that this is not in fact a bug. Apparently Jackson 2 aims for a Java 6 compatibility level. As a result of this they can’t include Java 8 features in the baseline as that would break compatibility. So they have a module to use the Java 8 features that you can bring into Maven with the following settings:
Bug in Jackson JSON serialization of Immutable objects
The bug
I have been using Jackson for JSON processing for many years now. It is a great framework and mostly just works. It is the default framework in Spring Boot and mostly it just sits behind the scenes and drives most micro services in Java these days. That is why I was surprised when we hit a bug in the framework as I hadn’t really had any issues in the past.
The road to Spring Framework 4.1
Earlier this year Spring Framework 4.1 was released. I was excited to try out the new features in our project at work and having previously upgraded us from Spring 3.1 to Spring 3.2 and from Spring 3.2 to Spring 4.0 I was expecting this to be another routine Spring update, but alas that was not to be.
One of the first things I do when looking to do a major version upgrade is to check all the dependency versions for the libraries to make sure all of our libraries are new enough to do the upgrade. In this case I discovered that Spring 4.1 requires Jackson 2.x and we were running Jackson 1.9.x.