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
Properly and consistently report changes in 'files' promises #4196
Properly and consistently report changes in 'files' promises #4196
Conversation
979fd3f
to
2390479
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.
Overall it looks good to me. Only one place I might consider additional changes to try and make the test result easier to expect.
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.
Here is a partial review. I will get back to the last 9 commits later.
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.
Nice one!
This pull request introduces 101 alerts and fixes 9 when merging 0ca76d2 into 2da72cc - view on LGTM.com new alerts:
fixed alerts:
|
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.
Looks good overall. Hard to thoroughly review everything, but the only major issue I saw was the missing continue
. Fix that, read through my comments and request another review :)
Pushed a commit fixing the manage_variable_values_ini.cf test, but the output from it now looks like this:
|
This pull request introduces 103 alerts and fixes 9 when merging de507ad into 2da72cc - view on LGTM.com new alerts:
fixed alerts:
|
@cf-bottom jenkins with exotics, please |
Sure, I triggered a build: (with exotics) Jenkins: https://ci.cfengine.com/job/pr-pipeline/5214/ Packages: http://buildcache.cfengine.com/packages/testing-pr/jenkins-pr-pipeline-5214/ |
763595e
to
f2715a3
Compare
@cf-bottom one last jenkins with exotics, please! 🤞 |
Alright, I triggered a build: (with exotics) Jenkins: https://ci.cfengine.com/job/pr-pipeline/5250/ Packages: http://buildcache.cfengine.com/packages/testing-pr/jenkins-pr-pipeline-5250/ |
This pull request introduces 98 alerts and fixes 9 when merging f2715a3 into 806cbaa - view on LGTM.com new alerts:
fixed alerts:
|
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, please review the jenkins failure before merging.
More high-level function than just 'Log()' which, unlike 'cfPS()', say nothing about the state of the whole promise because one promise can cause multiple changes on the system. Ticket: ENT-5291 Changelog: None
So that we can report the fact. Ticket: ENT-5291 Changelog: None
It should report all changes it makes. And it should use LogChange() instead of cfPS() for doing so because cfPS() is for reporting status of a whole promise. Ticket: ENT-5291 Changelog: Directory and file creations are now properly reported as 'info' messages
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Also report failures as failures not interruptions. Ticket: ENT-5291 Changelog: Failures in edit_xml result in promises marked as failed not interrupted
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: All changes made by 'files' promises are now reported
Ticket: ENT-5291 Changelog: None
With the improved changes reporting the test now produces 'info:' lines which are expected. Ticket: ENT-5291 Changelog: None
Also adapt the 10_files/02_maintain/changes_update_hashes.cf test and add comments about why certain classes are (not) defined. Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
The outcome classes are now defined for the top-level directory even if 'include_basedir' is 'false'. It makes more sense -- if there are changes made in the directory, the respective '_repaired' class is defined. And then it can be used for things like "Do we need to update the archive/backup of that directory?". Ticket: ENT-5291 Changelog: The outcome classes are now defined for the top-level directory when 'include_basedir' is 'false'
It's a set of permissions. Ticket: ENT-5291 Changelog: None
The log messages are now slightly different. Ticket: ENT-5291 Changelog: None
If 'preserve => "true"' is used in a copy_from body and the xattrs of the source and the destination are the same, the destination's xattrs should not be overwritten by the source's xattrs. Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
Ticket: ENT-5291 Changelog: None
f2715a3
to
9f11404
Compare
This pull request introduces 98 alerts and fixes 9 when merging 9f11404 into 986bb33 - view on LGTM.com new alerts:
fixed alerts:
|
Merge together:
#4196
https://github.com/cfengine/enterprise/pull/619