-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Support clear api key cache #5147
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.
We need to send an PR to elastic/elasticsearch to update the source spec
To include the path with no ids
.
We can use a patch file in our codebase to unblock us on this PR.
Excellent catch @stevejgordon 🔍 👍 |
@Mpdreamz I think I've patched this correctly and now per the updated tests, we can support optional IDs. |
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.
LGTM, don't forget to send an upstream PR for this :)
src/ApiGenerator/RestSpecification/_Patches/security.clear_api_key_cache.patch.json
Show resolved
Hide resolved
* Support clear API key cache * Patched to support optional ids
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-master master
# Navigate to the new working tree
cd .worktrees/backport-master
# Create a new branch
git switch --create backport-5147-to-master
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick ---mainline 1 e607d3126d05ec862c4d2a9de37bfcaecc05a249
# Push it to GitHub
git push --set-upstream origin backport-5147-to-master
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-master Then, create a pull request where the |
* Support clear API key cache * Patched to support optional ids
* Support clear API key cache * Patched to support optional ids Co-authored-by: Steve Gordon <[email protected]>
* Support clear API key cache (#5147) * Support clear API key cache * Patched to support optional ids
I updated
UrlPart
to support the use of theIds
type which seemed appropriate.One query for review... The docs for this API suggest that the ids in the path can be empty to clear cache for all keys. The generated code requires the presence of an ID part and I'm not sure if this is okay or how best to address it?
Contributes to #5096