title: StructureMap and SqlCacheDependency
body: <p>I'm trying to enable SqlCacheDependency through my StructureMap IoC, I'm using LinqToSql I have the code done to take care of the Linq Caching but not quite sure how to go about setting up the SqlCacheDependency as it requires putting this in a global.asa file</p>
  
  <pre><code>void Application_Start(object sender, EventArgs e) 
  {
      string connectionString = WebConfigurationManager.
          ConnectionStrings["Catalog"].ConnectionString;
      SqlDependency.Start(connectionString);
  }
  </code></pre>
  
  <p>However my repository doesn't use a global.asa as its just a library (.dll) not a web application.</p>
  
  <p>Any ideas how to do this? Maybe put whats in the application_start method into the constructor of my repository?</p>