Closed LiranCohen closed 2 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 98.55%. Comparing base (
0311b9e
) to head (c47f3d1
).
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Modifies
RecordsPermissionScope
to require scoping to a specific protocol. This also removes the ability to scope to a schema as you would just scope to a protocolPath instead.The motivation behind this was to make querying for all Messages tied to a specific protocol for subset sync. Without this change getting grants, and more importantly the grant revocations which have unrestricted scopes would be challenging/not performant.
Since we are planning on getting rid of flat-spaced records anyway, this is a step in the right direction.
schema
fromRecordsPermissionScope
RecordsPermissionScope
requiresprotocol
to be setprotocol
provided within theRecordsPermissionScope
is also added as aprotocol
tag to theRecordsWriteMessage
descriptor.RecordsWriteMessage
, ensure theprotocol
tag on the record is the same as the scopeprotocol
defined in theRecordsPermissionScope
.grant
is covered by this PR.request
andrevoke
will come in subsequent PRs