Add seats_in_use and seats_owed to gitlab_subscriptions
What does this MR do?
Add seats_in_use and seats_owed to gitlab_subscriptions
table for data warehouse analysis.
Later MRs would store calculated values in these columns.
Part of customers-gitlab-com#1641 (closed)
Migration
== 20200827085101 AddSeatsCurrentlyInUseInGitlabSubscriptions: migrating ======
-- add_column(:gitlab_subscriptions, :seats_in_use, :integer, {:default=>0, :null=>false})
-> 0.0040s
-- add_column(:gitlab_subscriptions, :seats_owed, :integer, {:default=>0, :null=>false})
-> 0.0017s
== 20200827085101 AddSeatsCurrentlyInUseInGitlabSubscriptions: migrated (0.0227s)
== 20200827085101 AddSeatsCurrentlyInUseInGitlabSubscriptions: reverting ======
-- remove_column(:gitlab_subscriptions, :seats_in_use)
-> 0.0033s
-- remove_column(:gitlab_subscriptions, :seats_owed)
-> 0.0008s
== 20200827085101 AddSeatsCurrentlyInUseInGitlabSubscriptions: reverted (0.0180s)
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry - [-] Documentation (if required)
-
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. -
Informed Infrastructure department of a default or new setting change, if applicable per definition of done
Edited by Mark Chao