summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Fixed ordering in Project.find_with_namespacefix-project-find-with-namespace-orderYorick Peterse2016-06-162-2/+34
| | | | | | | | | | | | | | | | | | | This ensures that Project.find_with_namespace returns a row matching literally as the first value, instead of returning a random value. The ordering here is _only_ applied to Project.find_with_namespace and _not_ Project.where_paths_in as currently there's no code that requires Project.where_paths_in to return rows in a certain order. Since this method also returns all rows that match there's no real harm in not setting a specific order either. Another reason is that generating all the "WHEN" arms for multiple values in Project.where_paths_in becomes really messy. On MySQL we have to use the "BINARY" operator to turn a "WHERE" into a case-sensitive WHERE as otherwise MySQL may still end up returning rows in an unpredictable order. Fixes gitlab-org/gitlab-ce#18603
* Merge branch 'add-index-on-requested_at-to-members' into 'master' Yorick Peterse2016-06-152-1/+11
|\ | | | | | | | | Add index on `requested_at` to the `members` table See merge request !4679
| * Add index on `requested_at` to the `members` tableadd-index-on-requested_at-to-membersRémy Coutable2016-06-152-1/+11
| | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* | Merge branch 'mr-buttons-update' into 'master' Jacob Schatz2016-06-156-43/+70
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixed issue with MR buttons being in a group ## What does this MR do? Fixes design issue with the buttons in the merge request widget ## Screenshots (if relevant) ![Screen_Shot_2016-06-09_at_14.13.32](/uploads/44ac4175f5a97a8d7baf97be6eebc684/Screen_Shot_2016-06-09_at_14.13.32.png) See merge request !4562
| * | Fixed issue with MR buttons being in a groupmr-buttons-updatePhil Hughes2016-06-136-43/+70
| | | | | | | | | | | | Also removed some inline code
* | | Merge branch '18225-avoid-full-table-users-count' into 'master' Jacob Vosmaer (GitLab)2016-06-151-1/+1
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check if the Users table has exactly one user limiting the whole set ## What does this MR do? Limit the query set so about a full scan for all the rows on the users table (only scan to records) #18225 See merge request !4492
| * | | Check if the Users table has exactly one user limiting the whole set18225-avoid-full-table-users-countPaco Guzman2016-06-061-1/+1
| | | |
* | | | Merge branch 'docker-registry-manifest-v1' into 'master' Rémy Coutable2016-06-157-33/+125
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for Docker Registry manifest v1 ## What does this MR do? Adds support for Manifest V1 generated by older versions of Docker (before 1.10). ## What are the relevant issue numbers? Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/18609 See merge request !4669
| * | | | Show created_at in table columndocker-registry-manifest-v1Kamil Trzcinski2016-06-151-5/+5
| | | | |
| * | | | Add support for Docker Registry manifest v1Kamil Trzcinski2016-06-157-32/+124
| | | | |
* | | | | Merge branch 'issuable-sidebar-dropdown-deselect-fix' into 'master' Jacob Schatz2016-06-153-2/+43
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixed issue with de-selecting dropdown option in issue sidebar ## What does this MR do? When de-selecting either an assignee or milestone, we try to send `undefined` which jQuery removes from the request causing a routing error. Instead this MR sends `null` which jQuery still sends and then correctly removes either the milestone or assignee. ## What are the relevant issue numbers? Closes #18641 ## Screenshots (if relevant) ![assignee](/uploads/6eaca416fb6e31eabf4c038967160c07/assignee.gif) ## Does this MR meet the acceptance criteria? - [ ] [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 - [ ] 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 !4671
| * | | | | Fixed issue with de-selecting dropdown option in issue sidebarissuable-sidebar-dropdown-deselect-fixPhil Hughes2016-06-153-2/+43
| | | | | | | | | | | | | | | | | | | | | | | | Closes #18641
* | | | | | Merge branch 'tooltip-change' into 'master' Jacob Schatz2016-06-154-1/+16
|\ \ \ \ \ \ | |_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update project star/unstar tooltip ## What does this MR do? Fixes project toggle star button tooltip to show actual tooltip for its state. ## Are there points in the code the reviewer needs to double check? No. ## Why was this MR needed? - When you star a project tooltip wasn't changing. - When you star a project and refresh the page, tooltip was still showing `Star Project` ## What are the relevant issue numbers? Fixes #18143 ## Screenshots (if relevant) ### Before ![Screen_Shot_2016-06-15_at_15.31.57](/uploads/e005951c23eeed7c2761a0ec1911f3ce/Screen_Shot_2016-06-15_at_15.31.57.png) ### After ![tooltip-change](/uploads/4caec99eac6ffcc7331947fdfdb9e051/tooltip-change.gif) ## 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 !4672
| * | | | | Update CHANGELOG.tooltip-changeFatih Acet2016-06-151-0/+1
| | | | | |
| * | | | | Fix project star tooltip on the fly.Fatih Acet2016-06-152-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | Introduced new util called updateTooltipTitle.
| * | | | | Fix project star tooltip in to show actual message.Fatih Acet2016-06-151-1/+1
| | | | | |
* | | | | | Merge branch 'eager-loading-issue-parser' into 'master' Douwe Maan2016-06-152-1/+16
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Eager load project relations in IssueParser ## What does this MR do? This changes the ReferenceParser class to eager load various associations. This in turn results in the permissions checking code (e.g. the `Ability` model) to _not_ run dozens if not hundreds of extra SQL queries depending on the amount of references involved (in a single document). ## Are there points in the code the reviewer needs to double check? No. ## Why was this MR needed? In !4410 it was revealed a _lot_ of a queries came from the `Ability` model and the code it would call. In many cases this was because the code would simply get a project, then get the owners; or get a group, then get some association of that. Eager loading these associations is a fairly simple solution and greatly cuts down the number of queries. ## What are the relevant issue numbers? None. ## 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) - [ ] 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 !4675
| * | | | | | Eager load project relations in IssueParserYorick Peterse2016-06-152-1/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By eager loading these associations we can greatly cut down the number of SQL queries executed when processing documents with lots of references, especially in cases where there are references belonging to the same project. Since these associations are so specific to the reference parsing process and the permissions checking process that follows it I opted to include them directly in IssueParser instead of using something like a scope. Once we have a need for it we can move this code to a scope or method.
* | | | | | | Merge branch 'stanhu/gitlab-ce-fix-error-500-false-binary-negative'Douwe Maan2016-06-1510-5/+27
|\ \ \ \ \ \ \
| * | | | | | | Fix Error 500 when viewing a blob with binary characters after the 1024-byte ↵Stan Hu2016-06-1210-5/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | mark Here was the problem: 1. When determining whether a given blob is viewable text, gitlab_git reads the first 1024 bytes and checks with Linguist whether it is a text or binary file. 2. If the blob is text, GitLab will attempt to display it. 3. However, if the text has binary characters after the first 1024 bytes, then GitLab will attempt to load the entire contents, but the encoding will be ASCII-8BIT since there are binary characters. 4. The Error 500 results when GitLab attempts to display a mix UTF-8 and ASCII-8BIT. To fix this, we load as much data as we are willing to display so that the detection will work properly. Requires an update to gitlab_git: gitlab-org/gitlab_git!86 Closes #13826
* | | | | | | | Merge branch 'list-items' into 'master' Jacob Schatz2016-06-154-6/+7
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove div between ul and li ## What does this MR do? Adds `container_class`to `ul` instead of `div` for valid HTML ## What are the relevant issue numbers? https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4592#note_12420843 See merge request !4633
| * | | | | | | | Remove div between ul and lilist-itemsAnnabel Dunstone2016-06-134-6/+7
| | | | | | | | |
* | | | | | | | | Merge branch 'zj-system-notes-not-awardable' into 'master' Douwe Maan2016-06-151-0/+4
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Award Emoji can't be awarded on system notes backend See merge request !4668
| * | | | | | | | | Award Emoji can't be awarded on system notes backendzj-system-notes-not-awardableZ.J. van de Weg2016-06-151-0/+4
| | | | | | | | | |
* | | | | | | | | | Merge branch 'environments-and-deployments' into 'master' Rémy Coutable2016-06-1546-40/+880
|\ \ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add environments and deployments This MR is a continuation of https://gitlab.com/gitlab-org/gitlab-ce/issues/17009. The current implementation is as follow: 1. We have two new tables: `environments` and `deployments`. 2. We have a new tab: `Environments` under `Pipelines` where you can see all you environments and add a new one. 3. We add a new option to `.gitlab-ci.yml` to track where we should create a deployment for environment. 4. If environment in `.gitlab-ci.yml` is specified it will create a deployment. **If environment does not exist it will be created.** (this got changed) 5. The deployment is always successful and shows the time of the action, in that case a build that presumably should do deployment. In the future we could extend deployment with statuses: success, failure. We could extend deployments with information that this is partial or full deployment. 6. User have to create environments that he will track first. 7. User can remove environments. 8. User can retry/rollback past deployment (in that case we retry past build). The new build when succeeds it will create a new deployment. 9. Currently environment have only one parameter: `name`. In the future it should have: `variables`, `credentials` and possibly `runners` and maybe other resources. 10. Currently deployment have this parameters: `sha`, `ref`, `deployable (in this case a build)`, `user (who triggered a deployment)`, `created_at`. The `.gitlab-ci.yml`: ``` deploy to production: stage: deploy script: dpl travis... environment: production ``` What needs to be done: - [x] Write initial implementation - [x] Improve implementation (@ayufan) - [x] Write tests (@ayufan) - [x] Improve UX of the forms (cc @markpundsack) - reviewed by @markpundsack - [x] Improve implementation of the views (cc @jschatz1) - done by @iamphill - [x] Write .gitlab-ci.yml documentation for `environments` - done by @ayufan - [ ] Write user documentation (@ayufan and @markpundsack) See merge request !4605
| * | | | | | | | | Use validate and required for environment and projectKamil Trzcinski2016-06-152-3/+3
| | | | | | | | | |
| * | | | | | | | | Make project_id, iid unique for deploymentsKamil Trzcinski2016-06-152-2/+469
| | | | | | | | | |
| * | | | | | | | | Validate project and environment instead of only requiringKamil Trzcinski2016-06-153-473/+6
| | | | | | | | | |
| * | | | | | | | | Make `project_id` and `environment_id` nullableenvironments-and-deploymentsKamil Trzcinski2016-06-153-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is done to make belongs_to with required to properly validate association. Otherwise `ActiveRecord::StatementInvalid` is raised.
| * | | | | | | | | Create_deployment ability is need to create retry or rollback deploymentKamil Trzcinski2016-06-152-3/+3
| | | | | | | | | |
| * | | | | | | | | Add CHANGELOGKamil Trzcinski2016-06-151-0/+1
| | | | | | | | | |
| * | | | | | | | | Make environments_spec more feature-specKamil Trzcinski2016-06-151-57/+56
| | | | | | | | | |
| * | | | | | | | | Improve cyclomatic of ability::allowedKamil Trzcinski2016-06-151-15/+1
| | | | | | | | | |
| * | | | | | | | | Improve forms and specsKamil Trzcinski2016-06-156-20/+22
| | | | | | | | | |
| * | | | | | | | | Improve validationsKamil Trzcinski2016-06-156-34/+31
| | | | | | | | | |
| * | | | | | | | | Improve design after reviewKamil Trzcinski2016-06-1414-69/+59
| | | | | | | | | |
| * | | | | | | | | Merge remote-tracking branch 'origin/master' into environments-and-deploymentsKamil Trzcinski2016-06-1439-543/+1040
| |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # Conflicts: # db/schema.rb
| * | | | | | | | | | Update scss to make the views look nicerKamil Trzcinski2016-06-145-9/+13
| | | | | | | | | | |
| * | | | | | | | | | Merge remote-tracking branch 'origin/master' into environments-and-deploymentsKamil Trzcinski2016-06-1424-108/+817
| |\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # Conflicts: # lib/ci/gitlab_ci_yaml_processor.rb
| * | | | | | | | | | | Test environment controller specsKamil Trzcinski2016-06-143-1/+168
| | | | | | | | | | | |
| * | | | | | | | | | | Properly create a new deployment after build successKamil Trzcinski2016-06-142-6/+68
| | | | | | | | | | | |
| * | | | | | | | | | | Authorize environments controller actionsKamil Trzcinski2016-06-144-2/+48
| | | | | | | | | | | |
| * | | | | | | | | | | Add gitlab-ci.yml documentation for environmentsKamil Trzcinski2016-06-141-0/+27
| | | | | | | | | | | |
| * | | | | | | | | | | Add specs for models and servicesKamil Trzcinski2016-06-1412-28/+139
| | | | | | | | | | | |
| * | | | | | | | | | | Validate environment name with regexKamil Trzcinski2016-06-144-10/+78
| | | | | | | | | | | |
| * | | | | | | | | | | Make retry action on pipeline to save a userKamil Trzcinski2016-06-142-3/+5
| | | | | | | | | | | |
| * | | | | | | | | | | Merge remote-tracking branch 'origin/master' into environments-and-deploymentsKamil Trzcinski2016-06-14109-647/+1420
| |\ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | Improved viewsPhil Hughes2016-06-134-46/+44
| | | | | | | | | | | | |
| * | | | | | | | | | | | Add deployment viewsKamil Trzcinski2016-06-119-33/+74
| | | | | | | | | | | | |
| * | | | | | | | | | | | Added initial version of deploymentsKamil Trzcinski2016-06-1022-111/+311
| | | | | | | | | | | | |