sourcegraph/lib/managedservicesplatform/iam
Robert Lin f5afeb8c22
feat/enterpriseportal: make UpdateEnterpriseSubscriptionMembership authoritative (#63502)
Closes https://linear.app/sourcegraph/issue/CORE-199. AIP generally
implies `Update` RPCs are authoritative, which means that we should be
deleting all roles memberships not provided to
`UpdateEnterpriseSubscriptionMembership`. Most important outcome here is
that we can actually remove roles from users by assigning them an empty
role set `[]`

Later we can add a "get roles" RPC to safely make these updates, and
introduce a purely additive RPC if needed. It's not a huge deal right
now because we only have 1 role ("customer admin")

Also removes the deprecated value from
https://github.com/sourcegraph/sourcegraph/pull/63501.

## Test plan

Unit tests, expanded with better table-driven cases and expanded
assertions
2024-06-27 12:52:46 -07:00
..
BUILD.bazel enterprise-portal: implement basic MSP IAM and RPCs (#63173) 2024-06-19 21:46:48 -04:00
client.go feat/enterpriseportal: make UpdateEnterpriseSubscriptionMembership authoritative (#63502) 2024-06-27 12:52:46 -07:00
database.go chore/enterpriseportal: propagate context to migration database context (#63455) 2024-06-25 01:18:15 +00:00
iam.go enterprise-portal: implement basic MSP IAM and RPCs (#63173) 2024-06-19 21:46:48 -04:00
openfga_server.go enterprise-portal: implement basic MSP IAM and RPCs (#63173) 2024-06-19 21:46:48 -04:00