シッコク
03/23/2025, 2:08 PMgroup
of `user`s, which contain `superUser`s coming from two sources: developers and externalSuperUser
I have want to set different logics when displaying the user list under a group. That is, only superusers can see one another.
my schema.spicedb
is defined as following:
definiton group {
relation member: user
relation superUser: developerGroup:* | externalSuperUserGroup
}
definition developerGroup {
relation member: user
}
definition externalSuperUserGroup {
relation member: user
}
here's the main problem, after I got the original user list of a specific group
, how can I filter out those who are belong to superUser
relationship?
I tried using LookupSubjects with param resourceObjectType='group', subjectType='user', relation='superuser'
to find those who is superUser, but I got nothing from the query result.
I think it's because the LookupSubjects can only query direct relationships. But I can't changes the structure of the schema here.
Is there any way to find such indirect relationship? (find the user
in developerGroup
as a superUser
in the group
)