Skip to content
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

Produce ReflectiveClassBuildItem dynamically #219

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

mcruzdev
Copy link
Member

No description provided.

@mcruzdev mcruzdev requested a review from a team as a code owner September 20, 2024 02:19
reflectiveClasses.produce(ReflectiveClassBuildItem.builder(
DaprTopicRule.class.getName(),
DaprTopicRoutes.class.getName(),
CloudEventReader.class.getName()).build());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just wonder why these classes need to be registered for reflection only in route is not blank if I read the codes correctly?

And it seeem that io.quarkiverse.dapr.core.DaprTopicSubscription is missed here?

Copy link
Member Author

@mcruzdev mcruzdev Sep 20, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @zhfeng!

Just wonder why these classes need to be registered for reflection only in route is not blank if I read the codes correctly?

I added this because I saw that in the last PR it was necessary to add annotation to the client code after using @Route.
Can I register it even if it is not used in the native image? Is graalvm smart enough not to use the reflection statement?

And it seeem that io.quarkiverse.dapr.core.DaprTopicSubscription is missed here?

This one is produced by void reflectiveClasses(BuildProducer<ReflectiveClassBuildItem> reflectiveClassBuildProducer) method.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, in this case, it should be OK to add all of them.

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