Age | Commit message (Collapse) | Author |
|
This moves the `where` in the `has_many :keys` association in Project to
the Key model. This allows EE to override this method, instead of
modifying the source code directly.
|
|
This moves the `1.hour` constant used as the LDAP sync time to a
separate method. This allows EE to override this method using a module,
instead of directly modifying the source code.
|
|
|
|
Fix typos in comments and specs
See merge request gitlab-org/gitlab-ce!22683
|
|
Reduce SQL queries needed to load open merge requests
See merge request gitlab-org/gitlab-ce!22709
|
|
|
|
|
|
|
|
Remove EE-specific code from 'Discussion' models
See merge request gitlab-org/gitlab-ce!22687
|
|
The SQL queries and memory allocation in MergeRequests::RefreshService
is dominated by queries for Project and Route loads. On staging, the
absence of an inverse relationship caused Rails to make over 1100
extraneous SQL queries for the www-gitlab-com repository.
Relates to https://gitlab.com/gitlab-org/gitlab-ce/issues/49703
|
|
Add language param to highlight
See merge request gitlab-org/gitlab-ce!21584
|
|
Enhance performance of counting local LFS objects
Closes gitlab-ee#6067
See merge request gitlab-org/gitlab-ce!22143
|
|
|
|
Extract language_from_git_attributes as a concern so it can
ben included in two blob classes.
|
|
This is to DRY the repeated file size check.
Move spec and constants to Highlight
|
|
Force FoundBlob to use BlobPresenter
|
|
Ported from Highlight class since it as a concept is more related to
blob, and this allows more flexibility.
|
|
Add an index to the `file_store` column on `lfs_objects`. This makes
counting local objects faster.
Also, there is no longer need to check for objects with `file_store`
being `NULL`. See
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/18557
---
### Query plans
#### Before & with `NULL`
```
Aggregate (cost=113495.96..113495.97 rows=1 width=8) (actual time=1691.394..1691.394 rows=1 loops=1)
-> Seq Scan on lfs_objects (cost=0.00..106415.50 rows=2832186 width=0) (actual time=0.012..1312.488 rows=2852607 loops=1)
Filter: ((file_store = 1) OR (file_store IS NULL))
Rows Removed by Filter: 131
Planning time: 0.077 ms
Execution time: 1691.433 ms
```
#### Before, without `NULL`
```
Aggregate (cost=113495.96..113495.97 rows=1 width=8) (actual time=856.423..856.424 rows=1 loops=1)
-> Seq Scan on lfs_objects (cost=0.00..106415.50 rows=2832186 width=0) (actual time=0.012..672.181 rows=2852607 loops=1)
Filter: (file_store = 1)
Rows Removed by Filter: 131
Planning time: 0.128 ms
Execution time: 856.470 ms
```
#### After & with `NULL`
```
Aggregate (cost=68819.95..68819.96 rows=1 width=8) (actual time=583.355..583.355 rows=1 loops=1)
-> Index Only Scan using index_lfs_objects_on_file_store on lfs_objects (cost=0.43..61688.35 rows=2852643 width=0) (actual time=0.028..399.177 rows=2852607 loops=1)
Filter: ((file_store = 1) OR (file_store IS NULL))
Rows Removed by Filter: 131
Heap Fetches: 867
Planning time: 0.096 ms
Execution time: 583.404 ms
```
#### After, without `NULL`
```
Aggregate (cost=68817.29..68817.30 rows=1 width=8) (actual time=490.550..490.551 rows=1 loops=1)
-> Index Only Scan using index_lfs_objects_on_file_store on lfs_objects (cost=0.43..61685.68 rows=2852643 width=0) (actual time=0.040..311.760 rows=2852607 loops=1)
Index Cond: (file_store = 1)
Heap Fetches: 831
Planning time: 0.294 ms
Execution time: 490.590 ms
```
Closes https://gitlab.com/gitlab-org/gitlab-ee/issues/6067
|
|
|
|
Replace deprecated uniq on a Relation with distinct
See merge request gitlab-org/gitlab-ce!22625
|
|
[11.4] Fix Token lookup for Git over HTTP and registry authentication
See merge request gitlab/gitlabhq!2577
|
|
[master] Redact unsubscribe links in issuable texts
See merge request gitlab/gitlabhq!2528
|
|
|
|
|
|
Models and migrations for group level clusters
See merge request gitlab-org/gitlab-ce!22307
|
|
Fixing count on Milestones
Closes #50848
See merge request gitlab-org/gitlab-ce!21446
|
|
Even though we currently only should have one group for a cluster, we
allow the flexibility to associate to other groups in the future.
This also matches the runner <=> groups association.
- Adds Cluster#first_group, aliased to Cluster#group. For the
conceivable future, a cluster will have at most one group.
- Prevent mixing of group and project clusters. If project type
clusters, it should only have projects assigned. Similarly with groups.
- Default cluster_type to :project_type. As it's very small table we can
set default and null: false in one release.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Backport SSH host key detection code to CE
See merge request gitlab-org/gitlab-ce!22577
|
|
This functionality is needed for SSH push mirroring support, which is a
CE feature.
|
|
Refactor Gitlab::KubeClient
Closes #52131
See merge request gitlab-org/gitlab-ce!22073
|
|
It's possible that user pastes accidentally also unsubscribe link
which is included in footer of notification emails. This unsubscribe
link contains personal token which attacker then use to act as the
original user (e.g. for sending comments under his/her identity).
|
|
|
|
Support licenses and performance
See merge request gitlab-org/gitlab-ce!22175
|
|
Alias the lfs_enabled method
Closes #49348
See merge request gitlab-org/gitlab-ce!22501
|
|
This removes the ability to pass in a different version. We can instead
create a new entry in the SUPPORTED_API_GROUPS hash for a different
version if need be.
|
|
Find and replace everywhere we pass in `api_groups` to KubeClient, as no
longer needed
|
|
requests"
|
|
Resolve "Removed branch link in pipelines page is broken"
Closes #42611
See merge request gitlab-org/gitlab-ce!21451
|
|
Add Clusters::KubernetesNamespace model
See merge request gitlab-org/gitlab-ce!22404
|
|
Move Project#rename_repo to a service class
See merge request gitlab-org/gitlab-ce!22419
|
|
We currently check for `project.lfs_enabled` to display
the state of lfs being enabled/disabled, but this is set to nil by
default, even when lfs is enabled.
Aliasing the method to #lfs_enabled? will return the correct state.
|
|
This model will be used to persist into database Kubernetes properties,
such as namespace, service account name and service account token.
|
|
EE added a `rescue` to the method Project#import_url, which could cause
merge conflicts when changing this method. This commit backports those
changes to CE, reducing the chances of running into a merge conflict.
|
|
This moves the logic of Project#rename_repo and all methods _only_ used
by this method into a new service class: Projects::AfterRenameService.
By moving this code into a separate service class we can more easily
refactor it, and we also get rid of some RuboCop "disable" statements
automatically.
During the refactoring of this code, I removed most of the explicit
logging using Gitlab::AppLogger. The data that was logged would not be
useful when debugging renaming issues, as it does not add any value on
top of data provided by users.
I also removed a variety of comments that either mentioned something the
code does in literal form, or contained various grammatical errors.
Instead we now resort to more clearly named methods, removing the need
for code comments.
This method was chosen based on analysis in
https://gitlab.com/gitlab-org/release/framework/issues/28. In this issue
we determined this method has seen a total of 293 lines being changed in
it. We also noticed that RuboCop determined the ABC size
(https://www.softwarerenovation.com/ABCMetric.pdf) was too great.
|