usnationalarchives / OPAProd

Tracking enhancements to OPAProd
1 stars 0 forks source link

New API error message for rate limit #89

Open DominicBM opened 9 years ago

DominicBM commented 9 years ago

It took me forever to realize that the intermittent "500 Internal Server Errors" I was getting were due to hitting the rate limit, and not some load issue on the server side. This should probably have its own error message.

WaxCylinderRevival commented 9 years ago

I received 500s frequently yesterday -- as in, at a 5:1 ratio, if not greater. I had never hit that error before, and my same or similar calls are fine today. More specific error messages would be helpful, especially to start tracking clusters of issues.

DominicBM commented 9 years ago

You shouldn't hit the rate limits unless you do more than 60 requests in 600 seconds (i.e. 1 request every 10 seconds for 10 minutes). I'm curious if that was your actual issue, or if it was a performance issue on the catalog's part. All of the errors I can think of other than this one do have actual messages, so if you weren't hitting the rate limit, it's either a performance defect to report or something else we haven't thought of. It's worth investigating.

WaxCylinderRevival commented 9 years ago

I agree, I shouldn't have hit rate limits, but I have noticed performance issues with the API. Yesterday was the first day I received 500 notices and your post made me wonder.

The calls are smooth today, but I have had problems this last two weeks with simple live calls.

mereastew commented 9 years ago

There were definitely performance issues with the UI system the last two weeks. Denise has indicated that this has been fixed, so I'm wondering what the impact was on the API. She said it was a "routing" issue.