Bug #3118

External node tool definitions appear to be cumulative

Added by Markus Roberts 7 months ago. Updated 3 days ago.

Status:Needs design decision Start:01/27/2010
Priority:Normal Due date:
Assignee:- % Done:

0%

Category:-
Target version:-
Affected version:0.24.8 Branch:
Keywords:
Votes: 0

Description

This behavior is surprising, but not new.

Given the external node tool:

#!/usr/bin/env ruby
print %q{
---
classes:
  - foo
}
exit 0

And site.pp:

class foo {
    notice "foo"
}

class bar {
    notice "bar"
}

node default {
    include bar
}

The following results are seen:

info: Caching node for host-246-104.pubnet.pdx.edu
notice: Scope(Class[bar]): bar
notice: Scope(Class[foo]): foo
notice: Compiled catalog for host-246-104.pubnet.pdx.edu in 0.01 seconds

The same results are seen with 0.24.8 and 0.25.4rc3.

This appears to break the assumption that default is only applied for nodes that aren’t otherwise defined. The same is seen with an explicit node instead of just default in site.pp

History

Updated by Markus Roberts 7 months ago

  • Status changed from Unreviewed to Needs design decision
  • Affected version changed from 0.25.4rc3 to 0.24.8

Updated by Markus Roberts 7 months ago

Initial discussion indicates that some users consider this a bug (default should only apply to otherwise undefined nodes) while others consider it a feature (useful to augment behaviour of all nodes / specific nodes independently of the external node manager) and do not see it as surprising (default is defined with regard to the puppet code, and rightly takes no cognizance of what the node manager does).

Updated by Jeff McCune 3 days ago

Just to throw my two cents on the pile. I personally think this interaction with the default node classification in site.pp is a feature and not a bug.

Most people I talk with are not surprised by this behavior and have not asked for it to change when using an external node classifier.

Also available in: Atom PDF