jhipster.github.io
jhipster.github.io copied to clipboard
Adds extra step in instruction for Database updates with the Maven liquibase:diff goal
I want to propose an addition to the Documentation, specifically to
https://www.jhipster.tech/development/ , section: Modify your JPA entity (add a field, a relationship, etc.)
If you modify your entity, for example, you add a new field, then, the new field is added to the
config/liquibase/changelog/DATE_added_entity_ENTITY_NAME.xml
So when the liquibase:diff goal is called, and a new changelog is added such as
<changeSet author="poolebu (generated)" id="1618764540135-3" >
<addColumn tableName="ENTITY_NAME">
<column name="NEW_COLUMN" type="bit" defaultValueBoolean="true"/>
</addColumn>
</changeSet>
Then the changesets conflict.
This commit has my proposal of adding an extra step to the instructions for using the workflow.
I wonder if this procedure still makes sense with JHipster 7 new feature: incremental changelogs?
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.
I wonder if this procedure still makes sense with JHipster 7 new feature: incremental changelogs?
for records, I guess yes, for people that are < JHipster 7 or still want to have a "manual" solution. Maybe we can link the incremental doc here to suggest using it instead.
I covered that in a blog post: https://dev.to/entando/how-to-use-liquibase-to-update-the-schema-of-your-jhipster-application-1cm3
I think it still makes sense to add a note in the documentation.
@poolebu could you please accept the CLA, so I can merge the PR?
@poolebu Can you please sign the CLA so we can merge your PR?