summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShinya Maeda <shinya@gitlab.com>2018-10-02 13:32:35 +0900
committerAlessio Caiazza <acaiazza@gitlab.com>2018-10-02 17:08:14 +0200
commit8bc065e02dcc4582aebbc7d28a30f7468a15ccc0 (patch)
tree32bd024177c906d61cbb99abd599ada9863011b5
parent336affe911885a84c2f14193e3fa43f0320c0cb2 (diff)
downloadgitlab-ce-8bc065e02dcc4582aebbc7d28a30f7468a15ccc0.tar.gz
Rename failure reason to stale_schedule
-rw-r--r--app/models/commit_status.rb2
-rw-r--r--app/presenters/commit_status_presenter.rb2
-rw-r--r--app/workers/stuck_ci_jobs_worker.rb2
-rw-r--r--lib/gitlab/ci/status/build/failed.rb2
4 files changed, 4 insertions, 4 deletions
diff --git a/app/models/commit_status.rb b/app/models/commit_status.rb
index 2020dd637a0..06507345fe8 100644
--- a/app/models/commit_status.rb
+++ b/app/models/commit_status.rb
@@ -50,7 +50,7 @@ class CommitStatus < ActiveRecord::Base
runner_system_failure: 4,
missing_dependency_failure: 5,
runner_unsupported: 6,
- schedule_expired: 7
+ stale_schedule: 7
}
##
diff --git a/app/presenters/commit_status_presenter.rb b/app/presenters/commit_status_presenter.rb
index b2b9fb55cba..29eaad759bb 100644
--- a/app/presenters/commit_status_presenter.rb
+++ b/app/presenters/commit_status_presenter.rb
@@ -9,7 +9,7 @@ class CommitStatusPresenter < Gitlab::View::Presenter::Delegated
runner_system_failure: 'There has been a runner system failure, please try again',
missing_dependency_failure: 'There has been a missing dependency failure',
runner_unsupported: 'Your runner is outdated, please upgrade your runner',
- schedule_expired: 'Scheduled job could not be executed by some reason, please try again'
+ stale_schedule: 'Delayed job could not be executed by some reason, please try again'
}.freeze
private_constant :CALLOUT_FAILURE_MESSAGES
diff --git a/app/workers/stuck_ci_jobs_worker.rb b/app/workers/stuck_ci_jobs_worker.rb
index 5028965862f..cc5762156d7 100644
--- a/app/workers/stuck_ci_jobs_worker.rb
+++ b/app/workers/stuck_ci_jobs_worker.rb
@@ -75,7 +75,7 @@ class StuckCiJobsWorker
relation
.where('scheduled_at < ?', BUILD_SCHEDULED_OUTDATED_TIMEOUT.ago)
.find_each(batch_size: BUILD_SCHEDULED_OUTDATED_BATCH_SIZE) do |build|
- drop_build(:outdated, build, :scheduled, BUILD_SCHEDULED_OUTDATED_TIMEOUT, :schedule_expired)
+ drop_build(:outdated, build, :scheduled, BUILD_SCHEDULED_OUTDATED_TIMEOUT, :stale_schedule)
end
end
end
diff --git a/lib/gitlab/ci/status/build/failed.rb b/lib/gitlab/ci/status/build/failed.rb
index 014eb66a26b..50b0d044265 100644
--- a/lib/gitlab/ci/status/build/failed.rb
+++ b/lib/gitlab/ci/status/build/failed.rb
@@ -11,7 +11,7 @@ module Gitlab
runner_system_failure: 'runner system failure',
missing_dependency_failure: 'missing dependency failure',
runner_unsupported: 'unsupported runner',
- schedule_expired: 'schedule expired'
+ stale_schedule: 'stale schedule'
}.freeze
private_constant :REASONS