Allow to set the phase for MessageListenerContainer related to the SmartLifecycle interface on 3.0.0+ #693
Labels
component: sqs
SQS integration related issue
type: enhancement
Smaller enhancement in existing integration
Type: Feature
Is your feature request related to a problem? Please describe.
With previous versions of Spring Could AWS (No Spring Boot 3), we had troubles with the graceful shutdown process in Spring Boot. We have an application with the following components:
Seems like when the application is shutting down, SQS components and Quartz Scheduler components, have the same
SmartLifecycle.phase
, and they collide, causing Quartz to not shutting down completely, and letting some crons in the database corrupted.The workaround we found was the following:
Moving SQS components one phase before, guarantee SQS shutdowns first, and later, Quartz.
Describe the solution you'd like
A way to set the phase for the SmartLifecycle interface for 3.0.0+
Describe alternatives you've considered
Additional context
I will try to create a minimal project to reproduce the issue, but it is environment dependent, not sure I can make it.
The text was updated successfully, but these errors were encountered: