Límite de tasa global en Discourse

Hola,

Hemos actualizado Discourse a la versión 2.2.5.
Esto se refiere a las limitaciones sobre el número de publicaciones por usuario por día.

Nuestra configuración predeterminada es:
DISCOURSE_MAX_REQS_PER_IP_PER_MINUTE: número de solicitudes por IP por minuto (el valor predeterminado es 200)
DISCOURSE_MAX_REQS_PER_IP_PER_10_SECONDS: número de solicitudes por IP cada 10 segundos (el valor predeterminado es 50)

Nos gustaría aumentar a:
DISCOURSE_MAX_REQS_PER_IP_PER_MINUTE: 1000
DISCOURSE_MAX_REQS_PER_IP_PER_10_SECONDS: 500

¿Cree que esto tendrá algún impacto en el servidor de Discourse y en el rendimiento?
Algunos usuarios han comenzado a quejarse de que alcanzan el límite en el número de publicaciones enviadas.

Gracias

I do not think this is the rate limit being discussed. Provide screenshots of the limiter being hit please or get more details.

It sounds like your users are running into first day user post count limits is my guess.

User gets error like:

01:09:42 {"errors":["You’ve performed this action too many times. Please wait 19 seconds before trying again."],"error_type":"rate_limit","extras":{"wait_seconds":19}}

That is indeed the Nginx per-IP rate limits, are you sure you are not behind a reverse proxy which is incorrectly sending all client IP addresses as the same IP address?

Is it always the same users? Are they trying to use the API?

If it’s not and they aren’t then check the profiles of some affected users, do their IPs look accurate? Are they all the same or similar? If so it’s either a misconfigured reverse proxy or something like Cloudflare being used with the orange cloud enabled without the template specified in the YML.

Yes they are using the same user, to generate a lot of posts per minute (via user API key).
But they now complain they are limited in terms of number of posts allowed for that user.

Do you think it could help if I increase:
DISCOURSE_MAX_REQS_PER_IP_PER_MINUTE : 1000
DISCOURSE_MAX_REQS_PER_IP_PER_10_SECONDS : 500

1 me gusta

Tuve el mismo problema. Quería usar la API, pero cometió este error:


Quisiera poder establecer la tasa de una API específica para el administrador.
No sé cómo modificar la tasa global.
Agradecería mucho que me indicaran dónde se encuentra.
Soy de China, así que mi inglés no es bueno, muy disculpa.

solo tenemos un límite de tasa de API general, sin capacidad para personalizar el límite por ruta.

Los límites que buscas están en la configuración del sitio:

  • límite de velocidad para crear un tema
  • límite de velocidad para crear una publicación
  • límite de velocidad para que un nuevo usuario cree un tema
  • límite de velocidad para que un nuevo usuario cree una publicación

Ve a https://discourse.example.com/admin/site_settings/category/rate_limits?filter=create para modificarlos.

2 Me gusta