-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
add option to generate jakarta @Inject in generated factory #1184
Comments
Could you say some more about these tools? |
Closing due to lack of response. |
@eamonnmcmanus this issue should be opened again, the standards have changed and even guice has now adopted to produce jakarta annotations in their latest versions 7.x and 6.x Tomcat 10.x has also migrated to jakarta annotations as it has been finalised it to be the standard. |
Agreed, with Guice moving to |
Previously AutoFactory recognized and generated `javax.inject` only. Now, it will continue to do so if `javax.inject` is present on the classpath, but it will recognize `jakarta.inject` if only that is on the classpath. Also remove some obsolete tests that would otherwise have had to be updated. Closes #1184. RELNOTES=AutoFactory now recognizes and generates both `javax.inject` and `jakarta.inject`. If `jakarta.inject` is on the classpath then it will be used, and otherwise `javax.inject`. A new compiler option `-Acom.google.auto.factory.InjectApi` can be set to either `javax` or `jakarta` to force the use of one or the other. PiperOrigin-RevId: 535324709
Previously AutoFactory recognized and generated `javax.inject` only. Now, it will prefer `jakarta.inject` if that is on the classpath, but it will still recognize `javax.inject` if only that is on the classpath. A new compiler option can be used to select `javax.inject` even if `jakarta.inject` is also available. Also remove some obsolete tests that would otherwise have had to be updated. Closes #1184. RELNOTES=AutoFactory now recognizes and generates both `javax.inject` and `jakarta.inject`. If `jakarta.inject` is on the classpath then it will be used, and otherwise `javax.inject`. A new compiler option `-Acom.google.auto.factory.InjectApi` can be set to either `javax` or `jakarta` to force the use of one or the other. PiperOrigin-RevId: 535324709
Previously AutoFactory recognized and generated `javax.inject` only. Now, it will prefer `jakarta.inject` if that is on the classpath, but it will still recognize `javax.inject` if only that is on the classpath. A new compiler option can be used to select `javax.inject` even if `jakarta.inject` is also available. Also remove some obsolete tests that would otherwise have had to be updated. Closes #1184. RELNOTES=AutoFactory now recognizes and generates both `javax.inject` and `jakarta.inject`. If `jakarta.inject` is on the classpath then it will be used, and otherwise `javax.inject`. A new compiler option `-Acom.google.auto.factory.InjectApi` can be set to either `javax` or `jakarta` to force the use of one or the other. PiperOrigin-RevId: 535324709
Previously AutoFactory recognized and generated `javax.inject` only. Now, it will prefer `jakarta.inject` if that is on the classpath, but it will still recognize `javax.inject` if only that is on the classpath. A new compiler option can be used to select `javax.inject` even if `jakarta.inject` is also available. Also remove some obsolete tests that would otherwise have had to be updated. Closes #1184. RELNOTES=AutoFactory now recognizes and generates both `javax.inject` and `jakarta.inject`. If `jakarta.inject` is on the classpath then it will be used, and otherwise `javax.inject`. A new compiler option `-Acom.google.auto.factory.InjectApi` can be set to either `javax` or `jakarta` to force the use of one or the other. PiperOrigin-RevId: 535324709
Currently, the classes generated from
@AutoFactory
will have ajavax.inject.Inject
annotation, which makes them incompatible with tools that use jakarta annotations. Please add some option, or alternative annotation, so users can choose to have ajakarta.inject.Inject
annotation in the generated code instead.The text was updated successfully, but these errors were encountered: