Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-11-18Merge branch 'feature/precalculate-authorized-projects' into 'master' Douwe Maan
Precalculate authorized projects in database ## What does this MR do? It caches user's authorized projects in database instead of using multiple unions, which should simplify and speed-up things since this operation (getting authorized projects) is used a lot. ## Are there points in the code the reviewer needs to double check? Did we miss a scenario where we need to refresh the list of projects? ## 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 - [x] Added for this feature/bug - [x] All builds are passing - [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [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 it does - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? #23150 See merge request !6839
2016-11-18Precalculate user's authorized projects in databaseAhmad Sherif
Closes #23150
2016-11-18Merge branch 'feature/cycle-analytics-events' into 'master' Douwe Maan
Cycle Analytics: Events per stage Adds list of events to each stage: - Issue: list of issues created in the last XX days, that have been labeled or added to a milestone. - Plan: list of commits that reference for the fist time an issue from the last stage. - Code: list of MR created in this stage - Test: List of unique builds triggered by the commits. - Review: List of MR merged - Staging: List of deployed builds - Production: list of issues with the time from idea to production Fixes #23449 - [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) - Tests - [x] Added for this feature/bug - [x] All builds are passing - [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [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 it does - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !6859
2016-11-18run pipeline worker in cycle analytics dev setupJames Lopez
2016-11-17Remove empty db fixtures fileSemyon Pupkov
2016-10-17Refactor code to use available and stopped statuses and refactor views to ↵Kamil Trzcinski
use separate renders
2016-10-06Allow to close environmentsKamil Trzcinski
2016-10-04Fix pipeline fixtures and calls to removed methodGrzegorz Bizon
2016-09-28Allow Member.add_user to handle access requestersRémy Coutable
Changes include: - Ensure Member.add_user is not called directly when not necessary - New GroupMember.add_users_to_group to have the same abstraction level as for Project - Refactor Member.add_user to take a source instead of an array of members - Fix Rubocop offenses - Always use Project#add_user instead of project.team.add_user - Factorize users addition as members in Member.add_users_to_source - Make access_level a keyword argument in GroupMember.add_users_to_group and ProjectMember.add_users_to_projects - Destroy any requester before adding them as a member - Improve the way we handle access requesters in Member.add_user Instead of removing the requester and creating a new member, we now simply accepts their access request. This way, they will receive a "access request granted" email. - Fix error that was previously silently ignored - Stop raising when access level is invalid in Member, let Rails validation do their work Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-09-23Limit test environment size to one project in CIGrzegorz Bizon
2016-09-20Implement review comments from @yorickpeterseTimothy Andrew
1. Change multiple updates to a single `update_all` 2. Use cascading deletes 3. Extract an average function for the database median. 4. Move database median to `lib/gitlab/database` 5. Use `delete_all` instead of `destroy_all` 6. Minor refactoring
2016-09-20Merge remote-tracking branch 'origin/master' into 21170-cycle-analyticsTimothy Andrew
2016-09-17Add a "populate metrics directly" option to the cycle analytics seed.Timothy Andrew
- The normal seed creates all the data for cycle analytics the "right" way. It creates issues, merge requests, commits, branches, deployments, etc. This is good, but too slow for perf testing. Generating a 1000 sets of records this way takes more than an hour. - When the `CYCLE_ANALYTICS_POPULATE_METRICS_DIRECTLY` environment variable is passed in, the seed only creates issues and merge requests. It then adds the `metrics` for each issue and merge request directly, to save time. - The seed now takes about 4 minutes to run for 1000 sets of records.
2016-09-15Improve performance of the cycle analytics page.Timothy Andrew
1. These changes bring down page load time for 100 issues from more than a minute to about 1.5 seconds. 2. This entire commit is composed of these types of performance enhancements: - Cache relevant data in `IssueMetrics` wherever possible. - Cache relevant data in `MergeRequestMetrics` wherever possible. - Preload metrics 3. Given these improvements, we now only need to make 4 SQL calls: - Load all issues - Load all merge requests - Load all metrics for the issues - Load all metrics for the merge requests 4. A list of all the data points that are now being pre-calculated: a. The first time an issue is mentioned in a commit - In `GitPushService`, find all issues mentioned by the given commit using `ReferenceExtractor`. Set the `first_mentioned_in_commit_at` flag for each of them. - There seems to be a (pre-existing) bug here - files (and therefore commits) created using the Web CI don't have cross-references created, and issues are not closed even when the commit title is "Fixes #xx". b. The first time a merge request is deployed to production When a `Deployment` is created, find all merge requests that were merged in before the deployment, and set the `first_deployed_to_production_at` flag for each of them. c. The start / end time for a merge request pipeline Hook into the `Pipeline` state machine. When the `status` moves to `running`, find the merge requests whose tip commit matches the pipeline, and record the `latest_build_started_at` time for each of them. When the `status` moves to `success`, record the `latest_build_finished_at` time. d. The merge requests that close an issue - This was a big cause of the performance problems we were having with Cycle Analytics. We need to use `ReferenceExtractor` to make this calculation, which is slow when we have to run it on a large number of merge requests. - When a merge request is created, updated, or refreshed, find the issues it closes, and create an instance of `MergeRequestsClosingIssues`, which acts as a join model between merge requests and issues. - If a `MergeRequestsClosingIssues` instance links a merge request and an issue, that issue closes that merge request. 5. The `Queries` module was changed into a class, so we can cache the results of `issues` and `merge_requests_closing_issues` across various cycle analytics stages. 6. The code added in this commit is untested. Tests will be added in the next commit.
2016-09-14wip: perfTimothy Andrew
2016-09-14Add a `seed_fu` fixture to generate data for cycle analytics.Timothy Andrew
- The fixture generates data for every stage in the cycle analytics dashboard. Once this fixture has run, you shouldn't be seeing any "<not enough data>" messages for cycle analytics. - This is probably not necessary for every fixture run, so it might be moved behind an env var in the future.
2016-09-07Group similar buildsKamil Trzcinski
2016-08-19Move and improvement comment in pipeline fixturesGrzegorz Bizon
2016-08-18Change name of the class that with pipeline seedsGrzegorz Bizon
2016-08-18Rename file that holds pipeline fixtures in dev envGrzegorz Bizon
2016-08-18Reduce the number of build fixtures created in devGrzegorz Bizon
2016-08-18Reorder failed stages and improve build statusesGrzegorz Bizon
2016-08-18Fix build artifacts in fixtures in development envGrzegorz Bizon
2016-08-18Fix build logs in development environment fixturesGrzegorz Bizon
2016-08-18Refactor pipeline fixtures for dev env a littleGrzegorz Bizon
2016-08-17Update fixtures to add a created status to pipelineKamil Trzcinski
2016-08-17Merge remote-tracking branch 'origin/master' into 18141-pipeline-graphKamil Trzcinski
2016-08-17Update fixtures to make development testing easierKamil Trzcinski
2016-08-15Fix pipeline and build seeds in development environmentGrzegorz Bizon
When we depend on state machine events in seeds, it is likely that we will break fixtures from time to time because when transition rules change, using events most likely invalidates some objects in seeds.
2016-08-03Improve CI fixturesZ.J. van de Weg
2016-07-29Add seeds for protected branches.Timothy Andrew
2016-07-28Remove project which can't be pulled while seedingZ.J. van de Weg
[ci skip]
2016-07-18Improve code designKamil Trzcinski
2016-07-18Update build fixtures to include manual actionsKamil Trzcinski
2016-06-15Random selection now also works for MySQLZ.J. van de Weg
2016-06-15Near half of the Issues get Award Emoji when seedingZ.J. van de Weg
2016-06-15Skip system notes from receiving award emojiZ.J. van de Weg
2016-06-15Seed Award Emoji while seeding the databaseZ.J. van de Weg
2016-06-07Merge remote-tracking branch 'origin/master' into rename-ci-commit-phase-2Kamil Trzcinski
2016-06-07Fix missed colorize methods.Connor Shea
2016-06-03Use pipelines in context of ProjectKamil Trzcinski
2016-05-04Limit the number of merge requests per project to avoid long seedsStan Hu
This step was taking a long time because seed_fu creates N / 2 merge requests for each repo, where N is the number of branches for that repo. At the time of this writing, there are 234 branches on the gitlab-ce repo, leading to 117 merge requests.
2016-04-12Fix specsKamil Trzcinski
2016-04-10Fix seed_fu failure with inserting milestones into test DBStan Hu
Milestones were not being saved due to "invalid state" validation errors
2016-03-05Allow the initial admin to set a passwordRobert Speicher
Closes #1980
2016-02-11Add second build for each commit in build seedsGrzegorz Bizon
2016-02-08Add an option to supply root email through an environmental variable.3kami3
2016-01-14Seed db on development with artifacts metadata fixtureGrzegorz Bizon
2016-01-14Seed db with CI build artifacts using a zip archiveGrzegorz Bizon
2016-01-14Remove artifacts metadata column from databaseGrzegorz Bizon