[
https://issues.apache.org/jira/browse/CAMEL-19892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Michael Würsch updated CAMEL-19892:
-----------------------------------
Description:
As far as I understand, Camel 4 should no longer rely on javax classes and use
the Jakarta equivalents instead.
However, while migrating my code base, I noticed that the
camel-restdsl-openapi-plugin for Maven outputs classes annotated with
javax.annotation.Generated and thus the generated code requires the
javax.annotation-api dependency to compile.
The reason is that RestDslSourceCodeGenerator.java of
openapi-rest-dsl-generator still uses the old api, which can be easily fixed by
changing the import statement (see attached patch-file).
I did not touch the imports of javax.lang.model.* in
RestDslSourceCodeGenerator.java, because they are related to the use of the
Java Poet library, which has not yet moved to Jakarta. However, these
dependencies do not affect the generated code.
was:
As far as I understand, Camel 4 should no longer rely on javax classes and use
the Jakarta equivalents instead.
However, while migrating my code base, I noticed that the
camel-restdsl-openapi-plugin for Maven outputs classes annotated with
javax.annotation.Generated and thus the generated code requires the
javax.annotation-api dependency to compile.
The reason is that RestDslSourceCodeGenerator.java of
openapi-rest-dsl-generator still uses the old api, which can be easily fixed by
changing the import statement (see attached patch-file).
I did not touch the imports of javax.lang.model.* in
RestDslSourceCodeGenerator.java, because they are related to the use of the
Java Poet library, which it seems has not yet moved to Jakarta. However, these
dependencies do not affect the generated code.
> openapi-rest-dsl-generator - Use jakarta instead of javax annotation
> --------------------------------------------------------------------
>
> Key: CAMEL-19892
> URL: https://issues.apache.org/jira/browse/CAMEL-19892
> Project: Camel
> Issue Type: Bug
> Affects Versions: 4.0.0
> Reporter: Michael Würsch
> Priority: Major
> Attachments: Fixed_jakarta_import_for_@Generated_.patch
>
>
> As far as I understand, Camel 4 should no longer rely on javax classes and
> use the Jakarta equivalents instead.
> However, while migrating my code base, I noticed that the
> camel-restdsl-openapi-plugin for Maven outputs classes annotated with
> javax.annotation.Generated and thus the generated code requires the
> javax.annotation-api dependency to compile.
> The reason is that RestDslSourceCodeGenerator.java of
> openapi-rest-dsl-generator still uses the old api, which can be easily fixed
> by changing the import statement (see attached patch-file).
> I did not touch the imports of javax.lang.model.* in
> RestDslSourceCodeGenerator.java, because they are related to the use of the
> Java Poet library, which has not yet moved to Jakarta. However, these
> dependencies do not affect the generated code.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)