-
Notifications
You must be signed in to change notification settings - Fork 17
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 introspection cache #567
Conversation
Very nice, however: since this will result in a breaking change, I need some kind of description, how users of #550 can work around the removed role feature. |
@buehler where would you prefer to have such documentation? it is basically a standard extension trait
|
It would be nice to have this in the docs of ZitadelExtraTokenFields struct. There were you removed the role generic. As such, I can also include them as the migration path for the breaking change. |
…ble with caches Using a role generic was incompatible with the type erasure of the introspection cache. Judging from the discussion in smartive#550 the original intention was to introduce a convenience feature, for library users. However, the same behaviour can be easily achieved by a simple extention trait, and does not need to be support by this crate itself to achieve the same convenience. As a result, the generic role type parameter is removed.
* don't lock on every request * use a ttl expiry for better token security
b9a7879
to
664fc32
Compare
@buehler I added the example both for the |
Main goals of this PR:
To achieve this I had to remove the Role generic type parameter introduced in #550 , as this was incompatible with the type erasure for the IntrospectionCache trait types.
But there are simple ways to achieve the same convenience on library user side.