title: Puppet and realize virtual resources
body: <p>i'working on a puppetmodule for mongodb</p>
  
  <p>Here is what I have (stripped down to the basics):</p>
  
  <p>modules/mongodb/manifests/virtual.pp:</p>
  
  <pre><code>class mongodb::virtual {
  
    @package {['mongo-10gen-server','mongo-10gen']:
      ensure =&gt; installed
    }
  </code></pre>
  
  <p>modules/mongodb/manifests/replicaset.pp:</p>
  
  <pre><code>define mongodb::replicaset {
    realize( Package['mongo-10gen-server','mongo-10gen'] )
  }
  </code></pre>
  
  <p>quite simple, but when I do a puppetrun on the client:</p>
  
  <pre><code>Info: Retrieving plugin
  Info: Loading facts in /var/lib/puppet/lib/facter/custom_facts.rb
  Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Failed to realize virtual resources Package[mongo-10gen-server], Package[mongo-10gen] on node mongonode
  Warning: Not using cache on failed catalog
  Error: Could not retrieve catalog; skipping run
  </code></pre>
  
  <p>Any idea whats wrong with my setup?</p>