Managing schema changes on Cloud Spanner using Liquibase
We’re very happy to announce that you can now use Liquibase’s open-source database devops library to manage and automate schema changes in Cloud Spanner. The availability of Liquibase Cloud Spanner extension beta version 1.0 brings all of Liquibase’s CI/CD benefits to Spanner.
You can find the source and detailed information in GitHub here: cloudspannerecosystem/liquibase-spanner
The following change types are supported by the extension: createTable, dropTable, addColumn, modifyDataType, addNotNullConstraint, dropColumn, createIndex, dropIndex, addForeignKeyConstraint, dropForeignKeyConstraint, dropAllForeignKeyConstraints, addLookupTable, insert, update, loadData, and loadUpdateData.
ChangeTypes are all tested as unit tests, with the Spanner emulator, and with a real Spanner.
It includes the following:
create-schema.yaml: Create for Singers and Albums tables, including interleaved tables, column options, and indexes.
load-data-singers.yaml: Load data into Singers table from CSV.
load-update-data-singers.yaml: Insert/update Singers table from CSV.
add-lookup-table-singers-countries.yaml: Create Countries table as a foreign key from Country field in Singers.
modify-data-type-singers-lastname.yaml: Alter datatype in Singers LastName column.
insert.yaml: Insert rows into Singers table.
delete.yaml: Delete rows from Singers.
update.yaml: Update rows in Singers.
Related Google News:
- Architect your data lake on Google Cloud with Data Fusion and Composer February 19, 2021
- Black History Month: Celebrating the success of Black founders with Google Cloud: Get Optimal Tech February 19, 2021
- Changes to information visibility in Meet quality tool, Meet audit log, and Reports API February 18, 2021
- New framework expands Google Cloud access globally February 18, 2021
- Signify chooses Google Cloud IoT Core to power Philips Hue smart lighting February 18, 2021
- New in Google Cloud VMware Engine: improved reach, networking and scale February 18, 2021
- New to Google Cloud? Here are a few training options to help you get started February 17, 2021
- Introducing Cloud Domains: Easily register and manage custom domains February 17, 2021