diff options
author | Rémy Coutable <remy@rymai.me> | 2016-07-18 08:26:43 +0000 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-07-18 08:26:43 +0000 |
commit | f1083ba1f6e4ff0c01d5e08b2a6c0b1f9b5a9b9a (patch) | |
tree | 1fff55ef67c0dadb5f77cf138d2c0cfd291b2b21 /db/migrate | |
parent | 7af92af5fe2a7c5c4be91d0d6daea61fc032d6f4 (diff) | |
parent | 9d72d902cf21c786b871eced12609a793596cf29 (diff) | |
download | gitlab-ce-f1083ba1f6e4ff0c01d5e08b2a6c0b1f9b5a9b9a.tar.gz |
Merge branch 'track-pipeline-user' into 'master'
Track a user who creates a Pipeline
## What does this MR do?
This adds additional column to pipelines to track user who is creating pipelines.
## Why was this MR needed?
This is to make it possible to show all pipelines created by specific user and to later solve: https://gitlab.com/gitlab-org/gitlab-ce/issues/18054
## What are the relevant issue numbers?
Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/18992
- [ ] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added
- [ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)
- [ ] API support added
- Tests
- [ ] Added for this feature/bug
- [ ] All builds are passing
- [ ] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides)
- [ ] Branch has no merge conflicts with `master` (if you do - rebase it please)
- [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits)
See merge request !5272
Diffstat (limited to 'db/migrate')
-rw-r--r-- | db/migrate/20160715132507_add_user_id_to_pipeline.rb | 7 | ||||
-rw-r--r-- | db/migrate/20160715134306_add_index_for_pipeline_user_id.rb | 7 |
2 files changed, 14 insertions, 0 deletions
diff --git a/db/migrate/20160715132507_add_user_id_to_pipeline.rb b/db/migrate/20160715132507_add_user_id_to_pipeline.rb new file mode 100644 index 00000000000..af0461c4daf --- /dev/null +++ b/db/migrate/20160715132507_add_user_id_to_pipeline.rb @@ -0,0 +1,7 @@ +class AddUserIdToPipeline < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + + def change + add_column :ci_commits, :user_id, :integer + end +end diff --git a/db/migrate/20160715134306_add_index_for_pipeline_user_id.rb b/db/migrate/20160715134306_add_index_for_pipeline_user_id.rb new file mode 100644 index 00000000000..e09caa0e6d7 --- /dev/null +++ b/db/migrate/20160715134306_add_index_for_pipeline_user_id.rb @@ -0,0 +1,7 @@ +class AddIndexForPipelineUserId < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + + def change + add_concurrent_index :ci_commits, :user_id + end +end |