Wasm

Attention

The Wasm filter is experimental and is currently under active development. Capabilities will be expanded over time and the configuration structures are likely to change.

The HTTP Wasm filter is used to implement an HTTP filter with a Wasm plugin.

Note

This filter is not supported on Windows.

Example configuration

Example filter configuration:

24                  cluster: web_service
25
26          http_filters:
27          - name: envoy.filters.http.wasm
28            typed_config:
29              "@type": type.googleapis.com/envoy.extensions.filters.http.wasm.v3.Wasm
30              config:
31                name: "my_plugin"
32                root_id: "my_root_id"
33                # if your wasm filter requires custom configuration you can add
34                # as follows
35                configuration:
36                  "@type": "type.googleapis.com/google.protobuf.StringValue"
37                  value: |
38                    {}
39                vm_config:
40                  vm_id: "my_vm_id"
41                  code:
42                    local:
43                      filename: "lib/envoy_filter_http_wasm_example.wasm"
44          - name: envoy.filters.http.router
45            typed_config:
46              "@type": type.googleapis.com/envoy.extensions.filters.http.router.v3.Router
47
48  clusters:
49  - name: web_service

The preceding snippet configures a filter from a Wasm binary on local disk.