alexcrichton opened PR #8861 from alexcrichton:doc-wasi-using-bindings-module
to bytecodealliance:main
:
This commit primarily adds a complete example of using
wasmtime-wasi-http
to the documentation. Along the way I've done a
number of other refactorings too:
bindgen!
-generated*Pre
structures now implementClone
.bindgen!
-generated*Pre
structures now have anengine
method.bindgen!
-generated*Pre
structures now have aninstance_pre
method.The structure of
wasmtime-wasi-http
now matcheswasmtime-wasi
,
notably:
- The
proxy
module is removed
wasmtime_wasi_http::add_to_linker_{a,}sync
is the top level
add-to-linker function.The
bindings
module now containsProxy
andProxyPre
along with
async
submodule.The
bindings
module contains all bindings forwasi:http
things.- The
add_only_*
methods are un-hidden and documented.- Code processing
req
has been simplified by avoiding
decomposing-and-reconstructing a request.The
new_incoming_request
method is now generic to avoid callers
having to do boxing/mapping themselves.I initially wanted to do more refactoring and documenting but I ran out of steam after this so this is where I'm going to leave it for now.
alexcrichton requested wasmtime-core-reviewers for a review on PR #8861.
alexcrichton requested pchickey for a review on PR #8861.
alexcrichton edited PR #8861:
This commit primarily adds a complete example of using
wasmtime-wasi-http
to the documentation. Along the way I've done a
number of other refactorings too:
bindgen!
-generated*Pre
structures now implementClone
.bindgen!
-generated*Pre
structures now have anengine
method.bindgen!
-generated*Pre
structures now have aninstance_pre
method.The structure of
wasmtime-wasi-http
now matcheswasmtime-wasi
,
notably:
- The
proxy
module is removed
wasmtime_wasi_http::add_to_linker_{a,}sync
is the top level
add-to-linker function.The
bindings
module now containsProxy
andProxyPre
along with
async
submodule.The
bindings
module contains all bindings forwasi:http
things.- The
add_only_*
methods are un-hidden and documented.- Code processing
req
has been simplified by avoiding
decomposing-and-reconstructing a request.The
new_incoming_request
method is now generic to avoid callers
having to do boxing/mapping themselves.I initially wanted to do more refactoring and documenting but I ran out of steam after this so this is where I'm going to leave it for now.
Closes #8860 8832
alexcrichton edited PR #8861:
This commit primarily adds a complete example of using
wasmtime-wasi-http
to the documentation. Along the way I've done a
number of other refactorings too:
bindgen!
-generated*Pre
structures now implementClone
.bindgen!
-generated*Pre
structures now have anengine
method.bindgen!
-generated*Pre
structures now have aninstance_pre
method.The structure of
wasmtime-wasi-http
now matcheswasmtime-wasi
,
notably:
- The
proxy
module is removed
wasmtime_wasi_http::add_to_linker_{a,}sync
is the top level
add-to-linker function.The
bindings
module now containsProxy
andProxyPre
along with
async
submodule.The
bindings
module contains all bindings forwasi:http
things.- The
add_only_*
methods are un-hidden and documented.- Code processing
req
has been simplified by avoiding
decomposing-and-reconstructing a request.The
new_incoming_request
method is now generic to avoid callers
having to do boxing/mapping themselves.I initially wanted to do more refactoring and documenting but I ran out of steam after this so this is where I'm going to leave it for now.
Closes #8832
pchickey submitted PR review:
Thanks, the docs improvements here are really great!
alexcrichton updated PR #8861.
alexcrichton has enabled auto merge for PR #8861.
alexcrichton updated PR #8861.
alexcrichton has enabled auto merge for PR #8861.
alexcrichton merged PR #8861.
Last updated: Nov 22 2024 at 17:03 UTC