-
Notifications
You must be signed in to change notification settings - Fork 616
Add AuthCtx to ReducerContext for rust #3288
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
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like there were also stuff from my previous review that was not addressed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have some improvements atop of this PR, primarily wrt. docs, but this looks good to merge.
Description of Changes
This exposes client credentials in reducer calls for rust.
API and ABI breaking changes
API Changes:
The main API change is the addition of
AuthCtx
and thesender_auth
inReducerContext
.ABI Changes:
This adds two new functions
jwt_len
andget_jwt
. These usest_connection_credentials
to look up the credentials associated with a connection id.jwt_len
can be used to figure out the size of the payload, so thatget_jwt
can provide a large enough buffer.TODO: I assume I need to bump the ABI version in this PR.
Expected complexity level and risk
Testing
I've done some manual testing with modified versions of the quickstart. We should add some examples that use the new API.