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

Contribute init/destroy lifecycle introspection hints for registered beans #29246

Closed
bclozel opened this issue Oct 3, 2022 · 3 comments
Closed
Assignees
Labels
in: core Issues in core modules (aop, beans, core, context, expression) theme: aot An issue related to Ahead-of-time processing type: enhancement A general enhancement
Milestone

Comments

@bclozel
Copy link
Member

bclozel commented Oct 3, 2022

Once #29205 is applied, several tests will start failing as Framework consistently uses ReflectionUtils#findMethod on registered beans for various reasons (finding init/detroy methods by name, looking for annotations). The existing infrastructure already adds targeted introspection/invocation hints, but this change takes a broader approach where we recognize that beans are very likely to be introspected by framework infrastructure.

@bclozel bclozel added in: core Issues in core modules (aop, beans, core, context, expression) type: enhancement A general enhancement theme: aot An issue related to Ahead-of-time processing labels Oct 3, 2022
@bclozel bclozel added this to the 6.0.0-RC1 milestone Oct 3, 2022
@bclozel bclozel self-assigned this Oct 3, 2022
@bclozel bclozel closed this as completed in 332961f Oct 3, 2022
@bclozel
Copy link
Member Author

bclozel commented Oct 3, 2022

Temporarily reverting this change and rescheduling to RC2 for now, as this triggers a particular GraalVM issue and breaks existing native applications.

@bclozel bclozel reopened this Oct 3, 2022
@bclozel bclozel modified the milestones: 6.0.0-RC1, 6.0.0-RC2 Oct 3, 2022
bclozel added a commit that referenced this issue Oct 3, 2022
bclozel added a commit that referenced this issue Oct 3, 2022
This new hint contribution triggers a GraalVM bug and breaks native
compilation for several samples, we need to temporarily revert this
change until a fix is available in GraalVM.

See gh-29246
@bclozel bclozel modified the milestones: 6.0.0-RC2, 6.0.x Oct 18, 2022
@bclozel bclozel modified the milestones: 6.0.x, 6.1.x Feb 21, 2023
@bclozel
Copy link
Member Author

bclozel commented Mar 7, 2023

See oracle/graal#5171 and oracle/graal#6139 for upcoming changes in GraalVM. Because this change is likely to land in 23.0.0, I'm rescheduling to 6.0.8.

@bclozel bclozel modified the milestones: 6.1.x, 6.0.8 Mar 7, 2023
@bclozel bclozel changed the title Contribute introspection hints on registered beans Contribute init/destroy lifecycle introspection hints for registered beans Mar 30, 2023
@bclozel
Copy link
Member Author

bclozel commented Mar 30, 2023

Reopening for two reasons:

@bclozel bclozel reopened this Mar 30, 2023
bclozel added a commit that referenced this issue Mar 30, 2023
sdeleuze added a commit that referenced this issue Apr 28, 2023
After b374824 related
to gh-29246, `"queryAllDeclaredMethods": true` is now added
on all registered beans.

This legit change triggers oracle/graal#6510. This
commit workarounds this GraalVM bug, and should be
removed once the GraalVM fix has reached a wide enough
audience.

Closes gh-30383
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) theme: aot An issue related to Ahead-of-time processing type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

1 participant