Why do I get Gateway Timeout whenever my MS Graph API mail search finds no results?

荒凉一梦 提交于 2019-12-04 03:30:14

问题


As of this week I am suddenly getting gateway timeout from Graph when my mail search finds no results.

I am using a query like this one:

https://graph.microsoft.com/v1.0/users/shared@notreal.com/mailFolders/AllItems/messages?$search="participants:some.person@fake.com"&$select=from,subject,HasAttachments,Id,SentDateTime&$top=100

This is a Graph query which requests up to 100 emails from the Office 365 mailbox of shared@notreal.com where the sender or receiver includes some.person@fake.com. shared@notreal.com is a mailbox that is shared with the account making the call.

My app is authenticated with the oauth2 authentication code flow and has been granted all necessary permissions.

This has been working for about a year. But starting a few days ago, this query only succeeds if results are found. When no results are found, the query takes 30 seconds, Graph returns UnknownError and the response is 504 with reasonphrase Gateway Timeout.

It seems as though something has changed in the Graph API - or perhaps in the Office 365 API, but I can't find any mention of it anywhere.

Microsoft specifically directs questions about the Graph API to stackoverflow, so here I am. I hope the right people are reading.

Why has this suddenly started happening and how can I fix it?

Update: there are now numerous reports of this issue, confirming that it's at Microsoft's end.

Github issue


回答1:


We saw this question and were actively investigating this kast week. With July 4th long weekend I hadn't got back to this thread until now.

This issue has been resolved on the back end of the service and you should not be seeing this issue anymore.

Thank you so much for sharing the service issue here.




回答2:


This issue seems to be resolved on our end now.



来源:https://stackoverflow.com/questions/56880644/why-do-i-get-gateway-timeout-whenever-my-ms-graph-api-mail-search-finds-no-resul

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!