title: Azure SQL serverless is not waking up on connection attempt
body: <p>I'm testing Azure SQL Serverless and from SSMS it seems to work fine, but from my ASP.NET Core application it never wakes up.</p>
  
  <p>Using SSMS I can open a connection to a sleeping Serverless SQL database and after a delay the connection will go through.</p>
  
  <p>Using my ASP.NET Core application I tried the same. From the login page I tried to login, which opens a connection to the database. After 10 or 11 seconds (I looked up the default timeout and its supposed to be 15 seconds but in this case it always seems to be about 10.5 seconds +/-0.5s). According to the docs, the first connection attempt may fail but subsequent ones should succeed, but I can send multiple queries to the database and it always fails with the following error:</p>
  
  <pre><code>Microsoft.Data.SqlClient.SqlException (0x80131904): Database 'myDb' on server 
  'MyDbSvr.database.windows.net' is not currently available.  Please retry the connection later.  If the 
  problem persists, contact customer support, and provide them the session tracing ID of 
  '{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}'.
  </code></pre>
  
  <p>If I wake the database up using SSMS then the login web page can connect to the database and succeeds.</p>
  
  <p>I have added <code>Connect Timeout=120;</code> to the connection string.</p>
  
  <p>The connection does happen during an HTTP request that is marked async on the Controller, thought I don't know if that makes any difference.</p>
  
  <p>Am I doing something wrong or is there something additional I need to do to get the DB to wake?</p>
  
  <p>[updte]
  as an extra test wrote the following test </p>
  
  <pre><code>void Main()
  {
      SqlConnection con = new SqlConnection("Server=mydbsvr.database.windows.net;Database=mydb;User Id=abc;Password=xyz;Connect Timeout=120;");
  
      Console.WriteLine(con.ConnectionTimeout);
  
      con.Open();
  
      var cmd = con.CreateCommand();
      cmd.CommandText = "select getdate();";
      Console.WriteLine(cmd.ExecuteScalar());
  }
  </code></pre>
  
  <p>and got the same error.</p>