sharepointmicrosoft-graph-apiserverxmlhttp

Intermittent connection drops using MS Graph API for Sharepoint


Since 06.02.2020 our interface with a clients Sharepoint (using MSGraph API) has been experiencing intermittent connection drops when trying to download a file using @microsoft.graph.downloadUrl.

Our application makes a HTTP GET request (using MSXML2.ServerXMLHTTP.6.0) to the provided url. Then after a certain amount of time an error gets thrown with the description "The connection with the server was terminated abnormally". No status code, no response content.

This also occurs using any browser (by copying the downloadUrl to the address bar and hitting enter). Chrome, with a file download (lets say the url points to a .jpg file), will say "Failed - Network error".

The error can be replicated (IF it is a global problem) using Curl with this batch script.

@echo off

FOR /L %%A IN (1,1,%1) DO (
    echo.
    echo Attempt: %%A%

    rem Writing output into a file, extension is not really important.
    curl --output "output.jpg" %2
)

Which can be called like test.bat <no of tries> "<@microsoft.graph.downloadUrl>". Added a log here, attempts 13, 15 and 18 get the error.

I'm not really sure what could be happening here. I've researched the error message and basically what happens is that the socket gets just dropped unexpectedly. I was thinking maybe there's a quota we are hitting with our requests, but in these cases MSGraph returns a proper error message and there is no background application bombarding MSGraph using these links. The links are used to show a pdf preview in the browser window for example.

Any ideas what could be wrong or where I could go for help?


Solution

  • We believe we tracked down the root cause of this issue - can all of those who were observing it let us know if things look better?