Spaces
Automatically delete unused tables

Automatically delete unused tables

Y42 keeps the materialization of each physical UUID table within the DWH, allowing you to easily rollback using the Virtual Data Builds mechanics. By default, these tables are kept for 30 days in your data warehouse. You can customize the timeframe for when the physical UUID tables should be deleted.

The expiration logic for deleting tables is based on two criteria:

  1. The job is older than 30 days or older than what the user has configured.
  2. It is not the latest valid job run on any existing branch's head

Let's walk through an example to illustrate the expiration logic: You have a model with a successful job run A on main and branch out to dev. Job run A is the latest valid job on both branches. After making changes on main, you run two more successful jobs (job run B and job run C) of the same model. After 30 days or a custom-configured timeframe, the expiration job will assess which jobs to expire:

  • Job run A won't be expired, because it's still the latest valid job on the dev branch. ✅
  • Job run C won't be expired, because it's the latest valid job on the main branch. ✅
  • However, job run B will be expired, as it's not the latest valid job on any existing branch. ❌
Asset's expired status

Asset's expired status