-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
feat(wasm): add support for wasmtime cache #12930
Conversation
35d459c
to
945dec3
Compare
7a5c92c
to
4c9bf05
Compare
b431ca9
to
2f034f9
Compare
Is it possible to add a test for restarting kong with the cache enabled? Otherwise LGTM |
2f034f9
to
765baba
Compare
Yeah mainly i wanted to make sure nothing broke by introducing the cache, that things work with existing cache files on restart. Thanks! |
This adds support for Wasmtime's module caching. See also: * Kong/ngx_wasm_module#540 * https://github.com/Kong/ngx_wasm_module/blob/b19d405403ca6765c548e571010aea3af1accaea/docs/DIRECTIVES.md?plain=1#L136-L149 * https://docs.wasmtime.dev/cli-cache.html
765baba
to
296ccb5
Compare
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
Cherry-pick failed for Please cherry-pick the changes locally. git remote add upstream https://github.com/kong/kong-ee
git fetch upstream master
git worktree add -d .worktree/cherry-pick-12930-to-master-to-upstream upstream/master
cd .worktree/cherry-pick-12930-to-master-to-upstream
git checkout -b cherry-pick-12930-to-master-to-upstream
ancref=$(git merge-base 4052fbbfee77be52bcd5c876719a84bcbc8ba337 296ccb531a142cc5dafc428e24af60646de84372)
git cherry-pick -x $ancref..296ccb531a142cc5dafc428e24af60646de84372 |
Manually cherry-picked: https://github.com/Kong/kong-ee/pull/9389 |
* feat(wasm): add support for wasmtime cache This adds support for Wasmtime's module caching. See also: * Kong/ngx_wasm_module#540 * https://github.com/Kong/ngx_wasm_module/blob/b19d405403ca6765c548e571010aea3af1accaea/docs/DIRECTIVES.md?plain=1#L136-L149 * https://docs.wasmtime.dev/cli-cache.html * tests(wasm): add start/restart test for wasmtime cache
Loading .wasm module binaries involves a compilation step before they can be executed, which can slow Kong's startup time. This enable's Wasmtime's builtin cache, such that subsequent start/stop/restart cycles can be faster with a warm cache.
See also:
KAG-4372