You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given a JSON tree containing a BinaryNode, validating it with json-schema-validator will cause a NPE:
java.lang.NullPointerException: unhandled token type VALUE_EMBEDDED_OBJECT
The underlying issue is that while Jackson will serialize and deserialize the binary value to and from a (base64 encoded) string, the BinaryNode.asToken method returns VALUE_EMBEDDED_OBJECT. This token type is not listed in NodeType.TOKEN_MAP, causing the mentioned NPE. Adding a mapping from VALUE_EMBEDDED_OBJECT to STRING would solve the problem.
The text was updated successfully, but these errors were encountered:
DanielGronau
changed the title
Handle BinaryNode correctly
Handle BinaryNode in NodeType
Jul 23, 2020
Given a JSON tree containing a
BinaryNode
, validating it with json-schema-validator will cause a NPE:The underlying issue is that while Jackson will serialize and deserialize the binary value to and from a (base64 encoded) string, the
BinaryNode.asToken
method returnsVALUE_EMBEDDED_OBJECT
. This token type is not listed inNodeType.TOKEN_MAP
, causing the mentioned NPE. Adding a mapping fromVALUE_EMBEDDED_OBJECT
toSTRING
would solve the problem.The text was updated successfully, but these errors were encountered: