-
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
gRPC - archive with a MutinyBean implementor is a bean archive #19902
Conversation
- an application archive that contains a MutinyBean implementor is an additional bean archive - resolves quarkusio#19864
* By default, only explict/implicit bean archives (as defined by the spec) are considered during the bean discovery. However, | ||
* extensions can register a logic to identify additional bean archives. | ||
*/ | ||
public final class BeanArchivePredicateBuildItem extends MultiBuildItem { |
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'm not sure about the name of this build item. The other alternative was AdditionalBeanArchiveBuildItem
but given the fact that the item does not represent a bean archive but a logic that identifies a bean archive I decided for BeanArchivePredicateBuildItem
.
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 think BeanArchivePredicateBuildItem
makes sense.
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.
Test for the original issue would be nice, but I see how that's not straightforward to add.
I don't know of a way how to test it TBH... |
@Override | ||
public boolean test(ApplicationArchive archive) { | ||
// Every archive that contains a generated implementor of MutinyBean is considered a bean archive | ||
return !archive.getIndex().getKnownDirectImplementors(GrpcDotNames.MUTINY_BEAN).isEmpty(); |
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.
is archive.getIndex()
always != null
?
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 believe so. But it's a good point that we could be more defensive here...
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.
Hm, we don't test the nullability in the BeanArchiveProcessor
either. So it's probably OK.
nice! Thanks Martin! |
This workflow status is outdated as a new workflow run has been triggered. Failing Jobs - Building 13bc4d2
Full information is available in the Build summary check run. Failures⚙️ JVM Tests - JDK 11 Windows #- Failing: extensions/amazon-lambda/deployment
! Skipped: docs extensions/amazon-lambda-http/deployment extensions/amazon-lambda-rest/deployment and 6 more 📦 extensions/amazon-lambda/deployment✖
|
Failing Jobs - Building 13bc4d2
Full information is available in the Build summary check run. Failures⚙️ JVM Tests - JDK 11 Windows #- Failing: extensions/vertx-http/deployment
! Skipped: core/test-extension/deployment docs extensions/agroal/deployment and 287 more 📦 extensions/vertx-http/deployment✖
|
Windows CI failures do not seem to be related. |
No description provided.