summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* fix repo hooks missing on importfix/import-project-hooksJames Lopez2016-07-282-1/+19
| | | | fix spec and added changelog
* Merge branch 'reduce-instrumentation-overhead' into 'master' Rémy Coutable2016-07-285-32/+25
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reduce instrumentation overhead ## What does this MR do? This MR reduces the overhead of instrumented methods. See the commit message of 905f8d763ab1184dc0b1e4bf6f18d7981753a860 for more information. ## Are there points in the code the reviewer needs to double check? Not that I can think of. ## Why was this MR needed? The overhead of method call instrumentation was too great. ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [x] ~~[Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)~~ - [x] ~~API support added~~ - Tests - [x] Added for this feature/bug - [ ] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !5550
| * Reduce instrumentation overheadYorick Peterse2016-07-285-32/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reduces the overhead of the method instrumentation code primarily by reducing the number of method calls. There are also some other small optimisations such as not casting timing values to Floats (there's no particular need for this), using Symbols for method call metric names, and reducing the number of Hash lookups for instrumented methods. The exact impact depends on the code being executed. For example, for a method that's only called once the difference won't be very noticeable. However, for methods that are called many times the difference can be more significant. For example, the loading time of a large commit (nrclark/dummy_project@81ebdea5df2fb42e59257cb3eaad671a5c53ca36) was reduced from around 19 seconds to around 15 seconds using these changes.
* | Add commit stats to commit api responsedixpac2016-07-281-0/+5
|/
* Merge branch 'akismet-ui-check' into 'master' Douwe Maan2016-07-272-18/+5
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Submit new issues created via the WebUI or API to Akismet for spam check on public projects. ## What does this MR do? Submit new issues created via the WebUI by non project members to Akismet for spam check. ## Why was this MR needed? Support for Akismet was added only to the API with !2266. This MR builds on that functionality to also check issues submitted via the WebUI for spam. ## What are the relevant issue numbers? Related to: - #5573 - #5932 - gitlab-com/infrastructure#14 - gitlab-com/support#61 - !2266 cc @stanhu @MrChrisW See merge request !5333
| * Refactor spam validation to a concern that can be easily reused and improve ↵akismet-ui-checkPatricio Cano2016-07-262-18/+5
| | | | | | | | legibility in `SpamCheckService`
| * Refactor `SpamCheckService` to make it cleaner and clearer.Patricio Cano2016-07-261-4/+6
| |
| * Submit all issues on public projects to Akismet if enabled.Patricio Cano2016-07-262-7/+5
| |
| * Submit new issues created via the WebUI by non project members to Akismet ↵Patricio Cano2016-07-262-12/+12
| | | | | | | | for spam check.
* | Merge branch 'simple-cov' into 'master' Robert Speicher2016-07-271-1/+1
|\ \ | | | | | | | | | | | | | | | | | | Generate coverage report from whole test suite Extends our CI plan to merge all coverage results and generate HTML report. See merge request !5018
| * | Remove unused coverallsKamil Trzcinski2016-07-211-1/+1
| | |
| * | Use `scripts/merge-simplecov`Kamil Trzcinski2016-07-211-63/+0
| | |
| * | Merge coverage reportKamil Trzcinski2016-07-211-0/+63
| | |
* | | Optimize maximum user access level lookup in loading of notesStan Hu2016-07-261-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | NotesHelper#note_editable? and ProjectTeam#human_max_access currently take about 16% of the load time of an issue page. This MR preloads the maximum access level of users for all notes in issues and merge requests with several queries instead of one per user and caches the result in RequestStore.
* | | Merge branch 'feature/profile-requests-conditionally' into 'master' Douwe Maan2016-07-263-0/+109
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Return request profiling info when a header is passed ## What does this MR do? It allows returning profiling info (instead of actual content) when a certain header is passed ## Why was this MR needed? To facilitate having a performance overview of certain requests. ## What are the relevant issue numbers? https://gitlab.com/gitlab-com/infrastructure/issues/211 ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [ ] ~~[Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)~~ - [ ] ~~API support added~~ - ~~Tests~~ - [ ] ~~Added for this feature/bug~~ - [ ] ~~All builds are passing~~ - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !5281
| * | | Profile requests when a header is passedfeature/profile-requests-conditionallyAhmad Sherif2016-07-263-0/+109
| | |/ | |/|
* | | Fix a bug where forking a project from a repository storage to another would ↵20302-forking-a-project-from-one-storage-to-another-failsAlejandro Rodríguez2016-07-261-4/+6
|/ / | | | | | | fail
* | Merge branch 'add-sidekiq-request-store' into 'master' Yorick Peterse2016-07-261-0/+13
|\ \ | | | | | | | | | | | | Add support for using RequestStore within Sidekiq tasks via SIDEKIQ_REQUEST_STORE env variable See merge request !5054
| * | Add support for using RequestStore within Sidekiq tasks via ↵Stan Hu2016-07-251-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | SIDEKIQ_REQUEST_STORE env variable This significantly reduces the DB churn in the PostReceive task when it performs reference extraction. See #18663
* | | Ensure relative paths for video are rewritten as we do for images20189-markdown-video-doesn-t-work-when-the-referenced-video-file-is-in-same-repoRémy Coutable2016-07-261-1/+1
| | | | | | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* | | Disable MySQL foreign key checks before dropping all tablesDrew Blessing2016-07-251-0/+7
|/ /
* | Fix backup restorefix-backup-restoreStan Hu2016-07-251-2/+2
| | | | | | | | | | | | Set permissions of backup dir to g+s Closes #20188
* | Use project ID in repository cache to prevent stale data from persisting ↵Stan Hu2016-07-251-3/+4
| | | | | | | | | | | | | | | | | | | | across projects We have a number of bugs caused by cache keys not being flushed properly during deletion of a project. Add the project ID to ensure this never happens. Closes #20027
* | If version file is unavailable unknown statusKatarzyna Kobierska2016-07-231-3/+2
| |
* | Add gitlab-workhorse version to admin dashboardKatarzyna Kobierska2016-07-231-0/+7
| | | | | | | | | | | | Test for showing GitLab Workhorse version on Admin Dashboard Refactoring
* | Merge branch 'artifacts-from-ref-and-build-name-api' into 'master' Rémy Coutable2016-07-221-1/+1
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Simpler two queries than one JOIN with subquery This is a follow up from !5347 Originally it was: ``` ruby pipeline = pipelines.latest_successful_for(ref) builds.where(pipeline: pipeline).latest.with_artifacts ``` However MySQL would complain that we can't use `IN` against a subquery which has `LIMIT`. Using `INNER JOIN` would be a workaround, however, doing that is too complicated in current version of Rails. So let's just use two queries in this case. Closes #14419 See merge request !5388
| * | Also fix the URL in the commentartifacts-from-ref-and-build-name-apiLin Jen-Shin2016-07-211-1/+1
| | |
* | | Retrieve rendered HTML from cache in one requestfix/get-cached-rendered-html-using-single-redis-requestAhmad Sherif2016-07-211-4/+5
| | | | | | | | | | | | See #19985
* | | Merge branch 'discussion-model' into 'master' Robert Speicher2016-07-211-53/+10
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Add Discussion model to represent MR/diff discussion Related to https://gitlab.com/gitlab-org/gitlab-ce/issues/10325. See merge request !5376
| * | | Add Discussion model to represent MR/diff discussiondiscussion-modelDouwe Maan2016-07-201-53/+10
| | | |
* | | | Merge branch 'artifacts-from-ref-and-build-name-api' into 'master' Rémy Coutable2016-07-211-20/+38
|\ \ \ \ | | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | API for downloading latest successful build ## What does this MR do? Implement parts of #4255, particularly the API. ## Are there points in the code the reviewer needs to double check? I still made it that `ref` could be either branch, tag, or even SHA with: ``` ruby # ref can't be HEAD, can only be branch/tag name or SHA scope :latest_successful_for, ->(ref) do table = quoted_table_name # TODO: Use `where(ref: ref).or(sha: ref)` in Rails 5 where("#{table}.ref = ? OR #{table}.sha = ?", ref, ref). success.order(id: :desc) end ``` Because the reasons I put in: * https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5142#note_13165543 * https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5142#note_13165921 But if you still think that it's not good to do it this way, I'll drop it and let's think about the other way to satisfy the requirement specified in https://gitlab.com/gitlab-org/gitlab-ce/issues/4255#note_13101233 It could be `status=any` or `sha=DEADBEAF` ## What are the relevant issue numbers? Part of #4255 ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [x] API support added - Tests - [x] Added for this feature/bug - [ ] All builds are passing - [ ] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [ ] Branch has no merge conflicts with `master` (if you do - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !5347
| * | | Merge branch 'master' into artifacts-from-ref-and-build-name-apiLin Jen-Shin2016-07-2121-58/+266
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (261 commits) Add link to user profile to commit avatar (!5163) Refactor service settings view Fix a problem with processing a pipeline where stage only has manual actions A CHANGELOG entry Don't show other actions of the same name Use limit parameter rather than hardcoded value Remove icons from explore nav Change how we style redirect_to Use flash[:notice] only Create PipelinesSettingsController for showing settings page Fix a few nitpicks Allow to disable user request access to groups/projects Enable Style/MultilineTernaryOperator rubocop cop Fix review comments Update routes Update CHANGELOG Improve implementation of variables Log cron_jobs configuration instead of raising exception Added checks for migration downtime Ensure to_json methods take optional argument ...
| * | | | Should check against `authorize_read_builds!`Lin Jen-Shin2016-07-201-0/+2
| | | | |
| * | | | Artifacts are plural, feedback:Lin Jen-Shin2016-07-201-3/+3
| | | | | | | | | | | | | | | | | | | | https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5347/diffs#note_13173284
| * | | | Merge branch 'master' into artifacts-from-ref-and-build-name-apiLin Jen-Shin2016-07-195-45/+33
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (23 commits) Add CHANGELOG entry [ci skip] CHANGELOG item Added redirect_to_referer to login link on issues Simplify entities for branches and tags API Added Rake task for tracking deployments Return the number of marked todos Use local_assigns Use `humanize` Improve code design Remove unused create_pipeline_service_spec.rb Add notice implementation Make manual actions to work with master code Use `capitalize` instead of `titleize` for manual actions Mark builds with manual actions as skipped Fix rubocop offenses Update build fixtures to include manual actions Improve manual actions code and add model, service and feature tests Rename playable_actions to manual_actions Add implementation of manual actions Position commit icons closer to branch name/tag/sha; add min-width to pipeline actions cell ...
| * | | | | API for downloading latest successful build:Lin Jen-Shin2016-07-191-21/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was extracted from !5142 and implementing part of #4255. We split it from !5142 because we want to ship it in 8.10 while !5142 was not ready yet.
* | | | | | Merge branch '4142-show-inline-video' into 'master' Rémy Coutable2016-07-212-0/+60
|\ \ \ \ \ \ | |_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for inline videos in issue, MR and notes (on issue, commit, MR, and MR diff) ## What does this MR do? It adds support for inline videos in issue, MR and notes (on issue, commit, MR, and MR diff). Most of the work was done by @hayesr in !3508 but a few improvements were still missing. ## Why was this MR needed? To be able to play uploaded videos in GitLab! ## What are the relevant issue numbers? Closes #4142. ## Screenshots ### Video players ![Screen_Shot_2016-07-19_at_18.44.09](/uploads/e85e531b455a41c3e66b26b356abaafd/Screen_Shot_2016-07-19_at_18.44.09.png) ----- ![Screen_Shot_2016-07-19_at_18.44.29](/uploads/05f52a812760210d1eae86a7f8fc48bc/Screen_Shot_2016-07-19_at_18.44.29.png) ----- ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - Tests - [x] Test `VideoLinkFilter` - [x] Test in `spec/features/markdown_spec.rb` - [x] Improve `spec/uploaders/file_uploader_spec.rb` - [x] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !5215
| * | | | | Remove VideoJS and clean the integrationRémy Coutable2016-07-201-9/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Handle videos in: - MD preview in notes: commit, issue/MR, MR diff - New notes in: commit, issue/MR, MR diff - Persisted notes in: commit, issue/MR, MR diff Signed-off-by: Rémy Coutable <remy@rymai.me>
| * | | | | Use a more powerful query to match videos in img tagsRémy Coutable2016-07-192-10/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also, always add a link to download videos since video playback is tricky. Also, it solves the issue with email client not supporting videos. Signed-off-by: Rémy Coutable <remy@rymai.me>
| * | | | | Remove duplication, useless rescue, and avoid using ActionViewRémy Coutable2016-07-191-14/+9
| | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
| * | | | | First support of videos in issues, MRs and notesEric Hayes2016-07-192-0/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Registered video MIME types * Currently supporting browser-supported formats with extensions that match the mime type
* | | | | | Merge branch 'email-domain-blacklist' into 'master' Robert Speicher2016-07-202-2/+4
|\ \ \ \ \ \ | |_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added the ability to block sign ups using a domain blacklist. As part of this MR, I restructured the Application Settings form to separate **Sign up** related settings from **Sign in** related settings and make everything cleaner and easier to read. Fixes #19749 Related to #5573 See merge request !5259
| * | | | | Refactor and rename `restricted_signup_domains` to `domain_whitelist` to ↵Patricio Cano2016-07-182-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | better conform to its behavior and newly introduced behavior.
| * | | | | Added the ability to block sign ups using a domain blacklist.Patricio Cano2016-07-181-0/+2
| | | | | |
* | | | | | Change `return`s for `next`s to please rubocop (behaviour is the same)Alejandro Rodríguez2016-07-201-2/+2
| | | | | |
* | | | | | Add /deploy_keys API to retrieve all deploy keys regardless of project ↵Alejandro Rodríguez2016-07-201-53/+66
| |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | affiliation Also, in favour of consistency, deprecate `/projects/:id/keys/...` routes in favour of `/projects/:id/deploy_keys/...`
* | | | | Merge branch 'migration-downtime-tags' into 'master' Robert Speicher2016-07-204-0/+140
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added checks for migration downtime This adds a set of checks that check/list which migrations require downtime (or not). It also comes with a CI task that fails should a migration not be tagged properly. Fixes #14545 See merge request !4911
| * | | | | Added checks for migration downtimemigration-downtime-tagsYorick Peterse2016-07-204-0/+140
| | |_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These new checks can be used to check if migrations require downtime or not (as tagged by their authors). In CI this compares the current branch with master so migrations added by merge requests are automatically verified. To check the migrations added since a Git reference simply run: bundle exec rake gitlab:db:downtime_check[GIT_REF]
* | | | | Merge branch 'rubocop/enable-multiline-ternary-operator-cop' into 'master' Robert Speicher2016-07-201-2/+1
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Enable Style/MultilineTernaryOperator rubocop cop Avoid multi-line ?: (the ternary operator). Use if/unless instead. See #17478 See merge request !4356
| * | | | | Enable Style/MultilineTernaryOperator rubocop coprubocop/enable-multiline-ternary-operator-copGrzegorz Bizon2016-07-201-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid multi-line ?: (the ternary operator). Use if/unless instead. See #17478