Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
chore: drop deprecated task check run table (#8070)
Danny Xu83e5a9bce648
diff --git a/backend/migrator/migration/dev/LATEST.sql b/backend/migrator/migration/dev/LATEST.sqlindex 85440cc078..935035aa3c 100644--- a/backend/migrator/migration/dev/LATEST.sql+++ b/backend/migrator/migration/dev/LATEST.sql@@ -657,33 +657,6 @@ UPDATEON task_run FOR EACH ROWEXECUTE FUNCTION trigger_update_updated_ts();--- task check run table stores the task check run-CREATE TABLE task_check_run (- id SERIAL PRIMARY KEY,- creator_id INTEGER NOT NULL REFERENCES principal (id),- created_ts BIGINT NOT NULL DEFAULT extract(epoch from now()),- updater_id INTEGER NOT NULL REFERENCES principal (id),- updated_ts BIGINT NOT NULL DEFAULT extract(epoch from now()),- task_id INTEGER NOT NULL REFERENCES task (id),- status TEXT NOT NULL CHECK (status IN ('RUNNING', 'DONE', 'FAILED', 'CANCELED')),- type TEXT NOT NULL CHECK (type LIKE 'bb.task-check.%'),- code INTEGER NOT NULL DEFAULT 0,- comment TEXT NOT NULL DEFAULT '',- -- result saves the task check run result in json format- result JSONB NOT NULL DEFAULT '{}',- payload JSONB NOT NULL DEFAULT '{}'-);--CREATE INDEX idx_task_check_run_task_id ON task_check_run(task_id);--ALTER SEQUENCE task_check_run_id_seq RESTART WITH 101;--CREATE TRIGGER update_task_check_run_updated_ts-BEFORE-UPDATE- ON task_check_run FOR EACH ROW-EXECUTE FUNCTION trigger_update_updated_ts();--- Pipeline related END------------------------- Plan related BEGINdiff --git a/backend/migrator/migration/prod/2.8/0003##deprecate_task_check_run.sql b/backend/migrator/migration/prod/2.8/0003##deprecate_task_check_run.sqlnew file mode 100644index 0000000000..72ec638345--- /dev/null+++ b/backend/migrator/migration/prod/2.8/0003##deprecate_task_check_run.sql@@ -0,0 +1 @@+DROP TABLE task_check_run;\ No newline at end of filediff --git a/backend/migrator/migration/prod/LATEST.sql b/backend/migrator/migration/prod/LATEST.sqlindex a768950e9e..f9474f43fe 100644--- a/backend/migrator/migration/prod/LATEST.sql+++ b/backend/migrator/migration/prod/LATEST.sql@@ -656,33 +656,6 @@ UPDATEON task_run FOR EACH ROWEXECUTE FUNCTION trigger_update_updated_ts();--- task check run table stores the task check run-CREATE TABLE task_check_run (- id SERIAL PRIMARY KEY,- creator_id INTEGER NOT NULL REFERENCES principal (id),- created_ts BIGINT NOT NULL DEFAULT extract(epoch from now()),- updater_id INTEGER NOT NULL REFERENCES principal (id),- updated_ts BIGINT NOT NULL DEFAULT extract(epoch from now()),- task_id INTEGER NOT NULL REFERENCES task (id),- status TEXT NOT NULL CHECK (status IN ('RUNNING', 'DONE', 'FAILED', 'CANCELED')),- type TEXT NOT NULL CHECK (type LIKE 'bb.task-check.%'),- code INTEGER NOT NULL DEFAULT 0,- comment TEXT NOT NULL DEFAULT '',- -- result saves the task check run result in json format- result JSONB NOT NULL DEFAULT '{}',- payload JSONB NOT NULL DEFAULT '{}'-);--CREATE INDEX idx_task_check_run_task_id ON task_check_run(task_id);--ALTER SEQUENCE task_check_run_id_seq RESTART WITH 101;--CREATE TRIGGER update_task_check_run_updated_ts-BEFORE-UPDATE- ON task_check_run FOR EACH ROW-EXECUTE FUNCTION trigger_update_updated_ts();--- Pipeline related END------------------------- Plan related BEGINdiff --git a/backend/migrator/migrator_test.go b/backend/migrator/migrator_test.goindex 3c115ea99b..3d4bf346d6 100644--- a/backend/migrator/migrator_test.go+++ b/backend/migrator/migrator_test.go@@ -241,5 +241,5 @@ func TestMigrationCompatibility(t *testing.T) {func TestGetCutoffVersion(t *testing.T) {releaseVersion, err := getProdCutoffVersion()require.NoError(t, err)- require.Equal(t, semver.MustParse("2.8.2"), releaseVersion)+ require.Equal(t, semver.MustParse("2.8.3"), releaseVersion)}