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
7f64628b
Commit
7f64628b
authored
Jan 05, 2022
by
Pedro Pombeiro
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Index runners by active state
parent
fcaa5681
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
0 deletions
+18
-0
db/migrate/20220104174445_add_ci_runners_index_on_active_state.rb
...te/20220104174445_add_ci_runners_index_on_active_state.rb
+15
-0
db/schema_migrations/20220104174445
db/schema_migrations/20220104174445
+1
-0
db/structure.sql
db/structure.sql
+2
-0
No files found.
db/migrate/20220104174445_add_ci_runners_index_on_active_state.rb
0 → 100644
View file @
7f64628b
# frozen_string_literal: true
class
AddCiRunnersIndexOnActiveState
<
Gitlab
::
Database
::
Migration
[
1.0
]
disable_ddl_transaction!
INDEX_NAME
=
'index_ci_runners_on_active'
def
up
add_concurrent_index
:ci_runners
,
[
:active
,
:id
],
name:
INDEX_NAME
end
def
down
remove_concurrent_index_by_name
:ci_runners
,
INDEX_NAME
end
end
db/schema_migrations/20220104174445
0 → 100644
View file @
7f64628b
5e5e41ee4c8dc9c3fe791470862d15b8d213fcc931ef8b80937bdb5f5db20aed
\ No newline at end of file
db/structure.sql
View file @
7f64628b
...
...
@@ -25591,6 +25591,8 @@ CREATE INDEX index_ci_runner_projects_on_project_id ON ci_runner_projects USING
CREATE INDEX index_ci_runner_projects_on_runner_id ON ci_runner_projects USING btree (runner_id);
CREATE INDEX index_ci_runners_on_active ON ci_runners USING btree (active, id);
CREATE INDEX index_ci_runners_on_contacted_at_and_id_desc ON ci_runners USING btree (contacted_at, id DESC);
CREATE INDEX index_ci_runners_on_contacted_at_and_id_where_inactive ON ci_runners USING btree (contacted_at DESC, id DESC) WHERE (active = false);
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