-
Notifications
You must be signed in to change notification settings - Fork 900
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
Ensure callable functions have invoker correctly set to "public" #4335
Ensure callable functions have invoker correctly set to "public" #4335
Conversation
…allable-function-public
…tion invoker is set correctly
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). For more information, open the CLA check for this pull request. |
@taeold - you mentioned in your previous comment that the invoker is not updated on update, however the source code/tests for the update methods look as if they would update the invoker if set (and subsequently not update the invoker for callable functions unless additional logic was added). Are you saying we don't need to handle this case, as users can't specify an |
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.
Are you saying we don't need to handle this case, as users can't specify an invoker for callable functions, meaning this scenario of changing the invoker on update will never happen?
Yes. User may have changed invoker for good reasons. I think we should respect that.
Also - can we add an entry to CHANGELOG.md file?
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.
🔥 Amazing contribution!
Implemented fix for issue introduced in `v10.3.0` where callable functions were not having their `invoker` property correctly set to `"public"` that would in turn cause access issues with the deployed functions (as detailed in #4327). Will also fix issues such as #3965, that are presumably cause by version mismatches/upgrades introducing this issue. Fixes issue by adding specific handling for callable functions and always setting the `invoker` to `"public"`. Also fixed issue with `taskQueueTrigger` endpoints calling wrong method/passing wrong args when trying to set invoker.
Description
Implemented fix for issue introduced in
v10.3.0
where callable functions were not having theirinvoker
property correctly set to"public"
that would in turn cause access issues with the deployed functions (as detailed in #4327).Will also fix issues such as #3965, that are presumably cause by version mismatches/upgrades introducing this issue.
See comment for explicit info.
Fixes issue by adding specific handling for callable functions and always setting the
invoker
to"public"
.Also fixed issue with
taskQueueTrigger
endpoints calling wrong method/passing wrong args when trying to set invoker.Scenarios Tested
Thanks to @taeold we have explicit tests for each function type and the expected outcomes for both
createV1Function
andcreateV2Function
methods.Sample Commands