429 Too Many Requests errors on admin dashboard

After updating to: v2.1.0.beta5 +21

Seems related to this commit:

image

1 to 3 widgets on /admin display that error.

3 Likes

Yes this is from this commit. The NGINX I tried on is not returning html but a simple sentence as text, I guess it can be different in some cases. This should prevent it:

Thanks.

4 Likes

Thanks!
But how can I prevent this?

image

I’m the only visitor of my site now, and I always got this error on some widgets.

Is this a self installation ?

I see you are familiar with discourse_docker/web.ratelimited.template.yml at master · discourse/discourse_docker · GitHub

Did you tweak some variables too low in this template ?

Yes.
Installed this last month.

That config is just default.

I’m getting this too, self install, ‘default’ config (aside from usual domain specific settings, eg domain, email etc.)

Yes this is tricky. This is a trade-off between making a lot of requests, or a BIG ONE which might take too much time to complete, and fail in a different way.

I will try to come up with a way to group some requests without taking too much risk. Probably won’t be fixed by 1 or 2 days.

4 Likes

btw, interesting behaviour - I get it for two panes in Chrome, but only one in Firefox … I guess that might be down to when the page elements were cached and luck?

It seems to be happening mostly “randomly”. It depends on the current load of your site + the rate the actual requests happen from your browser.

For the record it also happens on our website.

1 Like

Seems like a lot of users are affected with this! I too noticed today that I have a warning! Surprising enough, it was my first visit of the day to admin area.

We have a plan to address this, hold tight

5 Likes

Yes I have something working but will spend most of the day refining it. Expect a release monday. In the mean time if you experience this you can always go to see each report separately on the dedicated page.

4 Likes

I don’t have an urge to watch the stats for a relatively small forum. It’s more like a heads up that something is actually not working!

I’ll wait for the fix :wink:

Seems already fixed by this commit: FEATURE: makes reports loadable in bulk (#6309) · discourse/discourse@82dcc5c · GitHub

Thanks a lot!

1 Like

Ahaha yes… I wanted to keep it secret until Monday as it’s kind of tricky and wanted more time to be sure it was working correctly. But I guess if it’s working for you that’s already a good thing :+1:

7 Likes

I am also facing this problem since last update.

So a few words on this. If you have this issue you should definitely upgrade, I will improve it more but it’s already working quite well.

Reports are now using a singleton report loader which will handle the loading of all the reports on a page transparently. For plugin authors there’s nothing specific to do as long as you use the {{admin-report}} component.

If you use plugins which add reports to the dashboard, you can do it safely and be sure they won’t use all your resources (DB, Unicorns…), won’t trigger rate limiting if you have too many of them or crash the whole dashboard.

Happy to hear feedback on this.

5 Likes