Issue #5350 has been updated by Charlie Sharpsteen.

Category changed from tags to compiler
Status changed from Accepted to Duplicate
Assignee changed from eric sorenson to Charlie Sharpsteen

Dan Bode nailed the problem on the head in his earlier comment. Marking as a 
duplicate of #3845.

----------------------------------------
Bug #5350: Implicit tags not matched in collection while expressing relationship
https://projects.puppetlabs.com/issues/5350#change-90946

* Author: Owen Smith
* Status: Duplicate
* Priority: Normal
* Assignee: Charlie Sharpsteen
* Category: compiler
* Target version: 
* Affected Puppet version: 2.6.3
* Keywords: tag collection relationship class
* Branch: 
----------------------------------------
### Overview ###

I'm noticing that class tags are not being matched when specifying 
relationships between collections.

Note that this may be a general problem with implicit tags in collections. 
Issue #4560 describes a similar problem with collection-based realization. If 
these bugs have the same root cause, please merge the issues at your discretion.

### Steps to reproduce ###

With Puppet, execute the following code:

    class a {
      notify { "notea": message => "A" }
    }
    
    class b {
      notify { "noteb": message => "B" }
    }
    
    Notify<| tag == "b" |> -> Notify<| tag == "a" |>
    
    node default {
      include a
      include b
    }

using the `--graph` option. Say the graphs are generated in 
`/var/lib/puppet/state/graphs`.

Then examine the file `relationships.dot` in the graphs directory. 

### Expected Output ###

`relationships.dot` should contain the following code:

    "Notify[noteb]" -> "Notify[notea]" [
        fontsize = 8
    ]

indicating that there is a relationship between `Notify[notea]` and 
`Notify[noteb]`.

### Actual Output ###

No such code exists in relationships.dot, meaning that the notifications may 
execute in either order, despite the relationship declaration in the Puppet 
code.

### Workaround ###

If the tags are made explicit, this works:

    class a { 
      notify { "notea": message => "A", tag => "a" } 
    } 
    
    class b { 
      notify { "noteb": message => "B", tag => "b" } 
    } 
    
    Notify<| tag == "b" |> -> Notify<| tag == "a" |>
    
    node default { 
      include a 
      include b 
    } 

The intent with the collection-based resource declaration, however, is to 
simplify the resource declarations themselves, so this workaround doesn't buy 
me much.



-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to