adoroszlai opened a new pull request, #6086:
URL: https://github.com/apache/ozone/pull/6086
## What changes were proposed in this pull request?
Ozone currently uses the following annotations from 3 different sources to
indicate that some value (variable, parameter, return value, etc.) may be
`null` or not:
```
104 import javax.annotation.Nonnull;
31 import javax.annotation.Nullable;
2 import org.checkerframework.checker.nullness.qual.Nullable;
59 import org.jetbrains.annotations.NotNull;
2 import org.jetbrains.annotations.Nullable;
```
This PR proposes to standardize on one pair of annotations.
Initially I intended to use `javax.annotation`, since that one is most
common in our current code, and also sounds "official". Unfortunately it
turned out to have problems (see HADOOP-16463 for a nice description).
[Jakarta Annotation
API](https://github.com/jakartaee/common-annotations-api/) is a successor of
that one.
The PR also adds some import ban rules to keep out the old annotations.
https://issues.apache.org/jira/browse/HDDS-9905
## How was this patch tested?
CI:
https://github.com/adoroszlai/ozone/actions/runs/7641061511
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]