Closed ray1888 closed 1 month ago
FYI: base environment is below
OS: centos 7.9 aarch64 (kernal_verison: 4.18.0-348.20.1.el7.aarch64 ) Docker verison: 20.10.24 Kong Version: 3.7.1
While I didn't really understand what the issue was, I assume it is some issue with the external dispatch call. We are aware of some dispatch issues in the module in Kong 3.7.1. The latest release of the module has a number of fixes related to dispatch calls (see changelog). For now, I suggest waiting for a new Kong release that embeds a newer version of the module, which should come soon.
I checked with my team and the timeline for a Kong release with this module's dispatch fixes is still several weeks away. If in the meantime you wish to keep developing your filter, I suggest working on a local build of ngx_wasm_module. It is very easy to work on the module locally and develop your filter against it. Then later when the new Kong release has the latest ngx_wasm_module, you can load your filter with it. To work with ngx_wasm_module locally consult DEVELOPER.md which has all the instructions needed (make setup
and make
are almost all that you need). Then you can write an nginx.conf
that loads your filter, and keep running it and developing it efficiently. An FAQ section has a tutorial to have a quick nginx.conf
file you can edit: see here.
On second look this seems to be the same issue as the one you already opened last week, aka calling dispatch_http_call
with ctx.clusterName
instead of a real hostname. Closing this as duplicate.
i was using the proxywasm go sdk to write a wasm plugin , code are below
the process i support is after call a api( as long as the endpoint exist), the filter can goon to call the regular service, but is turn out, it just block there.
kong logs show like
after filters calling clusterremote , but not of the upstream is call .
how to reproduce
services:
upstreams:
set -x
DEMO_KONG_CONTAINER="${DEMO_KONG_CONTAINER:-kong-wasm}" DEMO_KONG_IMAGE="${DEMO_KONG_IMAGE:-kong/kong:nightly}"
script_dir=$(dirname $(realpath $0))
docker stop $DEMO_KONG_CONTAINER docker rm $DEMO_KONG_CONTAINER
access_localhost=""
docker run -d --name "$DEMO_KONG_CONTAINER" \ $access_localhost \ -v "$script_dir/config:/kong/config" \ -v "$script_dir/wasm:/wasm" \ -e "KONG_LOG_LEVEL=debug" \ -e "KONG_DATABASE=off" \ -e "KONG_DECLARATIVE_CONFIG=/kong/config/demo.yml" \ -e "KONG_NGINX_WASM_SHM_KV_KONG_WASM_RATE_LIMITING_COUNTERS=12m" \ -e "KONG_PROXY_ACCESS_LOG=/dev/stdout" \ -e "KONG_PROXY_ERROR_LOG=/dev/stderr" \ -e "KONG_WASM=on" \ -e "KONG_WASM_FILTERS_PATH=/wasm" \ --net=host \ "$DEMO_KONG_IMAGE"