Files

23 lines
1.6 KiB
Plaintext

# Fallback: OpenAI first, then Anthropic, then Gemini
A. OpenAI fails with each status (no client retries). Does the call move on?
OpenAI 400 -> thrown requests: openai=1 anthropic=0 gemini=0 trail: [openai: failed with status 400]
OpenAI 401 -> thrown requests: openai=1 anthropic=0 gemini=0 trail: [openai: failed with status 401]
OpenAI 429 -> answered requests: openai=1 anthropic=1 gemini=0 trail: [openai: failed with status 429, anthropic: ok]
OpenAI 500 -> answered requests: openai=1 anthropic=1 gemini=0 trail: [openai: failed with status 500, anthropic: ok]
OpenAI 503 -> answered requests: openai=1 anthropic=1 gemini=0 trail: [openai: failed with status 503, anthropic: ok]
B. The same 503 with the client's own retries switched on (maxRetries 2)
OpenAI 503 -> answered requests: openai=3 anthropic=1 gemini=0
C. Gemini retries in two layers: the Google SDK (HttpRetryOptions.attempts) and Spring AI's RetryTemplate
SDK attempts=1, RetryTemplate retries=0 -> 1 request(s) for one call
SDK attempts=1, RetryTemplate retries=2 -> 3 request(s) for one call
SDK attempts=3, RetryTemplate retries=0 -> 3 request(s) for one call
SDK attempts=3, RetryTemplate retries=2 -> 9 request(s) for one call
nothing configured at all -> 5 requests for one call, and it took more than 5 seconds: true
D. Everything down: the last provider's failure is the one you see
all three 503 -> thrown requests: openai=1 anthropic=1 gemini=1
trail: [openai: failed with status 503, anthropic: failed with status 503, gemini: failed with status 503]