Compare commits

..

5 Commits

Author SHA1 Message Date
澄潭
8f1f935bc9 docs: add AGENTS.md with repo/plugin index for AI agents
Signed-off-by: 澄潭 <zty98751@alibaba-inc.com>
2026-07-07 00:54:23 +08:00
澄潭
4db97b6a36 test: build #4034 repro plugin in CI (VERSION -alpha)
CI build-wasm-plugins.sh only compiles wasm-go plugins whose VERSION ends
in -alpha; VERSION was "1" so the plugin was skipped and the file:// wasm was
absent in CI, making the wasm filter fail closed (HTTP 500 on every request).
Bump VERSION to 1.0.0-alpha so CI builds the plugin.

Signed-off-by: 澄潭 <zty98751@alibaba-inc.com>
2026-07-07 00:39:16 +08:00
澄潭
bf30043807 test: add #4034 conformance repro (redis-failure inject CPU spin)
Adds a wasm-go conformance case reproducing #4034: a deferred async
redis-failure callback synchronously calls injectEncodedDataToFilterChain,
which pre-fix makes WasmBase::doAfterVmCallActions re-queue an action forever
and spins a worker at 100% CPU. Redis is pointed at an unroutable endpoint so
the failure callbacks fire under concurrency. With the drain-to-local fix the
gateway stays responsive (200); a spinning worker would fail via timeout.

Validated end-to-end against the rebuilt gateway image.

Signed-off-by: 澄潭 <zty98751@alibaba-inc.com>
2026-07-06 21:48:47 +08:00
澄潭
0a8aea12d6 fix: point ENVOY_LATEST_IMAGE_TAG at rebuilt gateway for #4034 drain-to-local
Use the gateway image built from the envoy submodule that carries the
proxy-wasm-cpp-host doAfterVmCallActions drain-to-local fix, so e2e and
dev installs exercise the #4034 CPU-spin fix.

