Skip to content

CAMEL-23265 Fix unchecked/unsafe operations warning in camel-spring-boot-generator-maven-plugin#1733

Merged
cunningt merged 1 commit intoapache:mainfrom
cunningt:uncheckedunsafe
Mar 30, 2026
Merged

CAMEL-23265 Fix unchecked/unsafe operations warning in camel-spring-boot-generator-maven-plugin#1733
cunningt merged 1 commit intoapache:mainfrom
cunningt:uncheckedunsafe

Conversation

@cunningt
Copy link
Copy Markdown
Contributor

Getting unchecked/unsafe operation warnings in camel-spring-boot-generator-maven-plugin - the error is from how the results from loadClass are consumed by addAnnotation

Add a loadAnnotationClass that uses proper typing for loading the Annotation class and use it in the one instance that we call addAnnotation.

BEFORE :

[INFO] /Users/tcunning/src/community/camel-spring-boot/tooling/camel-spring-boot-generator-maven-plugin/src/main/java/org/apache/camel/springboot/maven/SpringBootAutoConfigurationMojo.java: /Users/tcunning/src/community/camel-spring-boot/tooling/camel-spring-boot-generator-maven-plugin/src/main/java/org/apache/camel/springboot/maven/SpringBootAutoConfigurationMojo.java uses unchecked or unsafe operations.
[INFO] /Users/tcunning/src/community/camel-spring-boot/tooling/camel-spring-boot-generator-maven-plugin/src/main/java/org/apache/camel/springboot/maven/SpringBootAutoConfigurationMojo.java: Recompile with -Xlint:unchecked for details.

AFTER :

No unchecked or unsafe operation warning.

…oot-generator-maven-plugin

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@cunningt cunningt merged commit e5a3c6a into apache:main Mar 30, 2026
5 checks passed
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

Successfully merging this pull request may close these issues.

2 participants