Skip to content

Commit 90a48f4

Browse files
authored
[Debug] Enable curl retry aligned with openai (vllm-project#1539)
Signed-off-by: tzhouam <tzhouam@connect.ust.hk>
1 parent 80c89e0 commit 90a48f4

File tree

2 files changed

+14
-10
lines changed

2 files changed

+14
-10
lines changed

examples/online_serving/qwen2_5_omni/run_curl_multimodal_generation.sh

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -160,10 +160,7 @@ esac
160160
echo "Running query type: $QUERY_TYPE"
161161
echo ""
162162

163-
164-
output=$(curl -sS -X POST http://localhost:8091/v1/chat/completions \
165-
-H "Content-Type: application/json" \
166-
-d @- <<EOF
163+
request_body=$(cat <<EOF
167164
{
168165
"model": "Qwen/Qwen2.5-Omni-7B",
169166
"sampling_params_list": $sampling_params_list,
@@ -186,7 +183,12 @@ output=$(curl -sS -X POST http://localhost:8091/v1/chat/completions \
186183
]
187184
}
188185
EOF
189-
)
186+
)
187+
188+
output=$(curl -sS --retry 3 --retry-delay 3 --retry-connrefused \
189+
-X POST http://localhost:8091/v1/chat/completions \
190+
-H "Content-Type: application/json" \
191+
-d "$request_body")
190192

191193
# Here it only shows the text content of the first choice. Audio content has many binaries, so it's not displayed here.
192194
echo "Output of request: $(echo "$output" | jq '.choices[0].message.content')"

examples/online_serving/qwen3_omni/run_curl_multimodal_generation.sh

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -138,10 +138,7 @@ esac
138138
echo "Running query type: $QUERY_TYPE"
139139
echo ""
140140

141-
142-
output=$(curl -sS -X POST http://localhost:8091/v1/chat/completions \
143-
-H "Content-Type: application/json" \
144-
-d @- <<EOF
141+
request_body=$(cat <<EOF
145142
{
146143
"model": "Qwen/Qwen3-Omni-30B-A3B-Instruct",
147144
"sampling_params_list": $sampling_params_list,
@@ -164,7 +161,12 @@ output=$(curl -sS -X POST http://localhost:8091/v1/chat/completions \
164161
]
165162
}
166163
EOF
167-
)
164+
)
165+
166+
output=$(curl -sS --retry 3 --retry-delay 3 --retry-connrefused \
167+
-X POST http://localhost:8091/v1/chat/completions \
168+
-H "Content-Type: application/json" \
169+
-d "$request_body")
168170

169171
# Here it only shows the text content of the first choice. Audio content has many binaries, so it's not displayed here.
170172
echo "Output of request: $(echo "$output" | jq '.choices[0].message.content')"

0 commit comments

Comments
 (0)