Skip to content

JsonUtils refactoring, bug fix, and Fancy Jackson Annotations

Compare
Choose a tag to compare
@milosimpson milosimpson released this 14 Feb 20:24
· 191 commits to master since this release

New JsonUtil interface "extracted" from existing JsonUtils class static methods

  • Interface and Impl will allow clients to specify their own pre-configured ObjectMapper
  • JsonUtils static methods refactored to use a "stock" JsonUtil instance.
  • Two JsonUtils methods deprecated

Fixed bug in JsonUtils

  • The problem was that JsonUtils static methods were using Object.class.getResourceAsStream() which can behave oddly.
  • Now that the static methods in JsonUtils are backed by a real instance of JsonUtil, that JsonUtil can use itself to load resources.

Fancy Jackson Annotations

  • Unit test of new JsonUtilImpl ability to take in a preconfigured Jackson Module
  • Unit test demonstrates recursive polymorphic JSON deserialization in Jackson 2.2

Bumped Dependency Versions

  • Jackson, Guava, TestNg, ArgParse versions.