On Wednesday, October 8, 2014 6:55:19 AM UTC-5, Felix Frank wrote: > > On 10/08/2014 01:23 PM, Trevor Vaughan wrote: > > > > service { 'my_service': require => Package['mysql']{ :provider => 'gem' > } } > > How about require => Package<| title == 'mysql' and provider == 'gem' |> >
I filed a feature request years ago to support exactly that (Collections as rvalues). I didn't think it was ever implemented as such, but the chain operators cover more or less the same ground. > > Not that it matters - having two Package[mysql] resources will *never* > be a thing. > > If I understand Andy correctly, we might have something like > > package { 'mysql-gem': package_name => mysql, provider => gem } > > ...which is awful I guess. Anyway, relationship targets will not be > jeopardized (that I can see). > It is more than awful. It either overloads the package title in dangerous ways, or else it deeply undermines Puppet's protections against duplicate resources. Consider, what is the meaning of this: package { 'mysql-gem': package_name => 'mysql', provider => 'yum' } ? Does it duplicate any or all of these resources? package { 'mysql-yum': package_name => 'mysql', provider => 'yum' } package { 'mysql-rpm': package_name => 'mysql', provider => 'rpm' } package { 'mysql-gem': package_name => 'mysql' } ? Do the the above Package['mysql-yum'] and Package['mysql-rpm'] conflict with each other? (They should.) I can come up with bunches of similar issues. John -- You received this message because you are subscribed to the Google Groups "Puppet Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-dev+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-dev/2522e510-49d9-4389-a673-f89fe46ace10%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.