spring-data-relational icon indicating copy to clipboard operation
spring-data-relational copied to clipboard

Migrate to JSpecify annotations for nullability constraints

Open mp911de opened this issue 1 year ago • 3 comments

mp911de avatar Jan 15 '25 08:01 mp911de

Hi, @mp911de!

Could I work on this issue or maybe a part of it? From what I understand, the task is about replacing @Nullable and @NonNull annotations with JSpecify annotations, e.g., ensuring that the necessary imports are in place where they are currently used. Is there anything else I should know before I start working on this?

Thanks!

ivamly avatar Jan 16 '25 17:01 ivamly

Hey @ivamly. There's quite a bit more attached to this task. JSpecify annotations relate to the type level while Spring's @Nullable is targeting parameters, fields, and methods. Also, we're looking to leverage @Contract and integrate with NullAway.

I highly suggest waiting until common infrastructure and dependency management in the build infrastructure is in place (see https://github.com/spring-projects/spring-data-commons/issues/3170). If you give this topic another month or two, then you should have everything in place to start with the task on the module level.

mp911de avatar Jan 16 '25 18:01 mp911de

Thanks! I’ll wait for that.

ivamly avatar Jan 16 '25 18:01 ivamly