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
772fee38
Commit
772fee38
authored
Apr 16, 2020
by
Alina Mihaila
Committed by
Andreas Brandl
Apr 16, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove redundant index on creator_id and created_at from projects
parent
9bf7a9ba
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
2 deletions
+24
-2
changelogs/unreleased/213800-remove-redundant-index-from-projects.yml
...nreleased/213800-remove-redundant-index-from-projects.yml
+5
-0
db/migrate/20200414144547_remove_index_projects_on_creator_id_and_created_at_from_projects.rb
...ex_projects_on_creator_id_and_created_at_from_projects.rb
+18
-0
db/structure.sql
db/structure.sql
+1
-2
No files found.
changelogs/unreleased/213800-remove-redundant-index-from-projects.yml
0 → 100644
View file @
772fee38
---
title
:
Remove redundant index from projects table
merge_request
:
29507
author
:
type
:
performance
db/migrate/20200414144547_remove_index_projects_on_creator_id_and_created_at_from_projects.rb
0 → 100644
View file @
772fee38
# frozen_string_literal: true
class
RemoveIndexProjectsOnCreatorIdAndCreatedAtFromProjects
<
ActiveRecord
::
Migration
[
6.0
]
include
Gitlab
::
Database
::
MigrationHelpers
DOWNTIME
=
false
INDEX_NAME
=
'index_projects_on_creator_id_and_created_at'
disable_ddl_transaction!
def
up
remove_concurrent_index_by_name
:projects
,
INDEX_NAME
end
def
down
add_concurrent_index
:projects
,
[
:creator_id
,
:created_at
],
name:
INDEX_NAME
end
end
db/structure.sql
View file @
772fee38
...
...
@@ -9927,8 +9927,6 @@ CREATE INDEX index_projects_api_vis20_updated_at ON public.projects USING btree
CREATE
INDEX
index_projects_on_created_at_and_id
ON
public
.
projects
USING
btree
(
created_at
,
id
);
CREATE
INDEX
index_projects_on_creator_id_and_created_at
ON
public
.
projects
USING
btree
(
creator_id
,
created_at
);
CREATE
INDEX
index_projects_on_creator_id_and_created_at_and_id
ON
public
.
projects
USING
btree
(
creator_id
,
created_at
,
id
);
CREATE
INDEX
index_projects_on_creator_id_and_id
ON
public
.
projects
USING
btree
(
creator_id
,
id
);
...
...
@@ -13178,6 +13176,7 @@ COPY "schema_migrations" (version) FROM STDIN;
20200408175424
20200409211607
20200410232012
20200414144547
20200415160722
20200415161021
20200415161206
...
...
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