title: SQL server service broker usage with ASP.net cache?
body: <p>I have  ASP.net site (4.5) which uses sql cache notification. (using  <em><code>aspnet_regsql.exe</code></em>)</p>
  
  <p>The idea is that SQL server tables are stored in the app's cache .This is for - <em>not</em> to load data over and over again from the specific table.</p>
  
  <p>The beauty is that Asp.net's <code>cache</code> can automatically remove the table from the <code>cache</code> (<em>and load it again - optionally</em>) when data is modified on that table.</p>
  
  <p>It is done via web.config  : </p>
  
  <pre><code> &lt;system.web&gt;
        &lt;caching&gt;
           &lt;sqlCacheDependency enabled="true"&gt;
              &lt;databases&gt;
                 &lt;add name="Northwind" connectionStringName="AppConnectionString1" 
                  pollTime="500" /&gt;
              &lt;/databases&gt;
           &lt;/sqlCacheDependency&gt;
        &lt;/caching&gt;
   &lt;/system.web&gt;
  </code></pre>
  
  <p>But the way it works is by <em>polling</em> the main sql cache Notification table (<em>which basically holds table names and counters</em>)</p>
  
  <p><strong>Question:</strong></p>
  
  <p>I know that service broker can be used instead . But how does the mechanism is different as opposed to polling?
  I mean - when a table is changed - there is a trigger which updates the main table but how ASP.net knows that a counter (<em>which represent a change</em>) has been increased ? does ASP.net still polls ?</p>