Skip to content
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

add stubs for redirect_to_ hostcalls #187

Merged
merged 1 commit into from
Oct 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions lib/compute-at-edge-abi/compute-at-edge.witx
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,16 @@
(result $err (expected (error $fastly_status)))
)

(@interface func (export "redirect_to_websocket_proxy")
(param $backend_name string)
(result $err (expected (error $fastly_status)))
)

(@interface func (export "redirect_to_grip_proxy")
(param $backend_name string)
(result $err (expected (error $fastly_status)))
)

;;; Adjust how this requests's framing headers are determined.
(@interface func (export "framing_headers_mode_set")
(param $h $request_handle)
Expand Down
10 changes: 10 additions & 0 deletions lib/src/wiggle_abi/req_impl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,16 @@ impl FastlyHttpReq for Session {
Err(Error::NotAvailable("WebSocket upgrade"))
}

#[allow(unused_variables)] // FIXME ACF 2022-10-03: Remove this directive once implemented.
fn redirect_to_websocket_proxy(&mut self, backend_name: &GuestPtr<str>) -> Result<(), Error> {
Err(Error::NotAvailable("Redirect to WebSocket proxy"))
}

#[allow(unused_variables)] // FIXME ACF 2022-10-03: Remove this directive once implemented.
fn redirect_to_grip_proxy(&mut self, backend_name: &GuestPtr<str>) -> Result<(), Error> {
Err(Error::NotAvailable("Redirect to Fanout/GRIP proxy"))
}

#[allow(unused_variables)] // FIXME KTM 2020-06-25: Remove this directive once implemented.
fn downstream_tls_protocol<'a>(
&mut self,
Expand Down