Skip to content

wasi-http and error handling improvements#2949

Merged
vigoo merged 14 commits intomainfrom
wasmtime-http-improvements
Mar 11, 2026
Merged

wasi-http and error handling improvements#2949
vigoo merged 14 commits intomainfrom
wasmtime-http-improvements

Conversation

@vigoo
Copy link
Contributor

@vigoo vigoo commented Mar 9, 2026

wasmtime side: golemcloud/wasmtime#5

Resolves #2068

#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct HttpClientConfig {
/// Whether to use a shared HTTP connection pool for outgoing requests.
pub pool_enabled: bool,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we make it an enum instead to be consistent with our other configs

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes good point

@vigoo
Copy link
Contributor Author

vigoo commented Mar 10, 2026

The divergence issue with wasi-http that we experienced earlier was reproducible with the connection pool changes more easily. The fix is included. The problem was that request-body output stream operations were not persisted, so in case writing to the output failed (for example because a race cancelled the request, or any remote error happens) this error was not persisted and during replay caused a divergence:

image

@vigoo vigoo enabled auto-merge (squash) March 10, 2026 11:32
@vigoo vigoo merged commit 74aedf7 into main Mar 11, 2026
27 checks passed
@vigoo vigoo deleted the wasmtime-http-improvements branch March 11, 2026 14:42
@github-actions github-actions bot locked and limited conversation to collaborators Mar 11, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve Host HTTP implementation

2 participants