Dremio/Liquibase integration - Read/Write area

We deploy Dremio views in multiple environments and manage the schemas in source control. We’ve messed with flyway and liquibase for relational databases (postgres, etc.), but they didn’t work out for tools like Hive and Dremio - we use external tables to point to prepared marts in Hive, so it’s a lot like Dremio in our world.

Since we deploy these views/tables in multiple environments, we’ve made templates out of our DDL statements and checked those into source control in a structure that looks suspiciously like the flyway migrate sql structure. Rather than having an actual table with the version, we populate a file to indicate what schema we’re on, and when it’s time to upgrade we perform a very similar set of operations:

  1. check to see what version we think we’re on
  2. make sure the deployed schema looks like that version (see REST apis… this was less robust in dremio before those became available)
  3. perform migrations in order by populating templates and running the ddl
  4. update the version file

It’s not perfect, but it supports the familiar flow and works well enough for what we do. Recreating those steps is pretty simple in whatever scripting/programming language you like to use.

3 Likes