On Mon, Jun 13, 2011 at 10:18 AM, Randall Hansen <[email protected]>wrote:
> I think Aaron lays out the options pretty well. This issue has been > hanging fire for quite a while, and it would be nice to come to a > decision about what our path forward is. > > Who else cares about this? What do you think? > > r > > On Wed, Jun 8, 2011 at 1:36 PM, Aaron Grewell <[email protected]> > wrote: > > We've looked at two different possibilities thus far: > > > > 1) Make all resource types hash-aware. This is what I was originally > asking > > for. It would mean changing the way resources are declared so that in > the > > case of a hash their representation of $name was appropriate for use with > > defines and virtuals. This could either be done by requiring the hash to > > have a 'name' key and using that or by creating a metaparameter like > > hash_key so it could be user-specified. The hash itself would need to be > > passed to the resource in the same way as $name but with a different > > identifier so that its keys could be accessed inside the resource as e.g. > > $data[key]. > > > > The upside of this is that it should work universally and conceptually > match > > the rest of Puppet, the downsides I see so far are that its > implementation > > might well be intrusive and it might also add to the DSL. > > > > 2) Create a hash -> resource transformation function. If I understood > John > > correctly this is what he was in favor of. > > > > The upside of this is it should be less intrusive, easier to implement, > and > > require no DSL changes. The downside is that it still makes hashes > special > > and requires separate handling of them. > As an additional upside, this already exists in 2.7 and is called create_resources There is discussion around this topic at: http://projects.puppetlabs.com/issues/5909 > -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/puppet-users?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
