Open 24mu13 opened 4 years ago
Dont @ me, talk to telegram.
If you look at the linked issue, they say this should be handled by the consumer app.
I rethought about it, and yes my bad for not clicking link. Telegram desktop sends sound for every new message, but maybe i could do some rate limiting
Between, you don't need Redis for this. TDLib has the method setChatClientData
and the field chat.client_data
to store application-specific chat settings exactly like this one.
Using Redis just to limit simple for loop would be bigest overkill in history, same with client data
I have some (annoying) friend sending multiple/separate messages in sequence, like the following:
In this case I will receive THREE notifications (sound), disturbing and useless. Not to mention the same scenario in a chat-group, where everybody is texting at the same time! Nightmare.
In all these scenarios, I would like to receive a single notification when additional message is coming for same contact/group within a configurable time-slice (when zero means this feature is off).
An idea is to use a kind for Redis local cache where key is sender/group-id, and each key-value has an expiration depending of above setting.
https://github.com/tdlib/td/issues/930