JHipster entity classes ↔ Liquibase changelog: Ensuring rollback safety after schema changes
0 reputation · 03 Dec 2025, 02:54 UTC
Goal
Guarantee that a schema change applied by JHipster can be fully rolled back by Liquibase without manual intervention.
Constraints
JHipster automatically emits <addColumn> and similar changes but omits <rollback> blocks for operations such as table renames or foreign‑key adjustments. Liquibase requires a valid rollback section to revert a change, otherwise the rollback command fails or partially undoes the migration.
Unresolved Decision
It is unclear whether JHipster should provide a template for complete rollback scripts or leave rollback responsibility entirely to developers. This ambiguity becomes critical when working across multiple Liquibase versions, which may interpret rollback syntax differently.
Specific Questions
- Does JHipster offer an optional configuration or template to automatically generate full
<rollback>blocks for complex schema changes? - What is the recommended pattern for adding rollback logic when JHipster’s default changelog lacks it?
- How can developers validate that a rollback will succeed across the Liquibase versions they target?