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

[Java] Remove use of jsr305 #43396

Closed
Tracked by #67
laurentgo opened this issue Jul 23, 2024 · 1 comment
Closed
Tracked by #67

[Java] Remove use of jsr305 #43396

laurentgo opened this issue Jul 23, 2024 · 1 comment

Comments

@laurentgo
Copy link
Collaborator

Describe the enhancement requested

jsr305 dependency was an attempt at standardizing a set of annotations to provide semantic information regarding Java classes, methods, fields, etc.

Unfortunately the adoption has not been widespread and the dependency is not being updated, potentially causing issues with JPMS.

As some of the jsr305 annotations have equivalent within the checker framework, we could replace most of the usage of jsr305 annotations with checker annotations. The only one with no equivalent is @ThreadSafe which is only used once and could be simply removed.

Note that the same discussion is happening in multiple projects, like caffeine or guava. There is also a new standardization project named jspecify but the project only provides 4 nullability correctness annotations for now while Arrow also uses checker framework beyond just nullability correctness.

Component(s)

Java

laurentgo added a commit to laurentgo/arrow that referenced this issue Jul 23, 2024
jsr305 is not maintained anymore and is unlikely to support JPMS. The
classes are also in the javax. namespace which is known to cause issues
as well.

Replace most uses of jsr305 with the equivalent checker framework
annotations, and remove usage of @threadsafe.
laurentgo added a commit to laurentgo/arrow that referenced this issue Jul 23, 2024
jsr305 is not maintained anymore and is unlikely to support JPMS. The
classes are also in the javax. namespace which is known to cause issues
as well.

Replace most uses of jsr305 with the equivalent checker framework
annotations, and remove usage of @threadsafe.
laurentgo added a commit to laurentgo/arrow that referenced this issue Jul 23, 2024
jsr305 is not maintained anymore and is unlikely to support JPMS. The
classes are also in the javax. namespace which is known to cause issues
as well.

Replace most uses of jsr305 with the equivalent checker framework
annotations, and remove usage of @threadsafe.
lidavidm pushed a commit that referenced this issue Jul 24, 2024
### Rationale for this change

jsr305 is not maintained anymore and is unlikely to support JPMS. The classes are also in the javax. namespace which is known to cause issues as well.

### What changes are included in this PR?

Replace most uses of jsr305 with the equivalent checker framework annotations, and remove usage of `@ ThreadSafe.`

### Are these changes tested?

CI/CD

### Are there any user-facing changes?

None

* GitHub Issue: #43396

Authored-by: Laurent Goujon <[email protected]>
Signed-off-by: David Li <[email protected]>
@lidavidm lidavidm added this to the 18.0.0 milestone Jul 24, 2024
@lidavidm
Copy link
Member

Issue resolved by pull request 43397
#43397

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants