summaryrefslogtreecommitdiff
path: root/app/workers/post_receive.rb
Commit message (Collapse)AuthorAgeFilesLines
* Add latest changes from gitlab-org/gitlab@15-7-stable-eev15.7.0-rc42GitLab Bot2022-12-201-2/+6
|
* Add latest changes from gitlab-org/gitlab@15-3-stable-eev15.3.0-rc42GitLab Bot2022-08-181-0/+1
|
* Add latest changes from gitlab-org/gitlab@15-2-stable-eev15.2.0-rc42GitLab Bot2022-07-201-0/+13
|
* Add latest changes from gitlab-org/gitlab@14-5-stable-eev14.5.0-rc42GitLab Bot2021-11-181-1/+0
|
* Add latest changes from gitlab-org/gitlab@14-3-stable-eev14.3.0-rc42GitLab Bot2021-09-201-1/+3
|
* Add latest changes from gitlab-org/gitlab@14-2-stable-eev14.2.0-rc42GitLab Bot2021-08-191-1/+2
|
* Add latest changes from gitlab-org/gitlab@13-12-stable-eev13.12.0-rc42GitLab Bot2021-05-191-2/+4
|
* Add latest changes from gitlab-org/gitlab@13-10-stable-eev13.10.0-rc40GitLab Bot2021-03-161-0/+1
|
* Add latest changes from gitlab-org/gitlab@13-9-stable-eev13.9.0-rc42GitLab Bot2021-02-181-0/+2
|
* Add latest changes from gitlab-org/gitlab@13-6-stable-eev13.6.0-rc42GitLab Bot2020-11-191-1/+1
|
* Add latest changes from gitlab-org/gitlab@13-5-stable-eev13.5.0-rc42GitLab Bot2020-10-211-1/+1
|
* Add latest changes from gitlab-org/gitlab@13-4-stable-eeGitLab Bot2020-09-191-10/+13
|
* Add latest changes from gitlab-org/gitlab@13-2-stable-eeGitLab Bot2020-07-201-1/+1
|
* Add latest changes from gitlab-org/gitlab@13-1-stable-eeGitLab Bot2020-06-181-0/+1
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-04-091-5/+1
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-03-121-5/+0
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-03-061-0/+5
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-03-051-28/+41
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-03-021-1/+1
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-02-191-1/+1
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2020-01-241-0/+1
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-10-301-0/+2
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-10-181-0/+2
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-10-111-16/+5
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-10-031-31/+26
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-10-031-0/+11
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-10-031-11/+11
|
* Add latest changes from gitlab-org/gitlab@masterGitLab Bot2019-09-131-0/+2
|
* Expire project caches once per push instead of once per refStan Hu2019-08-161-4/+26
| | | | | | | | | | | | | | | | | | | | | | Previously `ProjectCacheWorker` would be scheduled once per ref, which would generate unnecessary I/O and load on Sidekiq, especially if many tags or branches were pushed at once. `ProjectCacheWorker` would expire three items: 1. Repository size: This only needs to be updated once per push. 2. Commit count: This only needs to be updated if the default branch is updated. 3. Project method caches: This only needs to be updated if the default branch changes, but only if certain files change (e.g. README, CHANGELOG, etc.). Because the third item requires looking at the actual changes in the commit deltas, we schedule one `ProjectCacheWorker` to handle the first two cases, and schedule a separate `ProjectCacheWorker` for the third case if it is needed. As a result, this brings down the number of `ProjectCacheWorker` jobs from N to 2. Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/52046
* Add usage pings for source code pushesIgor2019-08-131-0/+1
| | | | Source Code Usage Ping for Create SMAU
* Only expire tag cache once per pushsh-only-flush-tags-once-per-pushStan Hu2019-08-131-0/+2
| | | | | | | | | | Previously each tag in a push would invoke the Gitaly `FindAllTags` RPC since the tag cache would be invalidated with every tag. We can eliminate those extraneous calls by expiring the tag cache once in `PostReceive` and taking advantage of the cached tags. Relates to https://gitlab.com/gitlab-org/gitlab-ce/issues/65795
* Rename branches_exist? -> includes_branches?65803-invalidate-branches-cache-on-refreshStan Hu2019-08-091-1/+1
|
* Invalidate branches cache on PostReceivePatrick Bajao2019-08-091-0/+3
| | | | | | | | | | | | | | | | Whenever `PostReceive` is enqueued, `UpdateMergeRequestsWorker` is enqueued and `MergeRequests::RefreshService` is called, it'll check if the source branch of each MR asssociated to the push exists or not via `MergeRequest#source_branch_exists?`. The said method will call `Repository#branch_exists?` which is cached in `Rails.cache`. When the cache contains outdated data and the source branch actually exists, the `MergeRequests#RefreshService` job will close associated MRs which is not correct. The fix is to expire the branches cache of the project so we have updated data during the post receive hook which will help in the accuracy of the check if we need to close associated MRs or not.
* Backport of 12014-incremental-es-wiki-updatesce-12014-incremental-es-wiki-updatesMario de la Ossa2019-06-181-8/+15
| | | | Bringing in the DB migration and some light changes for CE classes
* Add wiki size to project statisticsPeter Marko2019-05-291-0/+2
|
* Port changes for design management to CEBob Van Landuyt2019-04-291-1/+3
| | | | | | This ports the changes from https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/10462/ to CE
* Process at most 4 pipelines during pushlimit-amount-of-created-pipelinesKamil Trzciński2019-04-101-12/+15
| | | | | | | | This adds a limitation that we will try to create pipeline for at most 4 first changes (branches and tags). This does not affect processing of Pipelines for Merge Requests, as each updated MR will have associated pipeline created.
* Use Gitlab::PushOptions for `ci.skip` push optionLuke Duncalfe2019-04-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously the raw push option Array was sent to Pipeline::Chain::Skip. This commit updates this class (and the chain of classes that pass the push option parameters from the API internal `post_receive` endpoint to that class) to treat push options as a Hash of options parsed by GitLab::PushOptions. The GitLab::PushOptions class takes options like this: -o ci.skip -o merge_request.create -o merge_request.target=branch and turns them into a Hash like this: { ci: { skip: true }, merge_request: { create: true, target: 'branch' } } This now how Pipeline::Chain::Skip is determining if the `ci.skip` push option was used.
* Merge branch 'bvl-allow-more-repos-per-resource-ce' into 'master'James Lopez2019-03-271-2/+2
|\ | | | | | | | | Allow multiple repositories per project See merge request gitlab-org/gitlab-ce!26539
| * Allow multiple repositories per projectBob Van Landuyt2019-03-261-2/+2
| | | | | | | | | | | | | | | | This changes the repository type from a binary `wiki?` to a type. So we can have more than 2 repository types. Now everywhere we called `.wiki?` and expected a boolean, we check that type.
* | Rename GitPushService -> Git::BranchPushServiceNick Thomas2019-03-251-1/+1
| |
* | Rename GitTagPushService -> Git::TagPushServiceNick Thomas2019-03-251-1/+1
|/
* Add support for Git push options, specifically ci.skipJonathon Reinhart2018-12-311-4/+16
| | | | | | | | | | | | | | | | | gitlab-org/gitlab-shell!166 added support for collecting push options from the environment, and passing them along to the /internal/post_receive API endpoint. This change handles the new push_options JSON element in the payload, and passes them on through to the GitPushService and GitTagPushService services. Futhermore, it adds support for the first push option, ci.skip. With this change, one can use 'git push -o ci.skip' to skip CI pipe execution. Note that the pipeline is still created, but in the "skipped" state, just like with the 'ci skip' commit message text. Implements #18667
* Removes idenfitication by commit from Gitlab::Identifier51335-fail-early-when-user-cannot-be-identifiedTiago Botelho2018-10-251-8/+5
| | | | | | | Before we would need to identify a user when pushing through the GitLab UI. Since this is no longer the case we can remove the identification by commit and instead, use the identify_using_user
* User not defined in PostReceive#process_project_changesTiago Botelho2018-10-251-5/+7
| | | | | | | When Gitlab::GitPostReceive#changes_refs is empty user would not get defined and nil would be passed to PostReceive#after_project_changes_hooks which would then throw an error.
* Enable frozen string literals for app/workers/*.rbgfyoung2018-06-271-0/+2
|
* Resolve "Make a Rubocop that forbids returning from a block"🙈 jacopo beschi 🙉2018-04-181-1/+1
|
* Update project activity when pushing to a wiki repositoryda-update-project-activityDouglas Barbosa Alexandre2018-03-071-1/+1
|
* Add ApplicationWorker and make every worker include itDouwe Maan2017-12-051-2/+1
|
* Use gl_repository exclusively as identifier on post-receivepostreceive-gl-repositoryAlejandro Rodríguez2017-06-271-18/+3
|