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

Migrate from JSR-305 #108

Open
alexander-yevsyukov opened this issue May 11, 2018 · 7 comments
Open

Migrate from JSR-305 #108

alexander-yevsyukov opened this issue May 11, 2018 · 7 comments

Comments

@alexander-yevsyukov
Copy link
Contributor

alexander-yevsyukov commented May 11, 2018

There are several problems with this dependency:

What our colleagues do about it

@alexander-yevsyukov
Copy link
Contributor Author

We mainly use Nullable and ParametersAreNonullByDefault from JSR-305.

Here are some links related to the matter:

@alexander-yevsyukov
Copy link
Contributor Author

Checker Framework release v2.1.14 mentions that:

Nullness Checker change to annotated JDK: The type argument to the Class, Constructor, and Optional classes may now be annotated as @nullable or @nonnull.

Who are those noble gentlemen?

@alexander-yevsyukov
Copy link
Contributor Author

@armiol, comparing Checker Framework and SpotBugs (which is the successor to FindBugs), the former is much more actively developed.

@alexander-yevsyukov
Copy link
Contributor Author

There's also lastNPE.org project associated with Eclipse.

@alexander-yevsyukov
Copy link
Contributor Author

So far, assuming Guava's transition and other factors the Checker Framework is a winner for our migration.

We have Guava as the dependency anyway. Using the Checker Framework in our code would not increase dependencies.

@alexander-yevsyukov
Copy link
Contributor Author

As we're migrating to Java 8, we need to use @Nullable instead of @NullableDecl. See the recent commit in Guava on this.

@alexander-yevsyukov
Copy link
Contributor Author

alexander-yevsyukov commented May 14, 2018

Partially this issue is addressed by #109. By now, there is no replacement for ParametersAreNonnullByDefault. Although, it's relatively easy to create a replacement, let's wait till the issue is addressed by our colleagues in Guava.

@alexander-yevsyukov alexander-yevsyukov changed the title Avoid JSR-305 dependency Migrate form JSR-305 May 14, 2018
@alexander-yevsyukov alexander-yevsyukov changed the title Migrate form JSR-305 Migrate from JSR-305 May 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant