Property-driven onRefresh checkpoint during application context bootstrap #30606
Labels
in: core
Issues in core modules (aop, beans, core, context, expression)
type: enhancement
A general enhancement
Milestone
In addition to the flexible CRaC lifecycle integration in #30242, allowing for custom checkpoints, we have identified a common checkpoint option out of the box: in
LifecycleProcessor.onRefresh
, right before the lifecycle start phase, with all non-lazy beans initialized but no async workers having started yet. No actual stopping and restarting will be necessary at that point yet, in contrast to later checkpoints, making this option attractive for fast bootstrapping (just without any warming up beyond that).A "spring.context.checkpoint" property with an "onRefresh" value could trigger such a checkpoint automatically. This can easily be used in application-specific build arrangements. The property will only trigger the checkpoint; the inclusion and distribution of the checkpoint image file is up to the individual application then.
The text was updated successfully, but these errors were encountered: