Skip to content
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

Introduce KotlinUtils #33630

Open
sdeleuze opened this issue Oct 1, 2024 · 2 comments
Open

Introduce KotlinUtils #33630

sdeleuze opened this issue Oct 1, 2024 · 2 comments
Assignees
Labels
in: core Issues in core modules (aop, beans, core, context, expression) theme: kotlin An issue related to Kotlin support type: enhancement A general enhancement
Milestone

Comments

@sdeleuze
Copy link
Contributor

sdeleuze commented Oct 1, 2024

Kotlin support has grown organically both in Spring Framework and other Spring portfolio projects, the set of features required portfolio wide is now pretty stabilized but there is a lack of reuse with related maintainability challenges.

For example, the logic Kotlin logic in InvocableHandlerMethod is involved, duplicated on WebFlux side, and required on Spring Boot side for features like configuration property binding to a Kotlin value class as described in spring-projects/spring-boot#41693.

Spring Data has a also lot of Kotlin related infrastructure that could be shared as well.

@sdeleuze sdeleuze added type: enhancement A general enhancement theme: kotlin An issue related to Kotlin support labels Oct 1, 2024
@sdeleuze sdeleuze added this to the 7.0.x milestone Oct 1, 2024
@sdeleuze sdeleuze self-assigned this Oct 1, 2024
@jhoeller jhoeller added the in: core Issues in core modules (aop, beans, core, context, expression) label Oct 1, 2024
@mp911de
Copy link
Member

mp911de commented Oct 2, 2024

Spring Data has a set of utils (KotlinReflectionUtils, KotlinBeanInfoFactory, KotlinValueUtils) for various applications, such as value class usage and Property descriptor detection. Would it make sense to move some of these into Spring Framework to let other components also benefit from Value classes?

@sdeleuze
Copy link
Contributor Author

sdeleuze commented Oct 2, 2024

@mp911de The functional scope of those utils make sense to me, we may end up to refine some public API and implementation, especially if we are able to move forward on #21546 and collaborate closely with Kotlin team to simplify value class support and fix some bug you have reported like https://youtrack.jetbrains.com/issue/KT-20768. If that's ok for you I will have a deeper look to Spring Data Kotlin utils, and include related learnings in my discussion with the Kotlin team, and when we have a reasonably clear idea of the underlying capabilities we will use, we can start collaborating actively on that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) theme: kotlin An issue related to Kotlin support type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

3 participants