Skip to content

Conversation

@matelakat
Copy link

This is an amended version of #18 - to include one additional commit to skip populating the attribute cache for nil nodes.

Copy link

@houndci-bot houndci-bot left a comment

Choose a reason for hiding this comment

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

Some files could not be reviewed due to errors:

.rubocop.yml: Style/AlignHash has the wrong namespace - should be Layout
.rubocop.yml: Style/AlignHash has the wrong namespace - should be Layout
.rubocop.yml: Style/AlignParameters has the wrong namespace - should be Layout
.rubocop.yml: Style/EmptyLinesAroundBlockBody has the wrong namespace - should be Layout
.rubocop.yml: Style/MultilineOperationIndentation has the wrong namespace - should be Layout
Error: obsolete parameter AlignWith (for Lint/EndAlignment) found in .rubocop.yml
AlignWith has been renamed to EnforcedStyleAlignWith

MaximilianMeister and others added 17 commits June 22, 2017 11:27
* log message is misleading when node list is empty
* like this it is easier to see where (on which node) chef-client failed

(cherry picked from commit a5707a8)
(cherry picked from commit e8e721b)
Rename variables, remove unneeded logs.

(cherry picked from commit d4ed8c5)
(cherry picked from commit f33f254)
(cherry picked from commit a130195)
(cherry picked from commit f0b83f3)
Don't be so complicated to build a list of nodes...

(cherry picked from commit 91741e5)
(cherry picked from commit fe8e131)
This includes removing log lines which duplicate data already in the
debug logs.

(cherry picked from commit 8774bb2)
(cherry picked from commit a0d6671)
There was an attempt to fix the internal API so that
ServiceObject.apply_role always returns [int, str], but this actually
breaks the UI-only path in the controller.

So revert this and document with a FIXME that this should eventually be
fixed by moving everything to [int, hash] where we will have more
freedom.

https://bugzilla.suse.com/show_bug.cgi?id=989958
(cherry picked from commit 1ad0664)
(cherry picked from commit ec17274)
We move some code that must always be run before returning in the global
ensure; this helps make sure that code is actually run in all cases.

(cherry picked from commit 7010dc7)
(cherry picked from commit 99d978f)
We catch all exceptions that aren't caught from this method to set the
status of the proposal to "failed", to avoid people being blocked by a
proposal staying forever in "applying".

This helps with https://bugzilla.suse.com/show_bug.cgi?id=840255

(cherry picked from commit 43bc948)
(cherry picked from commit 50ec9c0)
This change makes the code a little bit more readable.

(cherry picked from commit 627e75b)
(cherry picked from commit 2717af2)
We mark it as applied when committing, but then we never reset it to not
applied when we do a change and just save. That results in the code
assuming that the saved proposal is always the latest one.

(cherry picked from commit cefacf6)
(cherry picked from commit 09e3303)
Was part of crowbar#560

(cherry picked from commit 7d12ecb)
(cherry picked from commit 457222b)
In a few cases, we load a node just to look for some attribute that we
could have cached earlier. So let's just do that.

(cherry picked from commit 3374d9f)
(cherry picked from commit 890e720)
We want to have more arguments, and it's going to be confusing.

(cherry picked from commit 6d69e8a)
(cherry picked from commit b31bec1)
It's done once when saving, and another time when applying.

(cherry picked from commit 50e24e2)
(cherry picked from commit 936f2c3)
If the node already has the info, then no need to save, which is
expensive.

(cherry picked from commit 2013a47)
(cherry picked from commit 85cf951)
(cherry picked from commit 1442925)
(cherry picked from commit b6b44c3)
`pre_cached_nodes` can contain nil nodes, so their attributes cannot be
put into `node_attr_cache`, skipping them.
Copy link

@houndci-bot houndci-bot left a comment

Choose a reason for hiding this comment

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

Some files could not be reviewed due to errors:

.rubocop.yml: Style/AlignHash has the wrong namespace - should be Layout
.rubocop.yml: Style/AlignHash has the wrong namespace - should be Layout
.rubocop.yml: Style/AlignParameters has the wrong namespace - should be Layout
.rubocop.yml: Style/EmptyLinesAroundBlockBody has the wrong namespace - should be Layout
.rubocop.yml: Style/MultilineOperationIndentation has the wrong namespace - should be Layout
Error: obsolete parameter AlignWith (for Lint/EndAlignment) found in .rubocop.yml
AlignWith has been renamed to EnforcedStyleAlignWith

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.

5 participants