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

Refine TransactionalOperator.executeAndAwait nullability #29919

Closed
sdeleuze opened this issue Feb 2, 2023 · 0 comments
Closed

Refine TransactionalOperator.executeAndAwait nullability #29919

sdeleuze opened this issue Feb 2, 2023 · 0 comments
Assignees
Labels
in: data Issues in data modules (jdbc, orm, oxm, tx) theme: kotlin An issue related to Kotlin support type: enhancement A general enhancement
Milestone

Comments

@sdeleuze
Copy link
Contributor

sdeleuze commented Feb 2, 2023

As pointed out in 09c64ae#r881209396, currently TransactionalOperator.executeAndAwait has a rigid null-safety handling and hardcode non-null for the input parameter type and nullable for the return value.

Kotlin allows to deal with both non-null and nullable depending on the nullability of the lambda, we should take advantage of that.

@sdeleuze sdeleuze added in: data Issues in data modules (jdbc, orm, oxm, tx) theme: kotlin An issue related to Kotlin support labels Feb 2, 2023
@sdeleuze sdeleuze added this to the 6.0.5 milestone Feb 2, 2023
@sdeleuze sdeleuze self-assigned this Feb 2, 2023
sdeleuze added a commit to sdeleuze/spring-framework that referenced this issue Feb 2, 2023
@sdeleuze sdeleuze added the type: enhancement A general enhancement label Feb 2, 2023
sdeleuze added a commit to sdeleuze/spring-framework that referenced this issue Feb 2, 2023
Before this commit, TransactionalOperator.executeAndAwait had a rigid
null-safety handling. This commit takes advantage of Kotlin capability
to allow to deal with both non-null and nullable
depending on the nullability of the lambda.

Closes spring-projectsgh-29919
mdeinum pushed a commit to mdeinum/spring-framework that referenced this issue Jun 29, 2023
Before this commit, TransactionalOperator.executeAndAwait had a rigid
null-safety handling. This commit takes advantage of Kotlin capability
to allow to deal with both non-null and nullable depending on the
nullability of the lambda.

Closes spring-projectsgh-29919
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: data Issues in data modules (jdbc, orm, oxm, tx) theme: kotlin An issue related to Kotlin support type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

1 participant