The Puppet Labs Issue Tracker has Moved: https://tickets.puppetlabs.com

Bug #14210

Creating a relationship on half a composite namevar throws uninformative error.

Added by Cody Herriges over 2 years ago. Updated over 2 years ago.

Status:DuplicateStart date:04/26/2012
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:plumbing
Target version:-
Affected Puppet version:2.7.12 Branch:
Keywords:

We've Moved!

Ticket tracking is now hosted in JIRA: https://tickets.puppetlabs.com

This issue is currently not available for export. If you are experiencing the issue described below, please file a new ticket in JIRA. Once a new ticket has been created, please add a link to it that points back to this Redmine ticket.


Description

If you are creating relationships to a composite namevar and forget the qualifying portion of the title you will get a no method found error instead of an unable to find resource for relationship error. The following is the stacktrace and error.

/opt/puppet/lib/site_ruby/1.8/puppet/resource.rb:235:in `to_hash'
/opt/puppet/lib/site_ruby/1.8/puppet/resource.rb:244:in `uniqueness_key'
/opt/puppet/lib/site_ruby/1.8/puppet/resource/catalog.rb:427:in `resource'
/opt/puppet/lib/site_ruby/1.8/puppet/type.rb:1182:in `validate_relationship'
/opt/puppet/lib/site_ruby/1.8/puppet/type.rb:1181:in `each'
/opt/puppet/lib/site_ruby/1.8/puppet/type.rb:1181:in `validate_relationship'
/opt/puppet/lib/site_ruby/1.8/puppet/type.rb:1846:in `finish'
/opt/puppet/lib/site_ruby/1.8/puppet/type.rb:1844:in `collect'
/opt/puppet/lib/site_ruby/1.8/puppet/type.rb:1844:in `finish'
/opt/puppet/lib/site_ruby/1.8/puppet/type/file.rb:392:in `finish'
/opt/puppet/lib/site_ruby/1.8/puppet/resource/catalog.rb:253:in `finalize'
/opt/puppet/lib/site_ruby/1.8/puppet/resource/catalog.rb:253:in `each'
/opt/puppet/lib/site_ruby/1.8/puppet/resource/catalog.rb:253:in `finalize'
/opt/puppet/lib/site_ruby/1.8/puppet/configurer.rb:102:in `convert_catalog'
/opt/puppet/lib/site_ruby/1.8/puppet/configurer.rb:96:in `retrieve_catalog'
/opt/puppet/lib/site_ruby/1.8/puppet/configurer.rb:112:in `retrieve_and_apply_catalog'
/opt/puppet/lib/site_ruby/1.8/puppet/configurer.rb:152:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/agent.rb:44:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/agent/locker.rb:21:in `lock'
/opt/puppet/lib/site_ruby/1.8/puppet/agent.rb:44:in `run'
/opt/puppet/lib/ruby/1.8/sync.rb:230:in `synchronize'
/opt/puppet/lib/site_ruby/1.8/puppet/agent.rb:44:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/agent.rb:108:in `with_client'
/opt/puppet/lib/site_ruby/1.8/puppet/agent.rb:42:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/application.rb:172:in `call'
/opt/puppet/lib/site_ruby/1.8/puppet/application.rb:172:in `controlled_run'
/opt/puppet/lib/site_ruby/1.8/puppet/agent.rb:40:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/application/agent.rb:337:in `onetime'
/opt/puppet/lib/site_ruby/1.8/puppet/application/agent.rb:311:in `run_command'
/opt/puppet/lib/site_ruby/1.8/puppet/application.rb:309:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/application.rb:416:in `hook'
/opt/puppet/lib/site_ruby/1.8/puppet/application.rb:309:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/application.rb:407:in `exit_on_fail'
/opt/puppet/lib/site_ruby/1.8/puppet/application.rb:309:in `run'
/opt/puppet/lib/site_ruby/1.8/puppet/util/command_line.rb:69:in `execute'
/usr/local/bin/puppet:4
err: Failed to apply catalog: undefined method `merge' for #

This was found while working on https://github.com/puppetlabs/puppetlabs-java_ks. The relationship Java_ks[‘vhost.example.com’] will fail but Java_ks[‘vhost.example.com:keystore’] will succeed.

Note: Redmine is hiding the object type on the last line of the error above…even in a pre block.


Related issues

Duplicates Puppet - Bug #15264: Custom title patterns can fail cryptically Closed 06/27/2012

History

#1 Updated by Anonymous over 2 years ago

  • Category set to plumbing
  • Status changed from Unreviewed to Accepted

#2 Updated by Cody Herriges over 2 years ago

  • Description updated (diff)

#3 Updated by Cody Herriges over 2 years ago

  • Affected Puppet version set to 2.7.12

#4 Updated by Anonymous over 2 years ago

  • Status changed from Accepted to Duplicate

This got duplicated by #15264, work has been moved to that bug.

Also available in: Atom PDF