Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
aa8ee780
Commit
aa8ee780
authored
Sep 16, 2021
by
Bala Kumar
Committed by
Adam Hegyi
Sep 16, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add index for selecting resource_group from ci_builds
Changelog: performance
parent
4c04855e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
0 deletions
+16
-0
db/post_migrate/20210915202900_prepare_index_resource_group_status_commit_id_for_ci_builds.rb
...re_index_resource_group_status_commit_id_for_ci_builds.rb
+15
-0
db/schema_migrations/20210915202900
db/schema_migrations/20210915202900
+1
-0
No files found.
db/post_migrate/20210915202900_prepare_index_resource_group_status_commit_id_for_ci_builds.rb
0 → 100644
View file @
aa8ee780
# frozen_string_literal: true
class
PrepareIndexResourceGroupStatusCommitIdForCiBuilds
<
Gitlab
::
Database
::
Migration
[
1.0
]
INDEX_NAME
=
'index_ci_builds_on_resource_group_and_status_and_commit_id'
def
up
prepare_async_index
:ci_builds
,
[
:resource_group_id
,
:status
,
:commit_id
],
where:
'resource_group_id IS NOT NULL'
,
name:
INDEX_NAME
end
def
down
unprepare_async_index_by_name
:ci_builds
,
INDEX_NAME
end
end
db/schema_migrations/20210915202900
0 → 100644
View file @
aa8ee780
cc8f1bea8c722dfa06fc23a3dbaaacd7f1b7c5f7b529ebfab34b7c7c38e5db79
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment