solo-io / wasm

Web Assembly tools and SDKs for extending cloud-native infrastructure
Apache License 2.0
305 stars 39 forks source link

Support for singleton missing in gloo-envoy 1.5.x #155

Closed emayssat closed 3 years ago

emayssat commented 4 years ago

Hello,

I am trying to run a wasm service based on singleton. A wasm service is wasm code that is not triggered by requests, but through another method, like the onTick timer.

With istio 1.5.x , I can create such a service, but not with the gloo-envoy 1.5.x (beta 13) image. The configuration is rejected by gloo-envoy on start-up. Given the version are different, is there a difference between the syntax of their configuration as well?

Configuration that works in istio

cat ./out/envoy.yaml
...
admin:
  access_log_path: /dev/stdout
  address:
    socket_address:
      address: 0.0.0.0
      port_value: 19000

wasm_service:
- singleton: true
  config:
    name: envoy.filters.http.wasm
    root_id: singleton-http-call
    vm_config:
      runtime: envoy.wasm.runtime.v8
      code:
        local:
          filename: /etc/envoy/wasm/bundle-cpp-istio-1.5.x/build_output/singleton.wasm
      allow_precompiled: true

If you know a similar configuration for gloo-envoy that works, please share. Thanks

emayssat commented 4 years ago

istio-1.5 envoy image is 73f240a29bece92a8882a36893ccce07b4a54664/1.13.1-dev/Clean/RELEASE/BoringSSL

gloo-1.5 envoy image is a692089265903ab256ee720e3cb50861f3c107ec/1.15.0-dev/Distribution/RELEASE/BoringSSL

Sodman commented 3 years ago

This is not currently supported in Gloo, but will be very soon. The feature is in active development, work is being tracked here - https://github.com/solo-io/gloo/issues/3943

Closing out this issue in the wasm repo to favor tracking it in the Gloo repo.