-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
feat(application-controller): Add support for rollback multi-source applications #14124
feat(application-controller): Add support for rollback multi-source applications #14124
Conversation
fd30f30
to
b2d284b
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #14124 +/- ##
==========================================
+ Coverage 45.00% 45.01% +0.01%
==========================================
Files 354 354
Lines 47959 48018 +59
==========================================
+ Hits 21582 21617 +35
- Misses 23574 23594 +20
- Partials 2803 2807 +4 ☔ View full report in Codecov by Sentry. |
Please, put special attention reviewing the frontend because I'm not frontend developer and maybe I have done something terriblely wrong |
Thanks for implementing this. Hope it gets merged soon :) |
Thanks for the PR! We're past feature freeze for 2.8, so I'll queue this up for the 2.9 roadmap. |
Sure 😄 |
Makes sense! At least 3 weeks out, I'm focusing on getting 2.8 ready for GA for now. |
After vacations (I'll take them the first half of August so during second half) looks as a nice moment to rebase the PR with latest changes 😄 |
Hoping to have this merged soon. 🙏 |
Hi @crenshaw-dev |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only had time for a quick glance, opened one can of worms. :-)
fadc943
to
99e0b80
Compare
Sorry, I needed more time that I expected for rebasing the PR 🤦 (the summer break has erased my memory 100%) |
I have removed the logic from here and I have moved it into the state |
Any news on this? Do you guys need an extra pair of hands? |
It's waiting a review 😄 |
@Pehesi97 we need lots of extra pairs of hands. 😆 |
Any predictions on when it will be released? |
@GuerreiroLeonardo , if you could help them reviewing the code, I think this will be faster for sure 😄 |
@JorTurFer JorTurFer I wish I could, I have no knowledge on the argoCD code. I am simply a user right now hahah. I gues it would take a lot of hours until I am proficient enough to give any relevant contribution. Sorry =/ |
We also consider this PR important, do not have to capabilities to look at the code, but could test it once it gets released. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd want to see:
- design doc
- user facing documentation
- a ui demo (so I can kick the tires) -- the picture in feat(application-controller): Add support for rollback multi-source applications #14124 (comment) should be in the description.
Note that I'm not wearing a project owner hat, this what I'd want as a drive-by reviewer / UI person / end user.
util/argo/ref_sources.go
Outdated
} | ||
|
||
// GetRefSources creates a map of ref keys (from the sources' 'ref' fields) to information about the referenced source. | ||
// This function also validates the references use allowed characters and does not define the same ref key more than |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// This function also validates the references use allowed characters and does not define the same ref key more than | |
// This function also validates the references use allowed characters and do not define the same ref key more than |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is a spelling error on a comment a good reason to ask for a review on such a feature? Seems a good way to make contributors stop contributing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I took the code from argo.go and I moved it as it was and i didn't notice it. I'll update it 😄
util/argo/ref_sources.go
Outdated
} | ||
refKey := "$" + source.Ref | ||
if _, ok := refKeys[refKey]; ok { | ||
return nil, fmt.Errorf("invalid sources: multiple sources had the same `ref` key") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it'd be really nice if errors like this reported at least a pair of sources so that users have something to chase
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I took the code from argo.go
and I moved it as it is but I could add the key to the message if you think is useful
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My goal is to be able to read a message and figure out how to address it. If this error will be shown as is, I'd want to see the id of the thing (is it an application/<x>
?) and two sources
that had the same ref
(preferably with the ref
). If it's going to be pasted w/ other things, then as long as once it's pasted it has those bits, that'd make it usable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd try to improve the message 😄
I'll review the logic trying to figure out the best way to print the message
Why do I see the same revision twice? If I can't kick the tires, could you at please kick the tires for me? User Story:
|
Hi @jsoref About the user documentation, the UX is the same because I haven't added any new interaction, I just enabled an already existing button.
Because probably I used the same repository for both sources, sorry. I didn't think that it was important.
Except for how the multiple sources are presented, all the other points are exactly the same as the current scenario. It's true that I added the extra sources information to the UI (using the parenthesis), but I can remove it if you think that it's wrong. |
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl>
Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es>
Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl>
9813bdd
to
49a8b31
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!! Thanks @JorTurFer !! Approving with fact that @keithchong will be raising a follow on PR to fix the UI issues he identified.
Thanks @crenshaw-dev @ishitasequeira and @keithchong for your support! ❤️ |
This is wonderful news! Thank you all for your efforts. |
…pplications (argoproj#14124) * feat(application-controller): Add support for rollback multi-source applications Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * regenerate codegen after rebase Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix tests Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix front linting Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update test Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update codegen Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Update server/application/application.go Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> * apply feedback Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix errors Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add support for switching between single and multi Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix dereference issue Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * remove unnecesary code Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Rebase master Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> * fix style Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix reference Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add a comment Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> --------- Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com>
…pplications (argoproj#14124) * feat(application-controller): Add support for rollback multi-source applications Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * regenerate codegen after rebase Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix tests Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix front linting Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update test Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update codegen Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Update server/application/application.go Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> * apply feedback Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix errors Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add support for switching between single and multi Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix dereference issue Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * remove unnecesary code Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Rebase master Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> * fix style Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix reference Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add a comment Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> --------- Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com>
…pplications (argoproj#14124) * feat(application-controller): Add support for rollback multi-source applications Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * regenerate codegen after rebase Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix tests Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix front linting Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update test Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update codegen Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Update server/application/application.go Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> * apply feedback Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix errors Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add support for switching between single and multi Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix dereference issue Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * remove unnecesary code Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Rebase master Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> * fix style Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix reference Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add a comment Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> --------- Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com>
…pplications (argoproj#14124) * feat(application-controller): Add support for rollback multi-source applications Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * regenerate codegen after rebase Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix tests Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix front linting Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update test Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * update codegen Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Update server/application/application.go Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> * apply feedback Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix errors Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add support for switching between single and multi Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix dereference issue Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * remove unnecesary code Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * Rebase master Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> * fix style Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * fix reference Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> * add a comment Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> --------- Signed-off-by: Jorge Turrado <jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado Ferrero <Jorge_turrado@hotmail.es> Signed-off-by: Jorge Turrado <jorge.turrado@scrm.lidl> Co-authored-by: Ishita Sequeira <46771830+ishitasequeira@users.noreply.github.com> Signed-off-by: Javier Solana <javier.solana@cabify.com> Signed-off-by: Javier Solana <javier.solana@cabify.com>
Hello ! |
@afreyermuth98 this should be available in 2.12. |
Signed-off-by: Jorge Turrado jorge.turrado@scrm.lidl
Currently, ArgoCD support multi-source applications and that's a really nice feature, but using multi source, end users have to sacrify the option of executing fast rollbacks because the rollbacks are not supported for multi-source applications.
This PR adds the support for rollback multi-source applications (as single source applications do)
Note on DCO:
If the DCO action in the integration test fails, one or more of your commits are not signed off. Please click on the Details link next to the DCO action for instructions on how to resolve this.
Checklist:
Please see Contribution FAQs if you have questions about your pull-request.
Fixes #12580