title: Dependencies of a module
body: <p>I'm learning AutoFac.
  I like the idea of modules. From my understanding, I could for example create a module that registers some part of my application dependencies to the container to create some abstraction above it. However, I don't really know what to do in situations where I have multiple modules.</p>
  
  <ol>
  <li><p>First thing is, should I create a seperate LoggerModule just to do this:</p>
  
  <p>builder.RegisterType&lt;'MyLogger>().As&lt;'ILogger>();</p></li>
  </ol>
  
  <p>Or should it be put drectly in composition root? The question comes from my confusion if it's a good idea to register modules (higher abstraction) and services (lower abstraction) on the same level of composition root.
  Should modules be created only for services that use many dependencies, to make the registration simpler on the composition root level?</p>
  
  <ol start="2">
  <li><p>Another thing: What about my other modules that register services that require ILogger? Should I just assume that ILogger is already registered and just c.Resolve&lt;'ILogger>() or should I register it again so that every module has all needed dependencies registered?</p></li>
  <li><p>Can I create a module that registers other modules?</p></li>
  </ol>
  
  <p>I tried to look for answers to these, but I found only topics that were close, but not really about my issue.</p>