Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-04-05Remove and ignore notes.original_discussion_id columnDouwe Maan
2017-03-21Merge branch 'dz-improve-rename-projects-migration' into 'master' Yorick Peterse
Improve rename projects migration Closes #29556 See merge request !10009
2017-03-20Improve rename projects migrationDmitriy Zaporozhets
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2017-03-18All CI offline migrationsKamil Trzciński
2017-03-16Fix statements timeout in manual actions migrationGrzegorz Bizon
2017-03-15Merge branch 'test-db-rollback' into 'master' Kamil Trzciński
Add a test which would rollback db and migrate again Closes #29106 See merge request !9908
2017-03-14[Issue Sorting] Improve migrationValery Sizov
2017-03-14Added migration to reset existing relative_position for issuesValery Sizov
2017-03-13Add a test which would rollback db and migrate againLin Jen-Shin
Closes #29106
2017-03-13Merge branch 'dz-blacklist--names' into 'master' Douwe Maan
Blacklist nested groups and project names that can cause ambiguous routing for HA Closes #29324 See merge request !9898
2017-03-13Reserve few project and nested group pathsDmitriy Zaporozhets
That have wildcard routes associated and not reserved yet: artifacts, graphs, badges and refs Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2017-03-13Trigger refreshing of permissions in a migrationYorick Peterse
This migration resets `users.authorized_projects_populated` (in batches) so that active users' permissions are refreshed on the next request. This ensures that their permissions are properly stored.
2017-03-07Implement OpenID Connect identity providerMarkus Koller
2017-03-06Migrate legacy actions in post deployment migrationGrzegorz Bizon
2017-03-01Disable the inheritance column of services in DisableInvalidServiceTemplates ↵Rémy Coutable
migration The `unless defined?(Service)` was useless since in production env, models are eager loaded, thus we wouldn't disable the STI, resulting in the following error: The single-table inheritance mechanism failed to locate the subclass: 'GitlabCiService'. This error is raised because the column 'type' is reserved for storing the class in case of inheritance. Please rename this column if you didn't intend it to be used for storing the inheritance class or overwrite Service.inheritance_column to use another column for that information./opt/gitlab/embedded/service/gitlab-rails/db/post_migrate/20170211073944_disable_invalid_service_templates.rb:11:in `up' Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-02-23Revert "Prefer leading style for Style/DotPosition"Douwe Maan
This reverts commit cb10b725c8929b8b4460f89c9d96c773af39ba6b.
2017-02-23Exclude migrations from Style/MutableConstantDouwe Maan
2017-02-23Prefer leading style for Style/DotPositionDouwe Maan
2017-02-23Enable Style/MutableConstantDouwe Maan
2017-02-16Remove comments in migrationAnnabel Dunstone Gray
2017-02-16Fix borked db stuffAnnabel Dunstone Gray
2017-02-15Move migration to post_migrate; fix shortcuts_specAnnabel Dunstone Gray
2017-02-15Merge branch 'master' into 'zj-remove-deprecated-ci-service'Douwe Maan
# Conflicts: # db/schema.rb
2017-02-15Merge branch 'issue_25112' into 'master' Sean McGivern
Disable invalid service templates Closes #25112 See merge request !8850
2017-02-14Disable invalid service templatesFelipe Artur
2017-02-14Remove deprecated CI serviceZ.J. van de Weg
2017-02-14Use Gitlab::Database.with_connection_pool from !9192Lin Jen-Shin
2017-02-14Disconnect the pool after doneLin Jen-Shin
2017-02-14Use threads directly, introduce pool later:Lin Jen-Shin
Feedback: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/8987#note_22938402
2017-02-14Introduce ThreadedConnectionPool for customized poolLin Jen-Shin
This way we could reuse this pool for other migrations Feedback: * https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/8987#note_22923350 * https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/8987#note_22923365
2017-02-14Try this way to provide database connectionLin Jen-Shin
2017-02-14Use IS FALSE for both pg and mysql; Handle connectionsLin Jen-Shin
by ourselves so that even if the setting has 1 connection we could still use more connections.
2017-02-14Run two threads to improve migration running timeLin Jen-Shin
2017-02-14Remove inactive default email servicesLin Jen-Shin
Note that we no longer generate this by default. This is for clearing legacy default data.
2017-02-07Refactor migration to not require downtimeRuben Davila
2017-01-24Reject projects without namespaceZ.J. van de Weg
2017-01-24Quote class name in case it gets destroyedZeger-Jan van de Weg
2017-01-24Requeue projects pending deletionZ.J. van de Weg
There have been several bugs in the project deletion service and worker. Resulting in projects stuck in pending delete state, which limits users to create projects with the same name, keeps stale records in the database, and all kinds of other trouble. This post deployment migration requeues all these projects for deletion, in the hope that most of these could be removed by the updated code.
2017-01-11Fill missing authorized projects rowsYorick Peterse
This ensures that the project_authorizations rows exist for all users for which this data has not yet been populated. Fixes #26194
2017-01-08Remove the project_authorizations.id columnYorick Peterse
This column used to be a 32 bits integer, allowing for only a maximum of 2 147 483 647 rows. Given enough users one can hit this limit pretty quickly, as was the case for GitLab.com. Changing this type to bigint (= 64 bits) would give us more space, but we'd eventually hit the same limit given enough users and projects. A much more sustainable solution is to simply drop the "id" column. There were only 2 lines of code depending on this column being present, and neither truly required it to be present. Instead the code now uses the "project_id" column combined with the "user_id" column. This means that instead of something like this: DELETE FROM project_authorizations WHERE user_id = X AND id = Y; We now run the following when removing rows: DELETE FROM project_authorizations WHERE user_id = X AND project_id = Y; Since both user_id and project_id are indexed this should not slow down the DELETE query. This commit also removes the "dependent: destroy" clause from the "project_authorizations" relation in the User and Project models. Keeping this prevents Rails from being able to remove data as it relies on an "id" column being present. Since the "project_authorizations" table has proper foreign keys set up (with cascading removals) we don't need to depend on any Rails logic.
2017-01-06Whitelist next project names: assets, profile, publicDmitriy Zaporozhets
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2016-12-27Merge branch 'master' into 'dz-rename-reserved-project-names'Dmitriy Zaporozhets
# Conflicts: # db/schema.rb
2016-12-27Disable timeout while removing servicesZ.J. van de Weg
On GitLab.com this migration could take about 3 minutes. Disabling the statement we know we have enough time to complete this. Fixes #25976
2016-12-24Removed return from reserved project migrationYorick Peterse
This return is redundant as the query now uses "WHERE EXISTS (...)" to filter out projects without a namespace.
2016-12-24Fix parallel renaming of reserved projectsYorick Peterse
This ensures threads don't re-use the same connection object, and use fewer queries to perform the work.
2016-12-24Rename projects with reserved path namesDmitriy Zaporozhets
We cant have project with name 'project' or 'tree' anymore. This merge request containts a migration that will find and rename all projects using reserved names by adding N digit to the end of the name. Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2016-12-21Remove unused services from the databaseZ.J. van de Weg
This adds a migration to remove unused services, where the properties are empty. As the properties are empty, those do not contain any settings or other information. Fixes #25727
2016-12-16Make `ChangePersonalAccessTokensDefaultBackToEmptyArray` a "post" migration.Timothy Andrew
If we leave this as a regular migration, we could have the following flow: 1. Application knows nothing about scopes. 2. First migration runs, all existing personal access tokens have `api` scope 3. Application still knows nothing about scopes. 4. Second migration runs, all tokens created after this point have no scope 5. Application still knows nothing about scopes. 6. Tokens created at this time _should have the API scope, but instead have no scope_ 7. Application code is reloaded, application knows about scopes 8. Tokens created after this point only have no scope if the user deliberately chooses to have no scopes. Point #6 is the problem here. To avoid this, we move the second migration to a "post" migration, which runs after the application code is deployed/reloaded.
2016-11-15Fix a badly-performing migrationNick Thomas
2016-11-11Update 8.14-rc1 migrations to minimize downtime and deploy timeAlejandro Rodríguez
See https://gitlab.com/gitlab-org/gitlab-ce/issues/24386