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

Wrong nullability annotations produce static code analysis errors #1825

Closed
reitzmichnicht opened this issue Jun 8, 2021 · 2 comments
Closed

Comments

@reitzmichnicht
Copy link

Using latest spring-kafka produces some static analysis errors due to wrong annotations. For example in
https://github.com/spring-projects/spring-kafka/blob/main/spring-kafka/src/main/java/org/springframework/kafka/config/KafkaListenerEndpointRegistry.java
the method getListenerContainer can return null as documented, but on package level the annotation @org.springframework.lang.NonNullApi lets analyzers expect that the method cannot return null values.
It would be great if the nullability annotations are used correctly or removed instead.

Kind regards,
Michael

@garyrussell
Copy link
Contributor

Thanks for pointing out this error; let us know if you see others (and contributions are also welcome).

@reitzmichnicht
Copy link
Author

Thank you very much for the quick fix.

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

2 participants