Skip to content

Add Freeze Period Model

Sean Carroll requested to merge 24295-freeze-period-db-changes into master

What does this MR do?

As part of the Deploy Freeze functionality, this MR adds the Ci::FreezePeriod model and associated objects.

DB Migration and Rollback

As per this document

Add the output of both migrating and rolling back for all migrations into the MR description

  • Ensure the down method reverts the changes in db/structure.sql
  • Update the migration output whenever you modify the migrations during the review process

Migrate

❯ be rails db:migrate
== 20200408125046 CreateCiFreezePeriods: migrating ============================
-- create_table(:ci_freeze_periods)
   -> 0.0228s
== 20200408125046 CreateCiFreezePeriods: migrated (0.0228s) ===================

Rollback

❯ be rake db:rollback STEP=1
== 20200408125046 CreateCiFreezePeriods: reverting ============================
-- drop_table(:ci_freeze_periods)
   -> 0.0207s
== 20200408125046 CreateCiFreezePeriods: reverted (0.0229s) ===================

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • [-] Label as security and @ mention @gitlab-com/gl-security/appsec
  • [-] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • [-] Security reports checked/validated by a reviewer from the AppSec team

Part of #214328 (closed)

Edited by Mayra Cabrera

Merge request reports