You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While channel type is cached and helps improve perf for Open and public channels, for private channels we still have to check if the user is a member of the channel or not - this occurs in a db.exists query. The problem will compound when we add organisations (#679) and have to check permissions for users.
Solution:
Cache the user's channel permission in Redis
If a channel member is deleted/changed - clear the cache
When checking permissions, read from cache, else fetch from DB and populate the cache (need a utility function for this)
The text was updated successfully, but these errors were encountered:
While channel type is cached and helps improve perf for Open and public channels, for private channels we still have to check if the user is a member of the channel or not - this occurs in a
db.exists
query. The problem will compound when we add organisations (#679) and have to check permissions for users.Solution:
The text was updated successfully, but these errors were encountered: