You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
files: shenyu-plugin/shenyu-plugin-ai/shenyu-plugin-ai-proxy/src/main/java/org/apache/shenyu/plugin/ai/proxy/enhanced/service/AiProxyExecutorService.java:88-115; consumption at AiProxyPlugin.java:171-182
description: executeStream wraps doChatStream in Retry.max(1) then .onErrorResume(NonTransientAiException.class, handleFallbackStream). When the upstream stream errors AFTER emitting some chunks, Reactor retryWhen re-subscribes, issuing a brand-new upstream call emitting from the beginning. Those first-attempt chunks were already written to the client SSE response, so the client receives [partial attempt-1][full attempt-2].
impact: Corrupted/duplicated AI completions for streaming calls that hit a mid-stream error; non-idempotent streaming calls are replayed.
suggested_fix: For streaming, do not blanket-retry mid-stream; retry only before any emission (buffer-first) or fail and let the client reconnect.
Activity
github-actions commentedon Aug 3, 2026
👋 Hello @Aias00
A new issue has been opened by @Aias00:
Please review when you have time. Thank you! 🙏