Skip to content

Change the way BeanDescription passed during serializer construction to use Supplier #5093

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

Closed
cowtowncoder opened this issue Apr 13, 2025 · 1 comment
Labels
3.0 Issue planned for initial 3.0 release
Milestone

Comments

@cowtowncoder
Copy link
Member

To support lazy introspection of BasicBeanDescription for common cases (or more specifically, often avoid it altogether), it makes sense to pass Supplier<BeanDescription> instead of BeanDescription.
Supplier will then just call introspection first time, and cache (memoize) it for further access.

The most obvious place that needs changing is Serializers but code in BasicSerializerFactory and BeanSerializerFactory needs changes too.

And after databind changes, many/most modules as well.

@cowtowncoder
Copy link
Member Author

note: related to #4907, pre-req.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.0 Issue planned for initial 3.0 release
Projects
None yet
Development

No branches or pull requests

1 participant