Skip to content

Commit c2d0d27

Browse files
author
GitLab Bot
committed
Add latest changes from gitlab-org/gitlab@master
1 parent b4c3970 commit c2d0d27

File tree

23 files changed

+201
-171
lines changed

23 files changed

+201
-171
lines changed

.rubocop_todo/rspec/feature_category.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3188,7 +3188,6 @@ RSpec/FeatureCategory:
31883188
- 'spec/lib/gitlab/ci/variables/collection/item_spec.rb'
31893189
- 'spec/lib/gitlab/ci/variables/collection/sort_spec.rb'
31903190
- 'spec/lib/gitlab/ci/variables/helpers_spec.rb'
3191-
- 'spec/lib/gitlab/ci/yaml_processor/dag_spec.rb'
31923191
- 'spec/lib/gitlab/ci/yaml_processor/feature_flags_spec.rb'
31933192
- 'spec/lib/gitlab/ci_access_spec.rb'
31943193
- 'spec/lib/gitlab/class_attributes_spec.rb'

app/helpers/graph_helper.rb

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,6 @@ module GraphHelper
44
def refs(repo, commit)
55
refs = [commit.ref_names(repo).join(' ')]
66

7-
# append note count
8-
unless Feature.enabled?(:disable_network_graph_notes_count, @project, type: :experiment)
9-
notes_count = @graph.notes[commit.id]
10-
refs << "[#{pluralize(notes_count, 'note')}]" if notes_count > 0
11-
end
12-
137
refs.join
148
end
159

app/models/network/graph.rb

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
module Network
44
class Graph
5-
attr_reader :days, :commits, :map, :notes, :repo
5+
attr_reader :days, :commits, :map, :repo
66

77
def self.max_count
88
@max_count ||= 650
@@ -17,28 +17,10 @@ def initialize(project, ref, commit, filter_ref)
1717

1818
@commits = collect_commits
1919
@days = index_commits
20-
@notes = collect_notes
2120
end
2221

2322
protected
2423

25-
def collect_notes
26-
return {} if Feature.enabled?(:disable_network_graph_notes_count, @project, type: :experiment)
27-
28-
h = Hash.new(0)
29-
30-
@project
31-
.notes
32-
.where(noteable_type: 'Commit')
33-
.group('notes.commit_id')
34-
.select('notes.commit_id, count(notes.id) as note_count')
35-
.each do |item|
36-
h[item.commit_id] = item.note_count.to_i
37-
end
38-
39-
h
40-
end
41-
4224
# Get commits from repository
4325
#
4426
def collect_commits

app/views/shared/wikis/show.html.haml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212

1313
.nav-controls.pb-md-3.pb-lg-0
1414
= render 'shared/wikis/main_links'
15-
- if Feature.enabled?(:print_wiki, current_user)
16-
#js-export-actions{ data: { options: { target: '.js-wiki-page-content', title: @page.human_title, stylesheet: [stylesheet_path('application')] }.to_json } }
15+
#js-export-actions{ data: { options: { target: '.js-wiki-page-content', title: @page.human_title, stylesheet: [stylesheet_path('application')] }.to_json } }
1716

1817
- if @page.historical?
1918
= render Pajamas::AlertComponent.new(variant: :warning,

config/feature_flags/development/print_wiki.yml

Lines changed: 0 additions & 8 deletions
This file was deleted.

config/feature_flags/experiment/disable_network_graph_notes_count.yml

Lines changed: 0 additions & 8 deletions
This file was deleted.

config/metrics/schema/internal_events.json

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,41 @@
6363
"properties": {
6464
"instrumentation_class": {
6565
"const": "TotalCountMetric"
66+
},
67+
"options": {
68+
"type": "object",
69+
"properties": {
70+
"events": {
71+
"type": "array",
72+
"items": {
73+
"type": "string"
74+
}
75+
}
76+
},
77+
"required": [
78+
"events"
79+
],
80+
"additionalProperties": false
81+
},
82+
"events": {
83+
"type": "array",
84+
"items": {
85+
"type": "object",
86+
"required": [
87+
"name"
88+
],
89+
"properties": {
90+
"name": {
91+
"type": "string"
92+
}
93+
},
94+
"additionalProperties": false
95+
}
6696
}
6797
},
6898
"required": [
99+
"events",
100+
"options",
69101
"instrumentation_class"
70102
]
71103
}

config/metrics/schema/redis_hll.json

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,46 @@
3838
"properties": {
3939
"instrumentation_class": {
4040
"const": "AggregatedMetric"
41+
},
42+
"options": {
43+
"type": "object",
44+
"properties": {
45+
"aggregate": {
46+
"type": "object",
47+
"properties": {
48+
"operator": {
49+
"enum": [
50+
"OR",
51+
"AND"
52+
]
53+
},
54+
"attribute": {
55+
"type": "string"
56+
}
57+
},
58+
"required": [
59+
"operator",
60+
"attribute"
61+
],
62+
"additionalProperties": false
63+
},
64+
"events": {
65+
"type": "array",
66+
"items": {
67+
"type": "string"
68+
}
69+
}
70+
},
71+
"required": [
72+
"aggregate",
73+
"events"
74+
],
75+
"additionalProperties": false
4176
}
4277
},
4378
"required": [
44-
"instrumentation_class"
79+
"instrumentation_class",
80+
"options"
4581
]
4682
},
4783
{

doc/.vale/gitlab/LatinTerms.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ swap:
1515
e\. g\.: for example
1616
i\.e\.: that is
1717
i\. e\.: that is
18+
via: "Use 'with', 'through', or 'by using' instead."

doc/.vale/gitlab/Wordy.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ link: https://docs.gitlab.com/ee/development/documentation/styleguide/word_list.
1010
level: suggestion
1111
ignorecase: true
1212
swap:
13+
a number of: "Specify the number or remove the phrase."
1314
as well as: "Use 'and' instead of 'as well as'."
1415
note that: "Remove the phrase 'note that'."
1516
please: "Use 'please' only if we've inconvenienced the user."

0 commit comments

Comments
 (0)