Invite emails rate limited


The “Send Email Invite” from within a team isn´t working if you use to many recipients.

Steps to reproduce

Host OS: CentOS 7
Mattermost Version: Team Edition 5.10.0
DB: mysql
Send >20 team invitations through the “Send Email Invite” dialogue.

Expected behavior

I would except that the invitations are sent to the mail addresses.

Observed behavior

The limit is presumably at >20. 20 invitations work, 25 for example don´t work.
You get no error message in the sent invitation window, also no hint that it doesn´t work. In the logs you see the following message:
{"level":"error","ts":1559635541.0647378,"caller":"mlog/log.go:172","msg":"Invite emails rate limited.","user_id":"***","team_id":"***","retry_after":"-1ns"}
The Rate Limit Settings are disabled (copied from config.json):

"RateLimitSettings": {
        "Enable": false,
        "PerSec": 10,
        "MaxBurst": 100,
        "MemoryStoreSize": 10000,
        "VaryByRemoteAddr": true,
        "VaryByUser": false,
        "VaryByHeader": ""

I couldn´t find any other rate limiting settings.
Does anyone else have this problem? Is it possible to change this rate limit?

Hi @bjwe, I’ve asked our team about this and just waiting on their reply,

Hi @bjwe, RateLimitSettings does not configure email rate limits. It’s currently not possible to configure that rate limiter.

Hi @amy.blais, thank you for your quick reply.

Hi, everyone.

For reference purposes, I went ahead and created this bug report:

Feel free to share and add more comments related to the issue in the official ticket. Thanks.