title: Using Microsoft Graph to pull in calendar events via RESTful is slow at some times of the day
body: <p>I am using the Java Microsoft Graph API to pull in calendar events for a project.  I have to process a fairly large amount of calendar events (more than 50,000). </p>
  
  <p>I'm invoking it using the following construction:</p>
  
  <pre><code>String urlString = "https://graph.microsoft.com/v1.0/me/calendars/" + calendarId + "/events?$select=subject,organizer,attendees,start,end,location&amp;$filter=start/dateTime%20ge%20'" + trailingTwoYears + "'&amp;count=true&amp;$orderby=start/dateTime&amp;$skip=" + SKIP + "&amp;$top=50";
  </code></pre>
  
  <p>I have the following maven dependencies:</p>
  
  <pre><code>&lt;dependency&gt;
      &lt;groupId&gt;com.microsoft.azure&lt;/groupId&gt;
      &lt;artifactId&gt;adal4j&lt;/artifactId&gt;
      &lt;version&gt;1.6.0&lt;/version&gt;
  &lt;/dependency&gt;
  &lt;dependency&gt;
      &lt;groupId&gt;com.nimbusds&lt;/groupId&gt;
      &lt;artifactId&gt;oauth2-oidc-sdk&lt;/artifactId&gt;
      &lt;version&gt;5.24.1&lt;/version&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>Everything works great, except that I have noticed when I run it early in the morning, around 8AM Eastern Time,  it processes roughly 30 records/s. But by the afternoon, the speed of processing falls to about 5 records/s.  I have tried various values for the 'top' parameter, anything from 10 records per batch,  to 1000 records per batch,  it doesn't seem to affect the speed by much.  Not sure why it becomes so slow.  I may just need to schedule this cron job to run early in the morning to achieve fastest speed..</p>