Commit Graph

17 Commits

Author SHA1 Message Date
Evan Read d98560c1f5 Make unordered lists conform to styleguide
- Also makes other minor Markdown fixes that were near the main fixes.
2019-01-08 12:21:09 +10:00
Yorick Peterse 40ad7d5d7a
Fix ActiveRecord::Migration deprecations
Extending from ActiveRecord::Migration is deprecated, but was still used
in a bunch of places.
2018-12-12 16:38:40 +01:00
Brett Walker b0be58a1b3 Resolve "CE documentation is not CommonMark compliant" 2018-09-06 16:52:18 +00:00
Yorick Peterse 91b752dce6
Respond to DB health in background migrations
This changes the BackgroundMigration worker so it checks for the health
of the DB before performing a background migration. This in turn allows
us to reduce the minimum interval, without having to worry about blowing
things up if we schedule too many migrations.

In this setup, the BackgroundMigration worker will reschedule jobs as
long as the database is considered to be in an unhealthy state. Once the
database has recovered, the migration can be performed.

To determine if the database is in a healthy state, we look at the
replication lag of any replication slots defined on the primary. If the
lag is deemed to great (100 MB by default) for too many slots, the
migration is rescheduled for a later point in time.

The health checking code is hidden behind a feature flag, allowing us to
disable it if necessary.
2018-08-06 15:20:36 +02:00
Oswaldo Ferreira 378610372f Add points regarding background migrations on huge tables 2018-07-24 12:39:52 -03:00
Pascal Borreli 12e3eff462 Fixed typos 2018-04-27 08:50:05 +00:00
Sean McGivern 3772310423 Add more detail to cleanup steps for background migrations
1. We can't just steal from the queue, in case there was a problem with Sidekiq.
2. We need to consider import / export.
2018-04-18 11:06:59 +01:00
Bob Van Landuyt 917fb1744c [docs] Info rescheduling background migrations 2018-02-08 09:44:59 +01:00
Ville Skyttä 0cbbb08e79 doc: Spelling fixes 2018-01-19 12:09:59 +02:00
Douwe Maan 1e6ca3c41e Consistently schedule Sidekiq jobs 2017-12-05 11:59:39 +01:00
Sean McGivern 989ccd7171 Document manual cleanup after background migration stealing 2017-09-25 12:48:07 +01:00
Yorick Peterse ea2d0c4861
Update the update guides for background migrations
The introduction of background migrations means some of our requirements
for online upgrades have to be adjusted / clarified.

See https://gitlab.com/gitlab-org/gitlab-ce/issues/35939 for more
information.
2017-08-04 13:34:37 +02:00
Grzegorz Bizon 433b6fed29 Copy-edit background migrations guidelines 2017-07-21 13:19:35 +02:00
Grzegorz Bizon 367a895511 Extend background migration development guidelines 2017-07-20 13:46:13 +02:00
Grzegorz Bizon 4fa822ae9d Improve code examples in background migrations docs 2017-07-07 15:08:15 +02:00
Grzegorz Bizon 945cdf326e Make it possible to schedule bg migrations in bulk 2017-07-07 15:08:15 +02:00
Yorick Peterse d83ee2bbd1
Add the ability to perform background migrations
Background migrations can be used to perform long running data
migrations without these blocking a deployment procedure.

See MR https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/11854 for
more information.
2017-06-12 13:24:04 +02:00