title: L2SQL Async or not?
body: <p>i'm really having a hard time deciding how to build my sql layer. i'm building a webservice that will communicate with both sql and No-SQL servers. So i came up with a bunch of ideas so that we can implemented testing, etc. etc. </p>
  
  <p>Now i have bunch of files and a structure, i explain (Sorry i've i used names of patrons that i don't use... please correct me in that case): 
  -IDatabaseStore.cs
  -SqlDatabaseStore.cs
  -NoSQLDatabaseStore.cs
  -and all my specific stores(like userStore.cs that implements the sql store for example). </p>
  
  <p>And i wanted to do the following: 
  Both SQL- and NoSQLDatabaseStore will implement the IDatabaseStore. These 2 classes will be abstract to provide the basic functionalities like the Repository pattern does. And all specific store will implement one of both abstract classes to not rebuild everything. </p>
  
  <p>Now the problem: The No-SQL library that i use is MyCouch and is completly async, but for SQL i use L2SQL which isn't async. </p>
  
  <p>Now my question: how is it preferred to set this up, in your opinion?</p>
  
  <ol>
  <li><p>Like example 1, forcing that both use async methods, also if they aren't async(like L2SQL).</p></li>
  <li><p>Make the interface like example 2, all dynamic an pass the generic type as Task in case that it needs to be Async. This way i don't obligate my interface nor abstract classes to be async (But void methods aren't async ever that case?).</p></li>
  <li><p>Did i missed a way to make L2SQL async? Notice: I've seen a lot of posts already, but they don't seem to fit in this model.</p></li>
  <li><p>Any other suggestions? </p></li>
  </ol>
  
  <p>In case of performance i really would love tho have an Async L2SQL, because i will need to manage a lot of connections and this could really benifit the webservice. But for example a solution like: <a href="https://stackoverflow.com/a/252426/1364241">https://stackoverflow.com/a/252426/1364241</a> isn't awaitable, no?</p>
  
  <p>Example 1:</p>
  
  <pre><code>public interface IDatabaseStore {
     Task&lt;T&gt; GetByID(string id);
     Task&lt;List&lt;T&gt;&gt; GetAll();
     Task Delete(T model);
     Task Update(T model);
     Task Insert(T model);
  }
  </code></pre>
  
  <p>Example 2:</p>
  
  <pre><code>public interface IDatabaseStore {
      T GetByID(string id);
      List&lt;T&gt; GetAll();
      void Delete(T model);
      void Update(T model);
      void Insert(T model);
  }
  </code></pre>