Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent out-of-order deployments #115

Merged
merged 3 commits into from
Feb 23, 2023

Conversation

MartinBasti
Copy link
Collaborator

Fixing race condition where older pipeline could replace newer
deployment with image from older pipeline, if older pipeline was running
longer than latest one.

Helper functions to get succesfull runs of build pipeline runs.

I had to move `HasPipelineRunSucceeded` to `helpers` because it was
impossible to use it due ircular dependencies.

Signed-off-by: Martin Basti <mbasti@redhat.com>
@codecov
Copy link

codecov bot commented Feb 21, 2023

Codecov Report

Base: 70.98% // Head: 70.13% // Decreases project coverage by -0.86% ⚠️

Coverage data is based on head (aa20214) compared to base (fa22f5b).
Patch coverage: 81.81% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #115      +/-   ##
==========================================
- Coverage   70.98%   70.13%   -0.86%     
==========================================
  Files          25       25              
  Lines        2223     2297      +74     
==========================================
+ Hits         1578     1611      +33     
- Misses        494      537      +43     
+ Partials      151      149       -2     
Impacted Files Coverage Δ
tekton/utils.go 80.00% <ø> (-1.82%) ⬇️
controllers/pipeline/pipeline_adapter.go 54.65% <81.81%> (-3.63%) ⬇️
helpers/integration.go 68.82% <81.81%> (+1.67%) ⬆️
tekton/integration_pipeline.go 97.33% <0.00%> (-2.67%) ⬇️
controllers/snapshot/snapshot_adapter.go 56.72% <0.00%> (-1.84%) ⬇️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Fixing race condition where older pipeline could replace newer
deployment with image from older pipeline, if olded pipeline was running
longer than latest one.

Signed-off-by: Martin Basti <mbasti@redhat.com>
Make sure that correct log entry has been emitted.

Signed-off-by: Martin Basti <mbasti@redhat.com>
Copy link
Contributor

@jsztuka jsztuka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well done, LGTM

Copy link
Contributor

@hongweiliu17 hongweiliu17 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants