Feature Request: WASI 0.2 / Socket Support for WASM Input Plugins
- Dominant language
- C
- Stars
- 8.1k
- Forks
- 2k
- Avg merge
- 4d 16h
- Merged PRs (30d)
- 58
Description
Hi Fluent Bit team,
I'm working on a custom WASM input plugin for Fluent Bit, and I'd like to use it to **fetch logs from an HTTP API endpoint** (e.g., scrape metrics, ingest structured JSON from a service).
### Background
From the current documentation:
- Fluent Bit supports **Wasm input plugins** via the `exec_wasi` input.
- It mentions Rust `wasm32-unknown-unknown` as a toolchain, but also clearly states that **WASM input assumes the WASI ABI**, which aligns with `wasm32-wasi`.
- However, **WASI 0.1**, used by `wasm32-wasi`, does **not support sockets or networking**, which prevents plugins from fetching from HTTP endpoints.
### Context
In Rust:
- `wasm32-wasi` (WASI 0.1) does not support networking (no `std::net`, `reqwest`, etc.)
- `wasm32-wasip2` (WASI 0.2) **does support sockets**, and is now **Tier 2 stable as of Rust 1.82**.
- Fluent Bit does not currently mention `wasm32-wasip2` or support for WASI 0.2.
###Question
Are there any plans to support **WASI 0.2** (`wasm32-wasip2`) in future versions of Fluent Bit?
If not, is there an alternative approach for creating a custom plugin that performs HTTP requests dynamically?
Thanks for the amazing work on Fluent Bit!
Contributor guide
Assessment
This issue has not been assessed yet.