mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-21 11:56:38 +00:00
fix(internode): align msgpack benchmark gates (#5197)
Update the internode gRPC benchmark P2 env output to require both the msgpack-only request flag and the fleet-confirmed gate before measuring a true msgpack-only phase. Document the dual-gate rollback semantics and add a dry-run script test so the benchmark driver cannot silently regress to the single-flag flow. Co-authored-by: heihutu <heihutu@gmail.com>
This commit is contained in:
@@ -95,10 +95,15 @@ stage_env() {
|
||||
;;
|
||||
p2)
|
||||
if [[ "${phase}" == "after" ]]; then
|
||||
# Only enable after the msgpack json-fallback counter has read zero across a window.
|
||||
printf '%s\n' 'RUSTFS_INTERNODE_RPC_MSGPACK_ONLY=true'
|
||||
# Only enable after the msgpack json-fallback counter has read zero across a window and
|
||||
# the fleet confirmation gate has passed.
|
||||
printf '%s\n' \
|
||||
'RUSTFS_INTERNODE_RPC_MSGPACK_ONLY=true' \
|
||||
'RUSTFS_INTERNODE_RPC_MSGPACK_ONLY_FLEET_CONFIRMED=true'
|
||||
else
|
||||
printf '%s\n' 'RUSTFS_INTERNODE_RPC_MSGPACK_ONLY=false'
|
||||
printf '%s\n' \
|
||||
'RUSTFS_INTERNODE_RPC_MSGPACK_ONLY=false' \
|
||||
'RUSTFS_INTERNODE_RPC_MSGPACK_ONLY_FLEET_CONFIRMED=false'
|
||||
fi
|
||||
;;
|
||||
p3)
|
||||
@@ -155,10 +160,18 @@ case "${STAGE}" in
|
||||
p0|p1|p2)
|
||||
echo "-- NOTE: (re)start rustfs on all nodes with the env above before this measurement is valid."
|
||||
[[ -x "${TRANSPORT_BENCH}" ]] || { echo "ERROR: ${TRANSPORT_BENCH} not found/executable" >&2; exit 1; }
|
||||
run "${TRANSPORT_BENCH}" --out-dir "${OUT_DIR}" "${PASSTHROUGH[@]}"
|
||||
if ((${#PASSTHROUGH[@]} > 0)); then
|
||||
run "${TRANSPORT_BENCH}" --out-dir "${OUT_DIR}" "${PASSTHROUGH[@]}"
|
||||
else
|
||||
run "${TRANSPORT_BENCH}" --out-dir "${OUT_DIR}"
|
||||
fi
|
||||
;;
|
||||
p3)
|
||||
[[ -x "${FAILOVER_BENCH}" ]] || { echo "ERROR: ${FAILOVER_BENCH} not found/executable" >&2; exit 1; }
|
||||
OUT_DIR="${OUT_DIR}" run "${FAILOVER_BENCH}" "${PASSTHROUGH[@]}"
|
||||
if ((${#PASSTHROUGH[@]} > 0)); then
|
||||
OUT_DIR="${OUT_DIR}" run "${FAILOVER_BENCH}" "${PASSTHROUGH[@]}"
|
||||
else
|
||||
OUT_DIR="${OUT_DIR}" run "${FAILOVER_BENCH}"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
Reference in New Issue
Block a user