Validate all grappa calls - implementation & cache
We need support for queries of the type:
- Get all channels: Get all users groups + Get all channels that have
- Check user is member/subscribed:
-
Get all the user's groups + check groups overlap channel's groups + get user in channel's user list
- 1 query to auth to getuser/id/groups
- OR
Get all the channel's groups + get all the groups' users and check user is in resulting list + get user in channel's user list
- this option requires many calls to getgroup/id/members
-
- ...
First question to evaluate: Do we need to map all groups or performance can be achieved by using the user groups for all queries, instead of getting the group members. - Limits to 1 call to authz per user, which is cached for 5m
-
validate we're caching all grappa calls -
validate all grappa calls - implementation -
compare user groups with channel groups instead of getting groups members and checking if user is in list -
avoid more than one call per api (each call takes 2s if cache is missed)
-
Implement changes if necessary