-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prevent construction of null
-valued JsonNode
s (like TextNode
)
#4381
Labels
3.x
Issues to be only tackled for Jackson 3.x, not 2.x
Comments
cc @pjfanning . |
I would include BinaryNode here too. |
@pjfanning Ok I have no strong opinion so sure, why not. EDIT: |
cowtowncoder
changed the title
Prevent construction of
Prevent construction of Mar 2, 2024
null
-valued JsonNode
s (like TextNode
) in 3.0null
-valued JsonNode
s (like TextNode
)
cowtowncoder
added a commit
that referenced
this issue
Mar 2, 2024
cowtowncoder
added a commit
that referenced
this issue
Mar 2, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe your Issue
(note: follow-up to #4378 which is for 2.x)
We should not allow constructing
JsonNode
s aroundnull
, except for explicitNullNode
: attempts to do so should throw aJacksonException
(DatabindException
subtype).This should be checked for:
TextNode
BigIntegerNode
DecimalNode
BinaryNode
There may also be cases where we decide
null
is appropriate content.One such type is
POJONode
.The text was updated successfully, but these errors were encountered: