This metric is measuring number of tables which are not backed up since X days from last observed change.
Metric is implemented as a BigQuery query, which uses data about modifications of tables (collected by GCP Census) and data about existing backups.
This metric is measuring number of tables that were not modified since 3 days and which last available backup does not contain the same metadata as source.
Metric is implemented as a BigQuery query, which list all tables where last modification was over 3 days ago and joins them with last available Datastore backups metadata using Cloud Datastore export and then compare the number of bytes and rows between source table and its backup (collected by GCP Census).
To measure SLI, please follow all the steps below:
- Install GCP Census application that periodical collects metadata about BigQuery tables.
- Configure Cloud Datastore export, which periodically exports backup metadata and stores it in BigQuery,
- Install and initialise Terraform as in terraform setup file.
Additionally run following command to export census project id:
export TF_VAR_gcp_census_project=${GCP_CENSUS_PROJECT_ID}
- Create all views/tables by running following command from terraform/sli folder
terraform apply
- Deploy SLO service (it's a separate GAE service):
gcloud app deploy --project ${BBQ_PROJECT_ID} slo-service.yaml
- Configure periodical SLI export by adding the following cron entry
- description: SLI X days calculation url: /cron/sli/calculate schedule: every 6 hours from 00:25 to 23:59 retry_parameters: job_retry_limit: 5 target: slo-service
- Deploy all cron entries:
gcloud app deploy --project ${BBQ_PROJECT_ID} config/cron.yaml
All SLI results can be queried from SLI_history.SLI_backup_creation_latency_view
and SLI_backup_quality_views.SLI_quality
views.