mirror of
https://github.com/langgenius/dify-plugin-daemon.git
synced 2026-07-22 01:35:24 -04:00
23a4662e65
* feat: add retry mechanism for serverless invocation on 502 errors - Add MAX_SERVERLESS_RETRY_TIMES config (default: 3) for configurable retry attempts - Implement exponential backoff retry logic (500ms, 1s, 2s, ...) for 502 Bad Gateway errors - Only retry on 502 status code as it indicates transient AWS Lambda gateway issues - Add comprehensive test suite with 11 test cases covering all retry scenarios - Ensure proper HTTP response body cleanup on retries to prevent resource leaks * refactor: simplify retry logic and error handling in serverless invocation * fix: max time * fix: test