Skip to content

If the JVM is killed while refresh is in progress, the shutdown hook does not close the context #23625

@StoffelCPR

Description

@StoffelCPR

Heyo,

Problem

We currently have an Issue with spring-boot and liquibase.

We are using the integrated liquibase to manage our databases and we are using Chef to deploy.
After having databaseloglock issue we found out that our deployment process triggers a SIGTERM (Graceful shutdown) but the application shuts down immediately, like a kill, without exiting liquibase properly.

That liquibase has itself no proper shutdown/error mechanism is their problem and is under discussion in the following issue:
liquibase/liquibase#1453

But that liquibase is running without the spring-applications shutdown hook is another thing.

Expected behavior

When I use spring-boot and the integrated liquibase I'd expect that spring manages everything, including liquibase.

Spring does register a ShutdownHook after the initalization is completed but liquibase runs during startup.

There should be a shutdown hook first and that shutdown hook should trigger a liquibase shutdown or wait for spring to successfully initialize before commencing the shutdown.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions