diff options
author | Douwe Maan <douwe@gitlab.com> | 2019-06-24 12:19:27 +0300 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2019-06-24 12:19:27 +0300 |
commit | 6177bc1d69ca4870672a9db1af3b5f6798674676 (patch) | |
tree | c768bffb24322024a636ae182a6144f62a59eb7c /app | |
parent | 74c8f7848e1da93b99e2e7fe06d1098ae1fa7357 (diff) | |
parent | 26b057293d18f35367e39882f3724372b616dc51 (diff) |
Merge branch 'remove_create_deployment_from_build_success_worker' into 'master'
Remove deprecated call in BuildSuccessWorker
Closes #63622
See merge request gitlab-org/gitlab-ce!29958
Diffstat (limited to 'app')
-rw-r--r-- | app/workers/build_success_worker.rb | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/app/workers/build_success_worker.rb b/app/workers/build_success_worker.rb index 9a865fea621..ac947f3cf38 100644 --- a/app/workers/build_success_worker.rb +++ b/app/workers/build_success_worker.rb @@ -9,7 +9,6 @@ class BuildSuccessWorker # rubocop: disable CodeReuse/ActiveRecord def perform(build_id) Ci::Build.find_by(id: build_id).try do |build| - create_deployment(build) if build.has_environment? stop_environment(build) if build.stops_environment? end end @@ -18,17 +17,6 @@ class BuildSuccessWorker private ## - # Deprecated: - # As of 11.5, we started creating a deployment record when ci_builds record is created. - # Therefore we no longer need to create a deployment, after a build succeeded. - # We're leaving this code for the transition period, but we can remove this code in 11.6. - def create_deployment(build) - build.create_deployment.try do |deployment| - deployment.succeed - end - end - - ## # TODO: This should be processed in DeploymentSuccessWorker once we started storing `action` value in `deployments` records def stop_environment(build) build.persisted_environment.fire_state_event(:stop) |