Replies: 1 comment
-
@rhamzeh how hard would it be to support arbitrary metadata? We could benefit from it too, so we could extend the DSL without having to explicitly define additional metadata fields. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm wondering if any thought has been given to extending the protobuf definition for the authzmodel (https://github.com/openfga/api/blob/main/openfga/v1/authzmodel.proto) to support custom metadata values - for example, to stash a description or display name of a type or relation definition?
The primary use case would be the ability for UIs to parse the model and provide 'display-ready' labels for types and relations. Additionally, we sometimes think of relations having different 'subtypes' (i.e. role relations, permission relations, organizational relations, structural relations, etc.) - custom metadata on relations would allow us assign informal 'types' to our relations to be consumed by adopters of the model and/or UIs for display.
We could store that metadata in a layer/database external to OpenFGA, but it seems like a relatively small extension of the authzmodel proto could allow for that information to be stored in the desired system of record for authz models (OpenFGA).
I suppose displaying type/relation metadata in the DSL version of the model could be difficult, so I was thinking it would only be supported in the JSON version of the model.
Beta Was this translation helpful? Give feedback.
All reactions