Skip to content

Updating from Jackson 2.17 to 2.18 causes KotlinReflectionInternalError #879

Answered by cowtowncoder
GFriedrich asked this question in Q&A
Discussion options

You must be logged in to vote

Could possibly add "ignored type" configuration to prevent any otherwise detected properties with specified value. This can be done via annotation @JsonIgnoreType on class (for 3rd party types, via mix-in annotations usually). But! There's another way too:

final ObjectMapper mapper = ...; // create mapper
mapper.configOverride(ProblematicType.class).setIsIgnoredType(true);```

which might work if you can target specific type.

Alternatively if you can annotate Constructor in question with @JsonIgnore, that'd also work.
Or, like you suggest, @JsonIgnore on specific property.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@GFriedrich
Comment options

@cowtowncoder
Comment options

Answer selected by GFriedrich
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants