-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
ArC fixes for spec compatibility, round 3 #30924
Conversation
I know why the tests fail, fix incoming. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Not sure why so many checks were skipped 😕 Will rebase and try again. |
* This annotation can be used not only on bean classes, but also method and field producers (unlike pure {@code Priority}). | ||
* | ||
* @deprecated Use {@link Alternative} and {@link io.quarkus.arc.Priority}/{@link jakarta.annotation.Priority} instead | ||
* @deprecated Use {@link Alternative} and {@link jakarta.annotation.Priority} instead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if we should remove this annotation instead...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would be in favor, but ... should we first add a warning that it's deprecated for removal?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, it's deprecated since 2.6.0.CR1...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 for removal, it was meant as a temporary solution until we can make use of a standard solution anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it has been deprecated since 2.6, we can remove it. Just make sure you add an entry to the migration guide about how it should be transformed.
independent-projects/arc/processor/src/main/java/io/quarkus/arc/processor/Annotations.java
Outdated
Show resolved
Hide resolved
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few minor comments, most with my QE hat on. Otherwise looks good.
independent-projects/arc/runtime/src/main/java/io/quarkus/arc/impl/BeanManagerBean.java
Show resolved
Hide resolved
...ts/src/test/java/io/quarkus/arc/test/producer/illegal/NormalScopedPrimitiveProducerTest.java
Outdated
Show resolved
Hide resolved
...ojects/arc/tests/src/test/java/io/quarkus/arc/test/stereotypes/TransitiveStereotypeTest.java
Show resolved
Hide resolved
* This annotation can be used not only on bean classes, but also method and field producers (unlike pure {@code Priority}). | ||
* | ||
* @deprecated Use {@link Alternative} and {@link io.quarkus.arc.Priority}/{@link jakarta.annotation.Priority} instead | ||
* @deprecated Use {@link Alternative} and {@link jakarta.annotation.Priority} instead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 for removal, it was meant as a temporary solution until we can make use of a standard solution anyway.
* <p> | ||
* A priority specified by {@link AlternativePriority} and {@link jakarta.annotation.Priority} takes precedence. | ||
* | ||
* @deprecated use {@link jakarta.annotation.Priority} instead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could log a warning/info for this annotation to help users spot it before we get to removal, WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think anyone looks at the warnings we currently produce, and adding more is just an exercise in futility.
What we could do is fail the build if the annotation is used, but that's a pretty harsh measure :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have done that before and we can just drop the annotation if we document it properly in the migration guide.
It has been deprecated for a long time and in several Quarkus and RHBQ releases.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough. I don't think this PR is a good vehicle for that, as it affects a few Quarkus core extensions and at least one Quarkiverse extension. I filed #30963 for it.
This comment has been minimized.
This comment has been minimized.
CI failures don't look related. I filled #30988 for the first one and created a PR to disable the MongoDB test on Windows again. |
…eters with multiple bounds
…tive or array type In theory, this validation should only fail if there's an injection point that resolves to the bean. However, we do all similar validations just on the producer declaration; this commit only follows suit.
…d set per specification
…@ObservesAsync parameters
This commit fixes handling of transitive stereotypes in these 4 areas: - inheriting bean scope from stereotypes - inheriting default bean name status from stereotypes - inheriting alternative status from stereotypes - inheriting priority from stereotypes Previously, some of these areas only looked one level deep into transitive stereotypes, while others did not consider transitive stereotypes at all. They are all consistent now.
✔️ The latest workflow run for the pull request has completed successfully. It should be safe to merge provided you have a look at the other checks in the summary. |
Related to #28558
jakarta
BeanContainer
to the set of bean types of theBeanManager
built-in beanInjectionPoint.isTransient()
properlyBeanManagerImpl.resolveObserverMethods()
to return an ordered set per specification@Disposes
,@Observes
or@ObservesAsync
parameters@Dependent
beans don't have conditional observer methods@Observes[Async]
parametersio.quarkus.arc.Priority
annotationjakarta.annotation.Priority
can now be put anywhere, soio.quarkus.arc.Priority
is not needed anymore