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 ...@@ -5,6 +5,8 @@ class Projects::ArtifactsController < Projects::ApplicationController
include RendersBlob include RendersBlob
include SendFileUpload include SendFileUpload
urgency :low, [:browse, :file, :latest_succeeded]
layout 'project' layout 'project'
before_action :authorize_read_build! before_action :authorize_read_build!
before_action :authorize_update_build!, only: [:keep] before_action :authorize_update_build!, only: [:keep]
......
...@@ -85,7 +85,8 @@ class Projects::MergeRequestsController < Projects::MergeRequests::ApplicationCo ...@@ -85,7 +85,8 @@ class Projects::MergeRequestsController < Projects::MergeRequests::ApplicationCo
:destroy, :destroy,
:rebase, :rebase,
:discussions, :discussions,
:pipelines :pipelines,
:test_reports
] ]
def index def index
......
...@@ -3,6 +3,8 @@ ...@@ -3,6 +3,8 @@
module Projects module Projects
module Pipelines module Pipelines
class TestsController < Projects::Pipelines::ApplicationController class TestsController < Projects::Pipelines::ApplicationController
urgency :low, [:show, :summary]
before_action :authorize_read_build! before_action :authorize_read_build!
before_action :builds, only: [:show] before_action :builds, only: [:show]
......
...@@ -5,7 +5,7 @@ class Projects::PipelinesController < Projects::ApplicationController ...@@ -5,7 +5,7 @@ class Projects::PipelinesController < Projects::ApplicationController
include RedisTracking include RedisTracking
urgency :default, [:status] 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 :disable_query_limiting, only: [:create, :retry]
before_action :pipeline, except: [:index, :new, :create, :charts, :config_variables] before_action :pipeline, except: [:index, :new, :create, :charts, :config_variables]
......
...@@ -28,7 +28,7 @@ module API ...@@ -28,7 +28,7 @@ module API
requires :job, type: String, desc: 'The name for the job' requires :job, type: String, desc: 'The name for the job'
end end
route_setting :authentication, job_token_allowed: true 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 requirements: { ref_name: /.+/ } do
authorize_download_artifacts! authorize_download_artifacts!
...@@ -87,7 +87,7 @@ module API ...@@ -87,7 +87,7 @@ module API
requires :artifact_path, type: String, desc: 'Artifact path' requires :artifact_path, type: String, desc: 'Artifact path'
end end
route_setting :authentication, job_token_allowed: true 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! authorize_download_artifacts!
build = find_build!(params[:job_id]) 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