Issue #21561 has been reported by Adrien Thebo. ---------------------------------------- Bug #21561: Using the ENC with multiple environments can load classes that can't be reloaded during a reparse of manifests https://projects.puppetlabs.com/issues/21561
* Author: Adrien Thebo * Status: Accepted * Priority: Normal * Assignee: * Category: environments * Target version: * Affected Puppet version: * Keywords: * Branch: ---------------------------------------- The ENC can specify a list of classes to load that may not be reachable if manifests are reparsed. If a manifest reparse is triggered (either through switching environments or because of a file change) any classes specified only by the ENC may be lost. When the catalog is being compiled, classes that are explicitly passed by an ENC are parsed first. Each class is explicitly [loaded by name](https://github.com/puppetlabs/puppet/blob/3.2.1/lib/puppet/parser/compiler.rb#L101). During compilation all classes and related information is loaded into a TypeCollection instance. A number of circumstances can cause all of this to be [dumped and reloaded](https://github.com/puppetlabs/puppet/blob/3.2.1/lib/puppet/node/environment.rb#L82). The code assumes that this is safe because after the information is dumped then an initial parse is triggered, starting with [`Puppet[:manifest]`](https://github.com/puppetlabs/puppet/blob/3.2.1/lib/puppet/node/environment.rb#L219). When the ENC doesn't supply an explicit list of classes then parsing the default manifest will find all manifests that can be reached. Since classes specified by the ENC are loaded by name, the assumption that all classes can by reached by parsing `Puppet[:manifest]` fails. If a reload is triggered then any classes explicitly loaded by the ENC will be permanently lost. -- 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. For more options, visit https://groups.google.com/groups/opt_out.
