Hi! Let's say I have a schema that has users, role...
# spicedb
t
Hi! Let's say I have a schema that has users, roles and orgs. users can be member of roles, and roles can have different kind of relations on orgs. For example
Copy code
role:hr#member@user:joe
org:microsoft#manage_settings@role:hr#member
What would be the best way to get all permissions Joe has, considering that a role may have multiple permissions on an org, and a user may be member of multiple roles? I understand that readRelationships is discouraged, correct? Should I issue a bulkCheck on every single permission against every single org? Or is it better to use lookUpResources to get all roles joe is a member of, and then for each role, make a bulkCheck with all possible permissions? Or maybe some other way?
3 Views