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
2be54f1b
Commit
2be54f1b
authored
Jul 11, 2018
by
Mark Chao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix doc for large table column rename
parent
c2a0a3ab
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
doc/development/what_requires_downtime.md
doc/development/what_requires_downtime.md
+2
-2
No files found.
doc/development/what_requires_downtime.md
View file @
2be54f1b
...
@@ -198,14 +198,14 @@ And that's it, we're done!
...
@@ -198,14 +198,14 @@ And that's it, we're done!
## Changing The Schema For Large Tables
## Changing The Schema For Large Tables
While
`change_column_type_concurrently`
and
`rename_column_concurrently`
can be
While
`change_column_type_concurrently`
and
`rename_column_concurrently`
can be
used for changing the schema of a table without downtime it doesn't work very
used for changing the schema of a table without downtime
,
it doesn't work very
well for large tables. Because all of the work happens in sequence the migration
well for large tables. Because all of the work happens in sequence the migration
can take a very long time to complete, preventing a deployment from proceeding.
can take a very long time to complete, preventing a deployment from proceeding.
They can also produce a lot of pressure on the database due to it rapidly
They can also produce a lot of pressure on the database due to it rapidly
updating many rows in sequence.
updating many rows in sequence.
To reduce database pressure you should instead use
To reduce database pressure you should instead use
`change_column_type_using_background_migration`
or
`rename_column_
concurrently
`
`change_column_type_using_background_migration`
or
`rename_column_
using_background_migration
`
when migrating a column in a large table (e.g.
`issues`
). These methods work
when migrating a column in a large table (e.g.
`issues`
). These methods work
similarly to the concurrent counterparts but uses background migration to spread
similarly to the concurrent counterparts but uses background migration to spread
the work / load over a longer time period, without slowing down deployments.
the work / load over a longer time period, without slowing down deployments.
...
...
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