Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
bfe2a24d
Commit
bfe2a24d
authored
Oct 29, 2020
by
Bob Van Landuyt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add feature categories to the API B -> G
This adds a feature category to API classes from B -> G
parent
d4e08b04
Changes
33
Hide whitespace changes
Inline
Side-by-side
Showing
33 changed files
with
75 additions
and
1 deletion
+75
-1
lib/api/badges.rb
lib/api/badges.rb
+2
-0
lib/api/boards.rb
lib/api/boards.rb
+2
-0
lib/api/branches.rb
lib/api/branches.rb
+2
-0
lib/api/broadcast_messages.rb
lib/api/broadcast_messages.rb
+2
-0
lib/api/ci/pipeline_schedules.rb
lib/api/ci/pipeline_schedules.rb
+2
-0
lib/api/ci/pipelines.rb
lib/api/ci/pipelines.rb
+2
-0
lib/api/ci/runner.rb
lib/api/ci/runner.rb
+2
-0
lib/api/ci/runners.rb
lib/api/ci/runners.rb
+2
-0
lib/api/commit_statuses.rb
lib/api/commit_statuses.rb
+2
-0
lib/api/commits.rb
lib/api/commits.rb
+2
-0
lib/api/container_registry_event.rb
lib/api/container_registry_event.rb
+2
-0
lib/api/deploy_keys.rb
lib/api/deploy_keys.rb
+2
-0
lib/api/deploy_tokens.rb
lib/api/deploy_tokens.rb
+2
-0
lib/api/deployments.rb
lib/api/deployments.rb
+2
-0
lib/api/environments.rb
lib/api/environments.rb
+2
-0
lib/api/error_tracking.rb
lib/api/error_tracking.rb
+2
-0
lib/api/events.rb
lib/api/events.rb
+2
-0
lib/api/feature_flag_scopes.rb
lib/api/feature_flag_scopes.rb
+2
-0
lib/api/feature_flags.rb
lib/api/feature_flags.rb
+2
-0
lib/api/feature_flags_user_lists.rb
lib/api/feature_flags_user_lists.rb
+2
-0
lib/api/features.rb
lib/api/features.rb
+2
-0
lib/api/files.rb
lib/api/files.rb
+2
-0
lib/api/freeze_periods.rb
lib/api/freeze_periods.rb
+2
-0
lib/api/group_boards.rb
lib/api/group_boards.rb
+2
-0
lib/api/group_clusters.rb
lib/api/group_clusters.rb
+2
-0
lib/api/group_container_repositories.rb
lib/api/group_container_repositories.rb
+2
-0
lib/api/group_export.rb
lib/api/group_export.rb
+2
-0
lib/api/group_import.rb
lib/api/group_import.rb
+2
-0
lib/api/group_labels.rb
lib/api/group_labels.rb
+2
-0
lib/api/group_milestones.rb
lib/api/group_milestones.rb
+2
-0
lib/api/group_variables.rb
lib/api/group_variables.rb
+2
-0
lib/api/groups.rb
lib/api/groups.rb
+2
-0
spec/lib/api/every_api_endpoint_spec.rb
spec/lib/api/every_api_endpoint_spec.rb
+11
-1
No files found.
lib/api/badges.rb
View file @
bfe2a24d
...
...
@@ -8,6 +8,8 @@ module API
helpers
::
API
::
Helpers
::
BadgesHelpers
feature_category
:continuous_integration
helpers
do
def
find_source_if_admin
(
source_type
)
source
=
find_source
(
source_type
,
params
[
:id
])
...
...
lib/api/boards.rb
View file @
bfe2a24d
...
...
@@ -9,6 +9,8 @@ module API
before
{
authenticate!
}
feature_category
:boards
helpers
do
def
board_parent
user_project
...
...
lib/api/branches.rb
View file @
bfe2a24d
...
...
@@ -10,6 +10,8 @@ module API
after_validation
{
content_type
"application/json"
}
feature_category
:source_code_management
before
do
require_repository_enabled!
authorize!
:download_code
,
user_project
...
...
lib/api/broadcast_messages.rb
View file @
bfe2a24d
...
...
@@ -4,6 +4,8 @@ module API
class
BroadcastMessages
<
::
API
::
Base
include
PaginationParams
feature_category
:navigation
resource
:broadcast_messages
do
helpers
do
def
find_message
...
...
lib/api/ci/pipeline_schedules.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate!
}
feature_category
:continuous_integration
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a project'
end
...
...
lib/api/ci/pipelines.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate_non_get!
}
feature_category
:continuous_integration
params
do
requires
:id
,
type:
String
,
desc:
'The project ID'
end
...
...
lib/api/ci/runner.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
content_type
:txt
,
'text/plain'
feature_category
:continuous_integration
resource
:runners
do
desc
'Registers a new Runner'
do
success
Entities
::
RunnerRegistrationDetails
...
...
lib/api/ci/runners.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate!
}
feature_category
:continuous_integration
resource
:runners
do
desc
'Get runners available for user'
do
success
Entities
::
Runner
...
...
lib/api/commit_statuses.rb
View file @
bfe2a24d
...
...
@@ -4,6 +4,8 @@ require 'mime/types'
module
API
class
CommitStatuses
<
::
API
::
Base
feature_category
:continuous_integration
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a project'
end
...
...
lib/api/commits.rb
View file @
bfe2a24d
...
...
@@ -6,6 +6,8 @@ module API
class
Commits
<
::
API
::
Base
include
PaginationParams
feature_category
:source_code_management
before
do
require_repository_enabled!
authorize!
:download_code
,
user_project
...
...
lib/api/container_registry_event.rb
View file @
bfe2a24d
...
...
@@ -4,6 +4,8 @@ module API
class
ContainerRegistryEvent
<
::
API
::
Base
DOCKER_DISTRIBUTION_EVENTS_V1_JSON
=
'application/vnd.docker.distribution.events.v1+json'
feature_category
:package_registry
before
{
authenticate_registry_notification!
}
resource
:container_registry_event
do
...
...
lib/api/deploy_keys.rb
View file @
bfe2a24d
...
...
@@ -6,6 +6,8 @@ module API
before
{
authenticate!
}
feature_category
:continuous_delivery
helpers
do
def
add_deploy_keys_project
(
project
,
attrs
=
{})
project
.
deploy_keys_projects
.
create
(
attrs
)
...
...
lib/api/deploy_tokens.rb
View file @
bfe2a24d
...
...
@@ -4,6 +4,8 @@ module API
class
DeployTokens
<
::
API
::
Base
include
PaginationParams
feature_category
:continuous_delivery
helpers
do
def
scope_params
scopes
=
params
.
delete
(
:scopes
)
...
...
lib/api/deployments.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate!
}
feature_category
:continuous_delivery
params
do
requires
:id
,
type:
String
,
desc:
'The project ID'
end
...
...
lib/api/environments.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate!
}
feature_category
:continuous_delivery
params
do
requires
:id
,
type:
String
,
desc:
'The project ID'
end
...
...
lib/api/error_tracking.rb
View file @
bfe2a24d
...
...
@@ -4,6 +4,8 @@ module API
class
ErrorTracking
<
::
API
::
Base
before
{
authenticate!
}
feature_category
:error_tracking
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a project'
end
...
...
lib/api/events.rb
View file @
bfe2a24d
...
...
@@ -8,6 +8,8 @@ module API
allow_access_with_scope
:read_user
,
if:
->
(
request
)
{
request
.
get?
}
feature_category
:users
resource
:events
do
desc
"List currently authenticated user's events"
do
detail
'This feature was introduced in GitLab 9.3.'
...
...
lib/api/feature_flag_scopes.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
ENVIRONMENT_SCOPE_ENDPOINT_REQUIREMENTS
=
FeatureFlags
::
FEATURE_FLAG_ENDPOINT_REQUIREMENTS
.
merge
(
environment_scope:
API
::
NO_SLASH_URL_PART_REGEX
)
feature_category
:feature_flags
before
do
authorize_read_feature_flags!
end
...
...
lib/api/feature_flags.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
FEATURE_FLAG_ENDPOINT_REQUIREMENTS
=
API
::
NAMESPACE_OR_PROJECT_REQUIREMENTS
.
merge
(
name:
API
::
NO_SLASH_URL_PART_REGEX
)
feature_category
:feature_flags
before
do
authorize_read_feature_flags!
end
...
...
lib/api/feature_flags_user_lists.rb
View file @
bfe2a24d
...
...
@@ -8,6 +8,8 @@ module API
message
.
is_a?
(
String
)
?
{
message:
message
}.
to_json
:
message
.
to_json
}
feature_category
:feature_flags
before
do
authorize_admin_feature_flags_user_lists!
end
...
...
lib/api/features.rb
View file @
bfe2a24d
...
...
@@ -4,6 +4,8 @@ module API
class
Features
<
::
API
::
Base
before
{
authenticated_as_admin!
}
feature_category
:feature_flags
helpers
do
def
gate_value
(
params
)
case
params
[
:value
]
...
...
lib/api/files.rb
View file @
bfe2a24d
...
...
@@ -9,6 +9,8 @@ module API
# Prevents returning plain/text responses for files with .txt extension
after_validation
{
content_type
"application/json"
}
feature_category
:source_code_management
helpers
::
API
::
Helpers
::
HeadersHelpers
helpers
do
...
...
lib/api/freeze_periods.rb
View file @
bfe2a24d
...
...
@@ -6,6 +6,8 @@ module API
before
{
authenticate!
}
feature_category
:continuous_delivery
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a project'
end
...
...
lib/api/group_boards.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
prepend_if_ee
(
'EE::API::BoardsResponses'
)
# rubocop: disable Cop/InjectEnterpriseEditionModule
feature_category
:boards
before
do
authenticate!
end
...
...
lib/api/group_clusters.rb
View file @
bfe2a24d
...
...
@@ -6,6 +6,8 @@ module API
before
{
authenticate!
}
feature_category
:kubernetes_management
params
do
requires
:id
,
type:
String
,
desc:
'The ID of the group'
end
...
...
lib/api/group_container_repositories.rb
View file @
bfe2a24d
...
...
@@ -8,6 +8,8 @@ module API
before
{
authorize_read_group_container_images!
}
feature_category
:package_registry
REPOSITORY_ENDPOINT_REQUIREMENTS
=
API
::
NAMESPACE_OR_PROJECT_REQUIREMENTS
.
merge
(
tag_name:
API
::
NO_SLASH_URL_PART_REGEX
)
...
...
lib/api/group_export.rb
View file @
bfe2a24d
...
...
@@ -10,6 +10,8 @@ module API
authorize!
:admin_group
,
user_group
end
feature_category
:importers
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a group'
end
...
...
lib/api/group_import.rb
View file @
bfe2a24d
...
...
@@ -2,6 +2,8 @@
module
API
class
GroupImport
<
::
API
::
Base
feature_category
:importers
helpers
Helpers
::
FileUploadHelpers
helpers
do
...
...
lib/api/group_labels.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate!
}
feature_category
:issue_tracking
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a group'
end
...
...
lib/api/group_milestones.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate!
}
feature_category
:issue_tracking
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a group'
end
...
...
lib/api/group_variables.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate!
}
before
{
authorize!
:admin_build
,
user_group
}
feature_category
:continuous_integration
params
do
requires
:id
,
type:
String
,
desc:
'The ID of a group'
end
...
...
lib/api/groups.rb
View file @
bfe2a24d
...
...
@@ -7,6 +7,8 @@ module API
before
{
authenticate_non_get!
}
feature_category
:subgroups
helpers
Helpers
::
GroupsHelpers
helpers
do
...
...
spec/lib/api/every_api_endpoint_spec.rb
View file @
bfe2a24d
...
...
@@ -22,7 +22,17 @@ RSpec.describe 'Every API endpoint' do
completed_classes
=
[
::
API
::
Users
,
::
API
::
Issues
,
::
API
::
AccessRequests
,
::
API
::
Admin
::
Ci
::
Variables
,
::
API
::
Admin
::
InstanceClusters
,
::
API
::
Admin
::
Sidekiq
,
::
API
::
Appearance
,
::
API
::
Applications
,
::
API
::
Avatar
,
::
API
::
AwardEmoji
::
API
::
Applications
,
::
API
::
Avatar
,
::
API
::
AwardEmoji
,
API
::
Badges
,
::
API
::
Boards
,
::
API
::
Branches
,
::
API
::
BroadcastMessages
,
::
API
::
Ci
::
Pipelines
,
::
API
::
Ci
::
PipelineSchedules
,
::
API
::
Ci
::
Runners
,
::
API
::
Ci
::
Runner
,
::
API
::
Commits
,
::
API
::
CommitStatuses
,
::
API
::
ContainerRegistryEvent
,
::
API
::
DeployKeys
,
::
API
::
DeployTokens
,
::
API
::
Deployments
,
::
API
::
Environments
,
::
API
::
ErrorTracking
,
::
API
::
Events
,
::
API
::
FeatureFlags
,
::
API
::
FeatureFlagScopes
,
::
API
::
FeatureFlagsUserLists
,
::
API
::
Features
,
::
API
::
Files
,
::
API
::
FreezePeriods
,
::
API
::
GroupBoards
,
::
API
::
GroupClusters
,
::
API
::
GroupExport
,
::
API
::
GroupImport
,
::
API
::
GroupLabels
,
::
API
::
GroupMilestones
,
::
API
::
Groups
,
::
API
::
GroupContainerRepositories
,
::
API
::
GroupVariables
]
next
unless
completed_classes
.
include?
(
klass
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment