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

DependsOnDatabaseInitializationPostProcessor re-declares bean dependencies at native image runtime #33374

Closed
hpoettker opened this issue Nov 26, 2022 · 0 comments
Assignees
Labels
type: bug A general bug
Milestone

Comments

@hpoettker
Copy link
Contributor

This issue is motivated by the following issue in Spring Cloud Task: spring-cloud/spring-cloud-task#880

The DependsOnDatabaseInitializationPostProcessor of DatabaseInitializationDependencyConfigurer declares dependencies between beans and is executed both during AOT processing and during start-up in the native image. On the one hand, this is surprising as analyzing bean dependencies is something the AOT processing should do instead of the native runtime, if I understand correctly. On the other hand, it easily leads to circular dependencies between initializers whose detectors have the same order. If detectors have the same order then the effective order of initializers is ill-defined and can differ between AOT processing and native image runtime.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Nov 26, 2022
@wilkinsona wilkinsona added type: bug A general bug and removed status: waiting-for-triage An issue we've not yet triaged labels Nov 28, 2022
@wilkinsona wilkinsona added this to the 3.0.x milestone Nov 28, 2022
cppwfs added a commit to cppwfs/spring-cloud-task that referenced this issue Nov 28, 2022
@wilkinsona wilkinsona self-assigned this Nov 30, 2022
@wilkinsona wilkinsona modified the milestones: 3.0.x, 3.0.1 Nov 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

3 participants