summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'dm-waitable-worker' into 'master'Sean McGivern2018-02-261-1/+7
|\ | | | | | | | | Extract WaitableWorker out of AuthorizedProjectsWorker See merge request gitlab-org/gitlab-ce!17356
| * Extract WaitableWorker out of AuthorizedProjectsWorkerDouwe Maan2018-02-261-1/+7
| |
* | Merge branch 'mk/fix-error-code-for-repo-does-not-exist' into 'master'Douwe Maan2018-02-261-1/+1
|\ \ | | | | | | | | | | | | Respond with more appropriate HTTP status code when repo does not exist See merge request gitlab-org/gitlab-ce!17341
| * | Respond 404 when repo does not existmk/fix-error-code-for-repo-does-not-existMichael Kozono2018-02-241-1/+1
| | |
* | | Restart Unicorn and Sidekiq when GRPC throws 14:Endpoint read failedJacob Vosmaer (GitLab)2018-02-263-67/+156
|/ /
* | Backport custom metrics ce componentsPaweł Chojnacki2018-02-236-21/+31
| |
* | Merge branch 'master' into '29497-pages-custom-domain-dns-verification'Robert Speicher2018-02-235-19/+27
|\ \ | | | | | | | | | # Conflicts: # db/schema.rb
| * | Resolve "Milestone Quick Action not displayed with no project milestones but ↵🙈 jacopo beschi 🙉2018-02-233-17/+13
| | | | | | | | | | | | with group milestones"
| * | Merge branch 'users-autocomplete' into 'master'Douwe Maan2018-02-232-2/+14
| |\ \ | | |/ | |/| | | | | | | Improve performance of searching for and auto completing of users See merge request gitlab-org/gitlab-ce!17158
| | * Added changelog for user search improvementsusers-autocompleteYorick Peterse2018-02-221-4/+2
| | |
| | * Optimise searching for users using short queriesYorick Peterse2018-02-222-2/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This optimises searching for users when using queries consisting out of one or two characters such as "ab". We optimise such cases by searching for `LOWER(name)` and `LOWER(username)` instead of using `ILIKE`. Using `LOWER` produces a _much_ better performing query. For example, when searching for all users matching the term "a" we'd produce the following plan: Limit (cost=637.69..637.74 rows=20 width=805) (actual time=41.983..41.995 rows=20 loops=1) Buffers: shared hit=8330 -> Sort (cost=637.69..638.61 rows=368 width=805) (actual time=41.982..41.990 rows=20 loops=1) Sort Key: (CASE WHEN ((name)::text = 'a'::text) THEN 0 WHEN ((username)::text = 'a'::text) THEN 1 WHEN ((email)::text = 'a'::text) THEN 2 ELSE 3 END), name Sort Method: top-N heapsort Memory: 35kB Buffers: shared hit=8330 -> Bitmap Heap Scan on users (cost=75.47..627.89 rows=368 width=805) (actual time=9.452..41.305 rows=277 loops=1) Recheck Cond: (((name)::text ~~* 'a'::text) OR ((username)::text ~~* 'a'::text) OR ((email)::text = 'a'::text)) Rows Removed by Index Recheck: 7601 Heap Blocks: exact=7636 Buffers: shared hit=8327 -> BitmapOr (cost=75.47..75.47 rows=368 width=0) (actual time=8.290..8.290 rows=0 loops=1) Buffers: shared hit=691 -> Bitmap Index Scan on index_users_on_name_trigram (cost=0.00..38.85 rows=180 width=0) (actual time=4.369..4.369 rows=4071 loops=1) Index Cond: ((name)::text ~~* 'a'::text) Buffers: shared hit=360 -> Bitmap Index Scan on index_users_on_username_trigram (cost=0.00..34.41 rows=188 width=0) (actual time=3.896..3.896 rows=4140 loops=1) Index Cond: ((username)::text ~~* 'a'::text) Buffers: shared hit=328 -> Bitmap Index Scan on users_email_key (cost=0.00..1.94 rows=1 width=0) (actual time=0.022..0.022 rows=0 loops=1) Index Cond: ((email)::text = 'a'::text) Buffers: shared hit=3 Planning time: 3.912 ms Execution time: 42.171 ms With the changes in this commit we now produce the following plan instead: Limit (cost=13257.48..13257.53 rows=20 width=805) (actual time=1.567..1.579 rows=20 loops=1) Buffers: shared hit=287 -> Sort (cost=13257.48..13280.93 rows=9379 width=805) (actual time=1.567..1.572 rows=20 loops=1) Sort Key: (CASE WHEN ((name)::text = 'a'::text) THEN 0 WHEN ((username)::text = 'a'::text) THEN 1 WHEN ((email)::text = 'a'::text) THEN 2 ELSE 3 END), name Sort Method: top-N heapsort Memory: 35kB Buffers: shared hit=287 -> Bitmap Heap Scan on users (cost=135.66..13007.91 rows=9379 width=805) (actual time=0.194..1.107 rows=277 loops=1) Recheck Cond: ((lower((name)::text) = 'a'::text) OR (lower((username)::text) = 'a'::text) OR ((email)::text = 'a'::text)) Heap Blocks: exact=277 Buffers: shared hit=287 -> BitmapOr (cost=135.66..135.66 rows=9379 width=0) (actual time=0.152..0.152 rows=0 loops=1) Buffers: shared hit=10 -> Bitmap Index Scan on yorick_test_users (cost=0.00..124.75 rows=9377 width=0) (actual time=0.101..0.101 rows=277 loops=1) Index Cond: (lower((name)::text) = 'a'::text) Buffers: shared hit=4 -> Bitmap Index Scan on index_on_users_lower_username (cost=0.00..1.94 rows=1 width=0) (actual time=0.035..0.035 rows=1 loops=1) Index Cond: (lower((username)::text) = 'a'::text) Buffers: shared hit=3 -> Bitmap Index Scan on users_email_key (cost=0.00..1.94 rows=1 width=0) (actual time=0.014..0.014 rows=0 loops=1) Index Cond: ((email)::text = 'a'::text) Buffers: shared hit=3 Planning time: 0.303 ms Execution time: 1.687 ms Here we can see the new query is 25 times faster compared to the old query.
* | | Add DNS verification to Pages custom domainsNick Thomas2018-02-231-0/+8
|/ /
* | Allow token authentication on go-get requestDouwe Maan2018-02-232-1/+17
| |
* | Merge branch 'bvl-external-auth-port' into 'master'Douwe Maan2018-02-2313-9/+287
|\ \ | | | | | | | | | | | | Port `read_cross_project` ability from EE See merge request gitlab-org/gitlab-ce!17208
| * | Use `Redactor` to hide cross project informationbvl-external-auth-portBob Van Landuyt2018-02-223-42/+20
| | | | | | | | | | | | | | | Since the redactor can be run on multiple documents at once and query results are stored in the request store.
| * | Port `read_cross_project` ability from EEBob Van Landuyt2018-02-2214-8/+308
| |/
* | Modify cluster creation API method to enable legacy_apac as defaultMayra Cabrera2018-02-221-1/+5
|/ | | | | | | | | | GKE 1.8 has RBAC on by default, since GKE has bumped the default version to 1.8.7 RBAC is now on, and we don't support that out of the box. This was also avoiding cluster applications (tiller, prometheus, etc), to be installed. Closes #41619
* Merge branch '42332-actionview-template-error-366-524-out-of-range' into ↵Douwe Maan2018-02-221-1/+11
|\ | | | | | | | | | | | | | | | | 'master' Resolve "ActionView::Template::Error: 366..524 out of range" Closes #42332 See merge request gitlab-org/gitlab-ce!17262
| * Fix 500 error when diff context line has broken encoding42332-actionview-template-error-366-524-out-of-rangeSean McGivern2018-02-221-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Rugged sometimes chops a context line in between bytes, resulting in the context line having an invalid encoding: https://github.com/libgit2/rugged/issues/716 When that happens, we will try to detect the encoding for the diff, and sometimes we'll get it wrong. If that difference in encoding results in a difference in string lengths between the diff and the underlying blobs, we'd fail to highlight any inline diffs, and return a 500 status to the user. As we're using the underlying blobs, the encoding is 'correct' anyway, so if the string range is invalid, we can just discard the inline diff highlighting. We still report to Sentry to ensure that we can investigate further in future.
* | Merge branch 'fix-squash-with-renamed-files' into 'master'Grzegorz Bizon2018-02-221-1/+1
|\ \ | | | | | | | | | | | | | | | | | | Fix squash with renamed files Closes gitlab-ee#4975 See merge request gitlab-org/gitlab-ce!17216
| * | Fix squash with renamed filesfix-squash-with-renamed-filesSean McGivern2018-02-191-1/+1
| | | | | | | | | | | | | | | We need to ignore the names for renamed files when configuring with sparse checkout.
* | | Merge branch 'zj-branch-contains-git-message' into 'master'Douwe Maan2018-02-221-10/+16
|\ \ \ | | | | | | | | | | | | | | | | Allow branchnames to be named the same as the commit it points to See merge request gitlab-org/gitlab-ce!17231
| * | | Handle branch and tag names which are commit idsZeger-Jan van de Weg2018-02-211-10/+16
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | Adds a test where a branch name is also a valid commit id. Git, the binary should create an error message which is difficult to parse and leading to errors later, as seen in: gitlab-org/gitlab-ce#43222 To catch these cases in the future, gitlab-test@1942eed5cc108b19c7405106e81fa96125d0be22 was created. Which a branch name matching the commit
* | | Merge branch 'ce-gitaly-squash-in-progress' into 'master'Grzegorz Bizon2018-02-222-1/+24
|\ \ \ | | | | | | | | | | | | | | | | [CE] Incorporate Gitaly's RepositoryService.IsSquashInProgress RPC See merge request gitlab-org/gitlab-ce!17002
| * | | Incorporate Gitaly's RepositoryService.IsSquashInProgress RPCce-gitaly-squash-in-progressAlejandro Rodríguez2018-02-212-1/+24
| | | |
* | | | Fix repo existence check in GitAccessWikiJacob Vosmaer (GitLab)2018-02-222-1/+11
| | | |
* | | | Merge branch 'mk-improve-background-migration-specs' into 'master'Stan Hu2018-02-212-153/+208
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | Improve background migration specs See merge request gitlab-org/gitlab-ce!17162
| * | | | Use convenient Rails helpermk-improve-background-migration-specsMichael Kozono2018-02-211-1/+1
| | | | |
| * | | | Explicitly reference redefined modelsMichael Kozono2018-02-202-152/+149
| | | | | | | | | | | | | | | | | | | | And move UntrackedFile into PopulateUntrackedUploadsDependencies, and move its spec into its own file.
| * | | | Remove codebase dependencies from a BG migrationMichael Kozono2018-02-162-6/+64
| | | | | | | | | | | | | | | | | | | | Specifically, `PopulateUntrackedUploads` and its spec.
* | | | | Merge branch '36847-update-update-toml-rb-to-1.0.0' into 'master'Rémy Coutable2018-02-212-3/+3
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Resolve "[Gem Update] update toml-rb to 1.0.0" Closes #36847 See merge request gitlab-org/gitlab-ce!17259
| * | | | | 36847 - update toml-rb to 1.0.0Ken2018-02-212-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 36847 - add changelog
* | | | | | Merge branch 'add-pagination-commit-diffs' into 'master'Robert Speicher2018-02-211-1/+4
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add missing pagination on the commit diff endpoint Closes #43370 See merge request gitlab-org/gitlab-ce!17203
| * | | | | | Add missing pagination on the commit diff endpointMaxime Roussin-Belanger2018-02-191-1/+4
| | | | | | |
* | | | | | | Resolve "API: PUT /projects/:id fails when only ci_config_path is specified"Kárpáti László2018-02-211-0/+1
| | | | | | |
* | | | | | | Merge branch 'sh-guard-against-nil-sidekiq-metrics-server' into 'master'Robert Speicher2018-02-211-1/+1
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Guard against nil Sidekiq metrics server Closes #41351 See merge request gitlab-org/gitlab-ce!17254
| * | | | | | | Guard against nil Sidekiq metrics serversh-guard-against-nil-sidekiq-metrics-serverStan Hu2018-02-201-1/+1
| | |/ / / / / | |/| | | | | | | | | | | | | | | | | | | Closes #41351
* | | | | | | Merge branch ↵Rémy Coutable2018-02-211-4/+6
|\ \ \ \ \ \ \ | |_|_|_|_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | '40668-pages-domain-api-returns-404-when-using-a-specific-domain' into 'master' Resolve "Pages Domain API returns 404 when using a specific domain" Closes #40668 See merge request gitlab-org/gitlab-ce!17206
| * | | | | | Fix get a single pages domain when project path contains a periodTravis Miller2018-02-191-4/+6
| | |/ / / / | |/| | | |
* | | | | | Do not count rails sql cache as queries in query limitingquery-counting-should-not-include-cached-queriesDylan Griffith2018-02-211-2/+4
| |/ / / / |/| | | |
* | | | | Merge branch '43424-put_all_event_metrics_behind_feature_flags' into 'master'Douwe Maan2018-02-201-2/+3
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix for sidekiq metrics set cardinality growing unbounded Closes #43424 See merge request gitlab-org/gitlab-ce!17235
| * | | | | Only use features for eventsPawel Chojnacki2018-02-201-3/+3
| | | | | |
| * | | | | Put all event metrics exposed to prometheus behind a feature flagPawel Chojnacki2018-02-201-0/+1
| | |/ / / | |/| | |
* | | | | [GH Import] Create an empty wiki if wiki import failedValery Sizov2018-02-191-0/+1
| | | | |
* | | | | Merge branch 'jej/avoid-slow-file-lock-checks' into 'master'Sean McGivern2018-02-192-3/+8
|\ \ \ \ \ | |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | Avoid slow File Lock checks when not used Closes #43339 See merge request gitlab-org/gitlab-ce!17140
| * | | | Avoid slow File Lock checks when not usedJames Edwards-Jones2018-02-192-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | | Also avoid double commit lookup during file lock check by reusing memoized commits.
* | | | | Merge branch '32564-fix-double-system-closing-notes' into 'master'Sean McGivern2018-02-191-1/+1
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Resolve "Double closing system notes when closing issue with Merge Request" Closes #32546 and #32564 See merge request gitlab-org/gitlab-ce!17035
| * | | | | Convert Gitaly commit parent IDs to array as early as possibleSean McGivern2018-02-191-10/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The tracking issue if this causes problems is https://gitlab.com/gitlab-org/gitaly/issues/1028
| * | | | | applying feedback32564-fix-double-system-closing-notesMicaël Bergeron2018-02-161-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | # modified: lib/gitlab/git/commit.rb
| * | | | | fix specsMicaël Bergeron2018-02-161-0/+8
| | |_|/ / | |/| | |