e2e: add cmd probe failover test with true/false command nodes

This commit is contained in:
ginuerzh
2026-07-16 20:53:30 +08:00
parent bef00dffef
commit e9cf3b4d3f
2 changed files with 58 additions and 0 deletions
+43
View File
@@ -0,0 +1,43 @@
services:
- name: proxy
addr: :8080
handler:
type: http
chain: my-chain
listener:
type: tcp
# Live relay: forwards to the echo server.
- name: relay
addr: 127.0.0.1:18081
handler:
type: http
listener:
type: tcp
chains:
- name: my-chain
hops:
- name: hop-1
selector:
strategy: round
maxFails: 1
failTimeout: 10s
nodes:
- name: node-live
addr: 127.0.0.1:18081
connector:
type: http
probe:
type: cmd
command: "true"
interval: 5s
# This node's probe always fails → pre-marked dead → FailFilter excludes it.
- name: node-dead
addr: 127.0.0.1:18082
connector:
type: http
probe:
type: cmd
command: "false"
interval: 5s