Signed-off-by: 澄潭 <zty98751@alibaba-inc.com>
2026-07-06 21:36:14 +08:00
澄潭
91244c578a fix: bump envoy submodule to include doAfterVmCallActions drain-to-local (#4034)
Advances the envoy/envoy submodule from f49d591e to f468a1a3 (higress-group/envoy
envoy-1.36 tip), which carries the proxy_wasm_cpp_host pin bump (higress-group/envoy#28)
picking up higress-group/proxy-wasm-cpp-host#12.

That fix makes WasmBase::doAfterVmCallActions reentry-safe (drain the
after_vm_call_actions_ queue into a stack-local before iterating), resolving the
worker-thread CPU 100% infinite loop when a Wasm plugin re-enters via
onRedisCallFailure + injectEncodedDataToFilterChain (#4034).

Signed-off-by: 澄潭 <zty98751@alibaba-inc.com>
2026-07-06 15:45:03 +08:00
3 changed files with 0 additions and 99 deletions

View File

@@ -1,94 +0,0 @@
---
name: higress-update-envoy-gateway
description: Update Higress Envoy binary and gateway image dependencies for e2e validation. Use when Codex needs to build Envoy packages from the current Higress branch, upload those packages to higress-group/proxy releases, update Makefile.core.mk ENVOY_PACKAGE_URL_PATTERN and ENVOY_LATEST_IMAGE_TAG, run make build-gateway-local, retag the generated proxy/proxyv2 image as gateway, push the gateway image, or prepare a signed-off PR that lets Higress e2e tests consume a new Envoy build.
---
# Higress Envoy Gateway Dependency Update
## Core Workflow
Run from the Higress repo root unless a step explicitly says otherwise.
1. Verify context:
- Check `git status --short --branch`.
- Do not remove unrelated user changes or generated artifacts.
- Use `gh` for GitHub release/PR checks and always pass `--repo` for non-current repos.
2. Build Envoy packages from the current branch:
```bash
git submodule update --init
make build-envoy
```
Expected artifacts land in `external/package/`, typically:
- `envoy-alpha-<proxy-sha>.tar.gz`
- `envoy-symbol-<proxy-sha>.tar.gz`
- matching `.sha256` and `.dwp` files
3. Publish Envoy package release in `higress-group/proxy`:
- Create a new release tag by incrementing the requested RC/test tag, for example `v2.2.4-rc.2-test-cpp-host`.
- Match the reference release asset names, even if local filenames include SHAs:
- local `envoy-alpha-<sha>.tar.gz` uploads as `envoy-amd64.tar.gz`
- local `envoy-symbol-<sha>.tar.gz` uploads as `envoy-symbol-amd64.tar.gz`
- Use temporary renamed copies rather than renaming source artifacts:
```bash
cp external/package/envoy-alpha-<sha>.tar.gz /tmp/envoy-amd64.tar.gz
cp external/package/envoy-symbol-<sha>.tar.gz /tmp/envoy-symbol-amd64.tar.gz
gh release create <release-tag> /tmp/envoy-amd64.tar.gz /tmp/envoy-symbol-amd64.tar.gz \
--repo higress-group/proxy --target <target-branch> --title <release-tag> --generate-notes
gh release view <release-tag> --repo higress-group/proxy --json tagName,targetCommitish,assets,url
```
- If following an existing reference release, inspect it first with `gh release view`.
4. Update Higress Makefile dependencies:
- In `Makefile.core.mk`, set:
```make
export ENVOY_PACKAGE_URL_PATTERN?=https://github.com/higress-group/proxy/releases/download/<release-tag>/envoy-symbol-ARCH.tar.gz
```
- After building and pushing the gateway image, set:
```make
ENVOY_LATEST_IMAGE_TAG ?= <gateway-image-tag>
```
5. Build the local gateway image:
```bash
make build-gateway-local
```
Watch the log to confirm Envoy downloads from the new release URL. The build target may emit an image under a proxy-style repository/name, commonly:
- `higress-registry.cn-hangzhou.cr.aliyuncs.com/higress/proxyv2:<tag>`
6. Retag proxy image as gateway:
```bash
docker tag higress-registry.cn-hangzhou.cr.aliyuncs.com/higress/proxyv2:<tag> \
higress-registry.cn-hangzhou.cr.aliyuncs.com/higress/gateway:<tag>
docker images --format '{{.Repository}}:{{.Tag}} {{.ID}} {{.CreatedSince}}' \
higress-registry.cn-hangzhou.cr.aliyuncs.com/higress/gateway
```
Verify the `gateway:<tag>` and `proxyv2:<tag>` image IDs match.
7. Push the gateway image when requested:
```bash
docker push higress-registry.cn-hangzhou.cr.aliyuncs.com/higress/gateway:<tag>
```
Record the pushed digest in the final response.
8. Commit and push Makefile changes:
- Commit only intended tracked files. Do not add `plugins/golang-filter/golang-filter_amd64.so` or other build outputs unless explicitly requested.
- Use DCO sign-off:
```bash
git add Makefile.core.mk
git commit -s -m "Update gateway envoy dependencies"
git push origin <branch>
```
- If DCO fails after a previous unsigned commit:
```bash
git commit --amend --no-edit --signoff
git push --force-with-lease origin <branch>
gh pr checks <pr-number> --repo higress-group/higress
```
## Practical Notes
- `make build-gateway-local` may need Docker daemon access, network access, and write access to repo/submodule state.
- If sandboxed commands fail with read-only filesystem errors, Docker socket permission errors, or network failures, rerun the same important command with elevated permissions and a concrete justification.
- The default local gateway tag usually comes from the current Git revision shown in the build log as `TAG=<sha>`.
- For e2e validation, the point of this workflow is to make `install-dev`, `install-dev-wasmplugin`, and local image update targets use the newly pushed gateway image through `ENVOY_LATEST_IMAGE_TAG`.

View File

@@ -1,4 +0,0 @@
interface:
display_name: "Higress Envoy Gateway"
short_description: "Update Envoy packages and gateway tag"
default_prompt: "Use $higress-update-envoy-gateway to update Higress Makefile Envoy dependencies and build a gateway image for e2e validation."

View File

@@ -1 +0,0 @@
../../.agents/skills/higress-update-envoy-gateway