title: Unity and lifetime management configuration - always transient lifetime manager
body: <p>I have an configuration error with Unity. 
  I am trying to implement <a href="http://unitymvc3.codeplex.com/" rel="nofollow">http://unitymvc3.codeplex.com/</a>, but i am stucked right now, because of this:</p>
  
  <p>In my unity configuration I have this settings: </p>
  
  <pre><code>&lt;register type="IMainDbContext" mapTo="WorkflowContext"&gt;
      &lt;lifetime type="hierarchical" /&gt;
      &lt;constructor&gt;&lt;/constructor&gt;
    &lt;/register&gt;
  </code></pre>
  
  <p>But at the time of creating unity, (my simple code is here:)</p>
  
  <pre><code>UnityConfigurationSection section = ConfigurationManager.GetSection("unity") as UnityConfigurationSection;
          if (section != null)
          {
              section.Configure(container);
          }
  
          this.container = container;
  </code></pre>
  
  <p>everything is configured great, except of registration "IManDbContext" which has <code>LifetimeManagerType = {Name = "TransientLifetimeManager" FullName = "Microsoft.Practices.Unity.TransientLifetimeManager"}</code>, but it should be <code>hierarchical lifetime manager</code></p>
  
  <p>Have you got any ideas how tell unity (in configuration, not in code) i want hierarchical lifetime manager? 
  Thanks for any tips.</p>