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

Add section on AOT best practices about registering singletons #32240

Closed
snicoll opened this issue Feb 11, 2024 · 0 comments
Closed

Add section on AOT best practices about registering singletons #32240

snicoll opened this issue Feb 11, 2024 · 0 comments
Assignees
Labels
theme: aot An issue related to Ahead-of-time processing type: documentation A documentation task
Milestone

Comments

@snicoll
Copy link
Member

snicoll commented Feb 11, 2024

As #32214 has shown, registering a singleton means that it's completely ignored by AOT since AOT can't know how the bean instance has been instantiated. It's very similar to having a custom instance supplier hidden behind a lambda.

We should make it more clear in the AOT chapter that this won't work and why.

@snicoll snicoll added type: documentation A documentation task theme: aot An issue related to Ahead-of-time processing labels Feb 11, 2024
@snicoll snicoll added this to the 6.1.x milestone Feb 11, 2024
@snicoll snicoll self-assigned this Feb 11, 2024
@snicoll snicoll changed the title Add section on AOT best practices about registering singletons or a Bean Add section on AOT best practices about registering singletons Feb 11, 2024
@snicoll snicoll modified the milestones: 6.1.x, 6.1.4 Feb 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
theme: aot An issue related to Ahead-of-time processing type: documentation A documentation task
Projects
None yet
Development

No branches or pull requests

1 participant