Commit cb7b9177 authored by Heinrich Lee Yu's avatar Heinrich Lee Yu

Merge branch '355848-custom-sli-for-endpoints' into 'master'

Set low urgency for Pipeline Insights endpoints

See merge request gitlab-org/gitlab!83432
parents c00ea95b 7371da19
......@@ -5,6 +5,8 @@ class Projects::ArtifactsController < Projects::ApplicationController
include RendersBlob
include SendFileUpload
urgency :low, [:browse, :file, :latest_succeeded]
layout 'project'
before_action :authorize_read_build!
before_action :authorize_update_build!, only: [:keep]
......
......@@ -85,7 +85,8 @@ class Projects::MergeRequestsController < Projects::MergeRequests::ApplicationCo
:destroy,
:rebase,
:discussions,
:pipelines
:pipelines,
:test_reports
]
def index
......
......@@ -3,6 +3,8 @@
module Projects
module Pipelines
class TestsController < Projects::Pipelines::ApplicationController
urgency :low, [:show, :summary]
before_action :authorize_read_build!
before_action :builds, only: [:show]
......
......@@ -5,7 +5,7 @@ class Projects::PipelinesController < Projects::ApplicationController
include RedisTracking
urgency :default, [:status]
urgency :low, [:index, :new, :builds, :show, :failures, :create, :stage, :retry, :dag, :cancel]
urgency :low, [:index, :new, :builds, :show, :failures, :create, :stage, :retry, :dag, :cancel, :test_report]
before_action :disable_query_limiting, only: [:create, :retry]
before_action :pipeline, except: [:index, :new, :create, :charts, :config_variables]
......
......@@ -28,7 +28,7 @@ module API
requires :job, type: String, desc: 'The name for the job'
end
route_setting :authentication, job_token_allowed: true
get ':id/jobs/artifacts/:ref_name/download',
get ':id/jobs/artifacts/:ref_name/download', urgency: :low,
requirements: { ref_name: /.+/ } do
authorize_download_artifacts!
......@@ -87,7 +87,7 @@ module API
requires :artifact_path, type: String, desc: 'Artifact path'
end
route_setting :authentication, job_token_allowed: true
get ':id/jobs/:job_id/artifacts/*artifact_path', format: false do
get ':id/jobs/:job_id/artifacts/*artifact_path', urgency: :low, format: false do
authorize_download_artifacts!
build = find_build!(params[:job_id])
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment