summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Replace peek-pg with our own implementationremove-peek-pgSean McGivern2019-07-266-71/+36
| | | | | | | | | | This uses an ActiveRecord subscriber to get queries and calculate the total query time from that. This means that the total will always be consistent with the queries in the table. It does however mean that we could potentially miss some queries that don't go through ActiveRecord. Making this change also allows us to unify the response JSON a little bit, making the frontend slightly simpler as a result.
* Merge branch 'dm-submodule-links-nil' into 'master'Nick Thomas2019-07-261-3/+8
|\ | | | | | | | | Fix error rendering submodules in MR diffs when there is no .gitmodules See merge request gitlab-org/gitlab-ce!31162
| * Fix error rendering submodules in MR diffs when there is no .gitmodulesdm-submodule-links-nilDouwe Maan2019-07-261-3/+8
| | | | | | | | Without this change, we get a NoMethodError on nil
* | Prefer `flat_map` over `map` + `flatten`Peter Leitzen2019-07-265-8/+6
| | | | | | | | | | Convert several occurrences of `map` + `flatten` to `flat_map` where applicable.
* | Merge branch 'extract_auto_deploy_into_base_image' into 'master'Dmitriy Zaporozhets2019-07-262-376/+48
|\ \ | | | | | | | | | | | | | | | | | | Extract Auto DevOps deploy functions in a base image Closes #50286 See merge request gitlab-org/gitlab-ce!30404
| * | Extract deploy functions in a base imageextract_auto_deploy_into_base_imageThong Kuah2019-07-252-376/+48
| | | | | | | | | | | | https://gitlab.com/gitlab-org/cluster-integration/auto-deploy-image
* | | Ensure Warden triggers after_authentication callbackImre Farkas2019-07-261-2/+5
| | | | | | | | | | | | | | | | | | By not triggering the callback: - ActiveSession lookup keys are not cleaned - Devise also misses its hook related to session cleanup
* | | Merge branch 'print-sidekiq-class-name-in-memory-killer' into 'master'Stan Hu2019-07-251-7/+16
|\ \ \ | |_|/ |/| | | | | | | | Logging sidekiq worker class name in SidekiqMemoryKiller See merge request gitlab-org/gitlab-ce!30996
| * | Logging sidekiq worker class name in SidekiqMemoryKillerprint-sidekiq-class-name-in-memory-killerShinya Maeda2019-07-251-7/+16
| | | | | | | | | | | | | | | Currently, SidekiqMemoryKiller does not feed worker class name in the json structured logging. This commit extends the json parameter.
* | | Merge branch 'frozen_string_spec_support' into 'master'Douwe Maan2019-07-252-3/+2
|\ \ \ | | | | | | | | | | | | | | | | Add frozen_string_literal to spec/support See merge request gitlab-org/gitlab-ce!31132
| * | | Frozen string cannot change encodingfrozen_string_spec_supportThong Kuah2019-07-262-3/+2
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | This was shown in specs but surely this will be happening in application code as well if this method is passes a frozen string. We were also trying to force_encode a OmniAuth::AuthHash which had the very confusing behaviour of returning nil when it was sent a method that it did not define. Fix that by only force_encoding a String.
* | | Merge branch 'label-descr-push-opts' into 'master'Lin Jen-Shin2019-07-251-1/+3
|\ \ \ | | | | | | | | | | | | | | | | Support title and desc on merge w/ push option See merge request gitlab-org/gitlab-ce!31068
| * | | Support title and desc on merge w/ push optionlabel-descr-push-optsChristian Couder2019-07-241-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MergeRequests::PushOptionsHandlerService has been updated to allow creating and updating merge requests with the `title` and `description` set using git push options. To create a new merge request and set its title and description: git push -u origin -o merge_request.create \ -o merge_request.title="My title" \ -o merge_request.description="My description" To update an existing merge request and set its title and description: git push -u origin -o merge_request.title="My title" \ -o merge_request.description="My description" Issue https://gitlab.com/gitlab-org/gitlab-ce/issues/64320
* | | | Merge branch '54478-table_exists-not-compatible-with-rails-5-1' into 'master'Douglas Barbosa Alexandre2019-07-252-2/+2
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Resolve "table_exists? not compatible with Rails 5.1" Closes #54478 See merge request gitlab-org/gitlab-ce!30832
| * | | | Remove unneeded monkey-patch54478-table_exists-not-compatible-with-rails-5-1Heinrich Lee Yu2019-07-252-2/+2
| | |_|/ | |/| | | | | | | | | | | | | | Changes all calls to data_source_exists? to table_exists? since that is the intent of these calls
* | | | Merge branch 'sh-support-docker-oci-images' into 'master'Dmitriy Zaporozhets2019-07-251-3/+6
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Support Docker OCI images Closes gitlab-ee#12877 and #58685 See merge request gitlab-org/gitlab-ce!31127
| * | | | Support Docker OCI imagessh-support-docker-oci-imagesStan Hu2019-07-251-3/+6
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Docker Distribution v2.7.0 shipped with OCI support, but our container registry client was not updated to handle the manifest format in the HTTP `Accept` header. As a result, API calls to retrieve a manifest would return with an error, "OCI manifest found, but accept header does not support OCI manifests". This would result in blank fields in the container registry page and prevent tags from being deleted. To fix this, we just need to add `application/vnd.oci.image.manifest.v1+json` to the `Accept` header and configure Faraday to parse the response as JSON. The response structure is the same as the standard Docker Distribution V2 manifest. Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/58685 Closes https://gitlab.com/gitlab-org/gitlab-ee/issues/12877
* | | | Merge branch '9643-jira-api-serializer-ce' into 'master'Sean McGivern2019-07-251-0/+6
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | [CE] Create serializer for Jira API JSON payload See merge request gitlab-org/gitlab-ce!31139
| * | | | Backport Jira issue key regexHeinrich Lee Yu2019-07-251-0/+6
| |/ / /
* | | | Merge branch 'tc-revert-rails5-workaround' into 'master'Andreas Brandl2019-07-251-5/+1
|\ \ \ \ | |/ / / |/| | | | | | | | | | | Revert "Workaround for Rails 5, where LIMIT..." See merge request gitlab-org/gitlab-ce!30780
| * | | Revert "Workaround for Rails 5, where LIMIT..."tc-revert-rails5-workaroundToon Claes2019-07-161-5/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 6823e7defb45dfd86d5258b40d6f82482d1ef451. Originally implemented in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/21839, but an error was reported in https://gitlab.com/gitlab-org/gitlab-ce/issues/51729 resulting in a workaround introduced in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/21879. Now Rails 5.2 is used, this workaround no longer seems needed, so this reverts it.
* | | | Enable Rubocop Performance/ReverseEachsh-rubocop-reverse-eachStan Hu2019-07-241-1/+1
| |_|/ |/| | | | | | | | | | | | | | | | | `Array.reverse_each` is faster than `Array.reverse.each` because: * reverse.each creates a new array then loops each element * reverse_each loops in reverse order (no intermediate array created)
* | | Add RateLimiter to RawControllerMayra Cabrera2019-07-241-4/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Limits raw requests to 300 per minute and per raw path. * Add a new attribute to ApplicationSettings so user can change this value on their instance. * Uses Gitlab::ActionRateLimiter to limit the raw requests. * Add a new method into ActionRateLimiter to log the event into auth.log Related to https://gitlab.com/gitlab-org/gitlab-ce/issues/48717
* | | Merge branch 'cleanup/spec-tasks' into 'master'Douwe Maan2019-07-242-60/+4
|\ \ \ | | | | | | | | | | | | | | | | Resolves confusion within spec rake tasks. See merge request gitlab-org/gitlab-ce!31073
| * | | Resolves confusion within spec rake taskscleanup/spec-tasksJeremy Jackson2019-07-232-60/+4
| | | |
* | | | Merge branch 'optimise-import-performance' into 'master'Stan Hu2019-07-244-4/+4
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Optimise import performance Closes #64924 See merge request gitlab-org/gitlab-ce!31045
| * | | | Optimise import performanceoptimise-import-performanceKamil Trzciński2019-07-244-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Fix `O(n)` complexity of `append_or_update_attribute`, we append objects to an array and re-save project - Remove the usage of `keys.include?` as it performs `O(n)` search, instead use `.has_key?` - Remove the usage of `.keys.first` as it performs a copy of all keys, instead use `.first.first`
* | | | | [ADD] outbound requests whitelistReuben Pereira2019-07-242-6/+37
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Istvan szalai <istvan.szalai@savoirfairelinux.com>
* | | | | Merge branch 'sh-peek-cleanup' into 'master'Douglas Barbosa Alexandre2019-07-244-69/+65
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Use a base class for Peek views See merge request gitlab-org/gitlab-ce!31108
| * | | | | Use a base class for Peek viewssh-peek-cleanupStan Hu2019-07-244-69/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce a `DetailedView` base class, which is inherited by the Gitaly, Redis, and Rugged views. This reduces code duplication.
* | | | | | Enable tablesample count strategy by defaultAndreas Brandl2019-07-244-19/+5
|/ / / / / | | | | | | | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/issues/58792
* | | | | Merge branch 'sh-add-rugged-to-peek' into 'master'Sean McGivern2019-07-248-9/+94
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Add Rugged calls to performance bar See merge request gitlab-org/gitlab-ce!30983
| * | | | | Hide Rugged data if it doesn't existStan Hu2019-07-231-0/+2
| | | | | |
| * | | | | Add Rugged calls to performance barStan Hu2019-07-238-9/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will help diagnose the source of excessive I/O from Rugged calls. To implement this, we need to obtain the full list of arguments sent to each request method.
* | | | | | LFS export records repository_type dataLuke Duncalfe2019-07-243-8/+102
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A project can have the same `LfsObject` linked with up to three `LfsObjectsProject` records. Each of these records would be for a different repository, recorded in the `repository_type` property. The different repositories at time of writing are "project", "wiki", and "design". See https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/13894 This change exports the list of `repository_type`s as a JSON mapping of oid => repository_types, which are imported to recreate the correct `LfsObjectsProject` records. https://gitlab.com/gitlab-org/gitlab-ee/issues/11090
* | | | | | Fix incorrect web server parameter in init.d scriptMohammad Alhashash2019-07-241-4/+11
|/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | Environment variable USE_WEB_SERVER should have the value of the selected webserver when calling bin/web startup script. Fixes #65008
* | | | | Merge branch '65019-job-templates-dind-tls-fix' into 'master'Thong Kuah2019-07-245-0/+7
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Set DOCKER_TLS_CERTDIR in CI job templates See merge request gitlab-org/gitlab-ce!31080
| * | | | | Set DOCKER_TLS_CERTDIR in CI job templates65019-job-templates-dind-tls-fixTiger2019-07-245-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/issues/65019
* | | | | | Set DOCKER_TLS_CERTDIR in Auto Dev-Ops CI template65019-auto-devops-dind-tls-fixTiger2019-07-241-0/+2
|/ / / / / | | | | | | | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/issues/65019
* | | | | Merge branch '52442-initial-mysql-support-removal' into 'master'Robert Speicher2019-07-2318-382/+73
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove dead mysql code Closes #63191 See merge request gitlab-org/gitlab-ce!29608
| * | | | | Remove dead MySQL codeNick Thomas2019-07-2318-382/+73
| | |/ / / | |/| | | | | | | | | | | | | None of this code can be reached any more, so it can all be removed
* | | | | Rename changelog to correct issue number, be more explicit that we're ↵James Keogh2019-07-231-4/+5
| | | | | | | | | | | | | | | | | | | | talking about Auto DevOps projects
* | | | | Merge branch 'adjust-group-level-analytics-to-accept-multiple-project-ids' ↵Stan Hu2019-07-237-39/+62
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into 'master' Adjust group level analytics to accept multiple projects ids See merge request gitlab-org/gitlab-ce!30744
| * | | | | Change sql queryMałgorzata Ksionek2019-07-231-3/+3
| | | | | |
| * | | | | Add code review remarksadjust-group-level-analytics-to-accept-multiple-project-idsMałgorzata Ksionek2019-07-237-21/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add cr remarks Improve specs according to the review Fix schema Add cr remarks Fix naming Add cr remarks
| * | | | | Add basic project extractionMałgorzata Ksionek2019-07-237-35/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To allow project filtering Prepare summary for accepting multiple groups Modify deploys group summary class Add filtering by project name in issues summary Fix rubocop offences Add changelog entry Change name to id in project filtering Fix rebase problem Add project extraction
* | | | | | Add PIP_DEPENDENCY_PATH to dependency scanning templatemo khan2019-07-231-0/+1
| |/ / / / |/| | | |
* | | | | Merge branch 'safe-archiving-for-traces' into 'master'Kamil Trzciński2019-07-232-2/+17
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Extra logging for new live trace architecture See merge request gitlab-org/gitlab-ce!30892
| * | | | | Validate the existence of archived traces before removing live tracesafe-archiving-for-tracesShinya Maeda2019-07-232-2/+17
| |/ / / / | | | | | | | | | | | | | | | | | | | | Often live traces are removed even though the archived trace doesn't exist. This commit checkes the existence strictly.
* | | | | Merge branch 'sh-use-shared-state-cluster-pubsub' into 'master'Kamil Trzciński2019-07-231-1/+1
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Use persistent Redis cluster for Workhorse pub/sub notifications See merge request gitlab-org/gitlab-ce!30990