Commit Graph

12 Commits

Author SHA1 Message Date
GitLab Bot e464f195ff Add latest changes from gitlab-org/gitlab@master 2019-10-14 12:06:14 +00:00
Thong Kuah d6b952ad3e
Add frozen_string_literal to spec/workers
Adds `# frozen_string_literal: true` to spec/workers ruby files
2019-04-01 13:35:22 -03:00
Bob Van Landuyt f3fba178b9 Remove the `ForkedProjectLink` model
This removes the `ForkedProjectLink` model that has been replaced by
the `ForkNetworkMember` and `ForkNetwork` combination. All existing
relations have been adjusted to use these new models.

The `forked_project_link` table has been dropped.

The "Forks" count on the admin dashboard has been updated to count all
`ForkNetworkMember` rows and deduct the number of `ForkNetwork`
rows. This is because now the "root-project" of a fork network also
has a `ForkNetworkMember` row. This count could become inaccurate when
the root of a fork network is deleted.
2018-10-19 11:57:20 +02:00
Tiago Botelho f250fb1672 Makes namespaceless project destroy worker spec not depend on a specific migration version 2018-04-30 09:54:44 +01:00
Dmitriy Zaporozhets 6f152fd193
Update specs to respect Project#namespace_id not null constraint
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2018-03-01 16:09:09 +02:00
Bob Van Landuyt e8ca579d88 Add a project forks spec helper
The helper creates a fork of a project with all provided attributes,
but skipping the creation of the repository on disk.
2017-10-07 11:46:23 +02:00
Toon Claes 2074f39a47 Migration to remove pending delete projects with non-existing namespace
There might be some projects where the namespace was removed, but the
project wasn't. For these the projects still have a `namespace_id`
set. So this adds a post-deploy migration remove all projects that are
pending delete, and have a `namespace_id` that is non-existing.
2017-08-22 14:29:54 +02:00
Gabriel Mazetto d17a7be830 Refactor project and storage types 2017-08-22 06:33:20 +02:00
Robert Speicher 72a7b30c9f Change all `:empty_project` to `:project` 2017-08-02 17:47:31 -04:00
Gabriel Mazetto 597e619080 Rename ensure_dir_exist -> ensure_storage_path_exist 2017-08-01 07:44:25 +02:00
Toon Claes 37a79409d4 No user needed to cleanup namespaceless pending delete projects
Since this is a cleanup, ran by a post-deploy, there is no need to lookup the
admin to run the cleanup.
2017-05-10 15:01:27 +02:00
Toon Claes 0ad80cab40 Use worker to destroy namespaceless projects in post-deploy
Destroying projects can be very time consuming. So instead of destroying them in
the post-deploy, just schedule them and make Sidekiq do the hard work.

They are scheduled in batches of 5000 records. This way the number of database
requests is limited while also the amount data read to memory is limited.
2017-05-10 15:01:27 +02:00