Commit 1ca2b632 authored by Tiger Watson's avatar Tiger Watson

Merge branch '338054-deployments-cleanup-bigint-conversion' into 'master'

Cleanup bigint conversion for deployments

See merge request gitlab-org/gitlab!69719
parents 49edd888 dc6dac21
# frozen_string_literal: true
class CleanupBigintConversionForDeployments < Gitlab::Database::Migration[1.0]
disable_ddl_transaction!
TABLE = :deployments
# rubocop:disable Migration/WithLockRetriesDisallowedMethod
def up
with_lock_retries do
cleanup_conversion_of_integer_to_bigint(TABLE, :deployable_id)
end
end
# rubocop:enable Migration/WithLockRetriesDisallowedMethod
def down
restore_conversion_of_integer_to_bigint(TABLE, :deployable_id)
end
end
d02cc8e136f1d761a34c7c585a3fe2b8c3bc3bca67e0e45f950248a5fad36a24
\ No newline at end of file
......@@ -89,15 +89,6 @@ BEGIN
END;
$$;
CREATE FUNCTION trigger_77f5e1d20482() RETURNS trigger
LANGUAGE plpgsql
AS $$
BEGIN
NEW."deployable_id_convert_to_bigint" := NEW."deployable_id";
RETURN NEW;
END;
$$;
CREATE FUNCTION trigger_8487d4de3e7b() RETURNS trigger
LANGUAGE plpgsql
AS $$
......@@ -13225,7 +13216,6 @@ CREATE TABLE deployments (
tag boolean NOT NULL,
sha character varying NOT NULL,
user_id integer,
deployable_id_convert_to_bigint integer,
deployable_type character varying,
created_at timestamp without time zone,
updated_at timestamp without time zone,
......@@ -27312,8 +27302,6 @@ CREATE TRIGGER trigger_51ab7cef8934 BEFORE INSERT OR UPDATE ON ci_builds_runner_
CREATE TRIGGER trigger_542d6c2ad72e BEFORE INSERT OR UPDATE ON ci_builds_metadata FOR EACH ROW EXECUTE FUNCTION trigger_542d6c2ad72e();
CREATE TRIGGER trigger_77f5e1d20482 BEFORE INSERT OR UPDATE ON deployments FOR EACH ROW EXECUTE FUNCTION trigger_77f5e1d20482();
CREATE TRIGGER trigger_8487d4de3e7b BEFORE INSERT OR UPDATE ON ci_builds_metadata FOR EACH ROW EXECUTE FUNCTION trigger_8487d4de3e7b();
CREATE TRIGGER trigger_91dc388a5fe6 BEFORE INSERT OR UPDATE ON dep_ci_build_trace_sections FOR EACH ROW EXECUTE FUNCTION trigger_91dc388a5fe6();
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment