Currently it's somewhat difficult to reason about the performance of a particular permission definition during schema development.
Solution Brainstorm
While we cannot know the distribution of data in the system until we're working against a live SpiceDB deployment, we can detect the level of nesting and use of costly operators (intersection, negation) to come up with a score and throw a warning when a definition is over a particular score.
This will probably be somewhere downstream of the composable schema proposal. We'll need a reachability graph at compile time, which I don't think we currently have.
Problem Statement
Currently it's somewhat difficult to reason about the performance of a particular permission definition during schema development.
Solution Brainstorm
While we cannot know the distribution of data in the system until we're working against a live SpiceDB deployment, we can detect the level of nesting and use of costly operators (intersection, negation) to come up with a score and throw a warning when a definition is over a particular score.