Annotation Interface Parallel
This allows optimized startup time by allowing beans that have slow initialization paths to startup and without impacting the overall startup time of the application.
Note that beans and methods that are processed in parallel (unlike
Context scoped beans) will not initially fail the startup of the
as they may be initialized after the
ApplicationContext has started and cannot participate in
StartupEvent processing. If a parallel bean fails to startup it will by default stop the
ApplicationContext with an error unless
shutdownOnError() set to to
Parallel to methods is most useful when used in conjunction with a
ExecutableMethodProcessor. Be aware however, that the processor in this case should be thread safe as could be executed in parallel for different methods.
Optional Element SummaryModifier and TypeOptional ElementDescription
booleanThe default behaviour is to shut down the context if an error occurs on initialization.
shutdownOnErrorboolean shutdownOnErrorThe default behaviour is to shut down the context if an error occurs on initialization. Can be set false if shutdown is not required.
- Whether to shut down the application if an error occurs.