title: EWS - ServerBusyException?
body: <p>After our company upgraded from Exchange 2010 to Exchange 2013, I found a really strange quirk. I'm using the EWS managed API to create a streaming subscription to some public folders. I have some older windows services still running that are happily subscribed, reading new mail, and stuff like that. I have my new project that will eventually replace these old windows services, and while we were on Exchange 2010 it could create the same streaming subscriptions to the same public folders while the legacy windows services were still running. Post upgrade, I am now getting a ServerBusyException when I try to open the StreamingSubscriptionConnection. If I disable all the legacy windows services, I can open the connection fine in my new project. </p>
  
  <p>Here is how I'm subscribing, nothing too fancy:</p>
  
  <pre><code>    private StreamingSubscriptionConnection CreateStreamingSubscription(ExchangeService service, StreamingSubscription subscription)
      {
          var connection = new StreamingSubscriptionConnection(service, 30);
          connection.AddSubscription(subscription);
          connection.OnNotificationEvent += connection_OnNotificationEvent;
          connection.OnSubscriptionError += connection_OnSubscriptionError;
          connection.OnDisconnect += connection_OnDisconnect;
  
          try
          {
              connection.Open(); // &lt;-- boom!
          }
          catch (ServerBusyException ex)
          {
              Log.Error("Connection to Exchange refused. Server is too busy.", ex);
              throw; // &lt;-- this is the exception, it is specific
          }
          catch (Exception ex)
          {
              Log.Error("Unknown error connection to Exchange.", ex);
              throw;
          }
  
  
          return connection;
      }
  </code></pre>
  
  <p>After looking that MSDN, there is a property called BackOffMilliseconds, but it is coming back as 0 indicating that Exchange isn't actually telling me to try again later. I logged into the Exchange server to check throttling policies, and the default global policy is applied. Every parameter that has the word 'concurrency' in it is over 10, so I don't think it is a throttling policy issue. For what it's worth, my legacy windows services and this new project are all using the same service account to do their thing. </p>
  
  <p>I also looked at how the service connection is made, and there is no change whether it is set to Exchange2013 or Exchange2010_SP1:</p>
  
  <pre><code>    private ExchangeService CreateExchangeService()
      {
          ServicePointManager.ServerCertificateValidationCallback = CertificateValidationCallBack;
          var service = new ExchangeService(ExchangeVersion.Exchange2013);
          service.Credentials = new WebCredentials(ExchangeUser, ExchangePassword, ExchangeDomain);
          service.AutodiscoverUrl(ExchangeEmail, RedirectionUrlValidationCallback);
          return service;
      }
  </code></pre>
  
  <p>Last I checked Fiddler to see what was happening during these failed subscriptions, and I'm seeing an unhelpful HTTP 500 with the same server busy, try later message.</p>
  
  <p>Any ideas on what changed in the EWS API in Exchange 2013 vs 2010SP2?</p>