-
-
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
Enum Deserialisation Failing with Polymorphic type validator #3796
Comments
One quick note: I strong suggest not using
instead of directly serializing polymorphic root value. Having said that, sounds like there might be an issue with handling; thank you for reproduction of the problem. |
Was able to find how to fix this; merged in 2.15 for 2.15.0. |
Thank you so much. |
@sagarika4 Ah, right. It'd be nice to be able to change that but 3rd party dependencies are tricky. |
Whops! Thank you @netomi, fixed. |
Problem
Configuring object mapper with PolymorphicTypeValidator Fails to deserialise enum. Code to reproduce:
Exception thrown:
These configurations are needed for object mapper because Redis GenericJackson2JsonRedisSerializer uses these configurations. Unable to use Redis GenericJackson2JsonRedisSerializer for serialisation and deserialisation. The enum is exactly how the OpenAPI Spec generates it.
Note: This works perfectly fine when object mapper without custom settings is used.
Last version tested on:
The text was updated successfully, but these errors were encountered: