Today, I came across a json parsing situation where the sub-type field is outside the type json. Genrally we seen a situation like this @JsonTypeInfo(use=JsonTypeInfo.Id.CLASS, include=JsonTypeInfo.As.PROPERTY, property="@class") class Animal{} class Dog extends Animal{ } class Cat extends Animal{ } and it de-serialize to json like this: { "@class" : "x.y.z.Cat", ... } In my project I need to parse json like this { "status": "OK", "messageName": "x.y.z.Success", "messagePayload": { "foo": "cd3a5697", "bar": 224 } } { "status": "ERROR", "messageName": "x.y.z.Error", "messagePayload": { "errorCode": "APPLICATION_ERROR", "errorInstanceId": "b292b864", "errorDetailedMessage": "Invalid UUID string (Length mismatch)" } }
Some#random('thoughts'); // technical, non technical