Uses of Interface
org.springframework.context.Lifecycle
Packages that use Lifecycle
Package
Description
This package builds on the beans package to add support for
message sources and for the Observer design pattern, and the
ability for application objects to obtain resources using a
consistent API.
Annotation support for the Application Context, including JSR-250 "common"
annotations, component-scanning, and Java-based metadata for creating
Spring-managed objects.
Classes supporting the org.springframework.context package,
such as abstract base classes for ApplicationContext
implementations and a MessageSource implementation.
Scheduling convenience classes for the
java.util.concurrent
and jakarta.enterprise.concurrent packages, allowing to set up a
ThreadPoolExecutor or ScheduledThreadPoolExecutor as a bean in a Spring
context.-
Uses of Lifecycle in org.springframework.context
Subinterfaces of Lifecycle in org.springframework.contextModifier and TypeInterfaceDescriptioninterfaceSPI interface to be implemented by most if not all application contexts.interfaceStrategy interface for processing Lifecycle beans within the ApplicationContext.interfaceAn extension of theLifecycleinterface for those objects that require to be started uponApplicationContextrefresh and/or shutdown in a particular order. -
Uses of Lifecycle in org.springframework.context.annotation
Classes in org.springframework.context.annotation that implement LifecycleModifier and TypeClassDescriptionclassStandalone application context, accepting component classes as input — in particular@Configuration-annotated classes, but also plain@Componenttypes and JSR-330 compliant classes usingjakarta.injectannotations. -
Uses of Lifecycle in org.springframework.context.support
Classes in org.springframework.context.support that implement LifecycleModifier and TypeClassDescriptionclassAbstract implementation of theApplicationContextinterface.classBase class forApplicationContextimplementations which are supposed to support multiple calls toAbstractApplicationContext.refresh(), creating a new internal bean factory instance every time.classAbstractRefreshableApplicationContextsubclass that adds common handling of specified config locations.classConvenient base class forApplicationContextimplementations, drawing configuration from XML documents containing bean definitions understood by anXmlBeanDefinitionReader.classStandalone XML application context, taking the context definition files from the class path, interpreting plain paths as class path resource names that include the package path (for example, "mypackage/myresource.txt").classSpring's default implementation of theLifecycleProcessorstrategy.classStandalone XML application context, taking the context definition files from the file system or from URLs, interpreting plain paths as relative file system locations (for example, "mydir/myfile.txt").classGeneric ApplicationContext implementation that holds a single internalDefaultListableBeanFactoryinstance and does not assume a specific bean definition format.classAnApplicationContextimplementation that extendsGenericApplicationContextand implementsGroovyObjectsuch that beans can be retrieved with the dot de-reference syntax instead of usingAbstractApplicationContext.getBean(java.lang.String).classConvenient application context with built-in XML support.classApplicationContextimplementation which supports programmatic registration of beans and messages, rather than reading bean definitions from external configuration sources.Methods in org.springframework.context.support that return types with arguments of type LifecycleModifier and TypeMethodDescriptionDefaultLifecycleProcessor.getLifecycleBeans()Retrieve all applicable Lifecycle beans: all singletons that have already been created, as well as all SmartLifecycle beans (even if they are marked as lazy-init).Methods in org.springframework.context.support with parameters of type Lifecycle -
Uses of Lifecycle in org.springframework.scheduling.concurrent
Classes in org.springframework.scheduling.concurrent that implement LifecycleModifier and TypeClassDescriptionclassBase class for setting up aExecutorService(typically aThreadPoolExecutororScheduledThreadPoolExecutor).classFactoryBeanthat sets up aScheduledExecutorService(by default: aScheduledThreadPoolExecutor) and exposes it for bean references.classA simple implementation of Spring'sTaskSchedulerinterface, using a single scheduler thread and executing every scheduled task in an individual separate thread.classJavaBean that allows for configuring aThreadPoolExecutorin bean style (through its "corePoolSize", "maxPoolSize", "keepAliveSeconds", "queueCapacity" properties) and exposing it as a bean reference of its nativeExecutorServicetype.classJavaBean that allows for configuring aThreadPoolExecutorin bean style (through its "corePoolSize", "maxPoolSize", "keepAliveSeconds", "queueCapacity" properties) and exposing it as a SpringTaskExecutor.classA standard implementation of Spring'sTaskSchedulerinterface, wrapping a nativeScheduledThreadPoolExecutorand providing all applicable configuration options for it.