Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve tracing for permissions checks #156

Merged
merged 5 commits into from
Aug 9, 2023

Conversation

jnschaeffer
Copy link
Contributor

This PR updates the logic we use for instantiating spans on permissions checks. In particular, I tried to establish a couple of conventions:

  • Allow and deny outcomes are communicated using span attributes instead of events so they can be searched more easily
  • Denials are not errors in general because a denial (actor can't act on a resource) is different from an error (SpiceDB is broken)

The PR also includes some quality of life improvements for the dev container.

This commit updates permissions checks to provide better spans for
surfacing allow/deny events. In particular, it tries to enforce the
following conventions:

* Allow and deny are explicitly conveyed using permissions.outcome
* Denials are not errors

These two conventions combined help us differentiate between allows,
denials, and problems communicating with SpiceDB.

Signed-off-by: John Schaeffer <[email protected]>
Signed-off-by: John Schaeffer <[email protected]>
@jnschaeffer jnschaeffer requested review from a team as code owners August 9, 2023 21:03
@jnschaeffer jnschaeffer merged commit bbd541c into infratographer:main Aug 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants