nileshrathi345 opened a new pull request, #535: URL: https://github.com/apache/livy/pull/535
## What changes were proposed in this pull request? Handle HTTP 307 Temporary Redirect in `LivyConnection.sendRequest()` so the Java HTTP client follows standby→active leader redirects in HA mode. POST, DELETE, and multipart requests are retried to the Location URL instead of failing with `IOException: Temporary Redirect`. Also validates that Location is present and consumes the redirect response entity before retry. JIRA: [LIVY-1062](https://issues.apache.org/jira/browse/LIVY-1062) ## How was this patch tested? Unit tests in `LivyConnectionSpec`: - Happy path: POST, DELETE, and multipart POST via 307 redirect (method, headers, body, response type) - Failure paths: missing/empty Location, redirect loop, non-redirect 404 ## Was this patch authored or co-authored using generative AI tooling? Yes, Yes, this was co-authored using Cursor to write the new test cases Generated-by: Cursor Composer, Cursor 3.13.21 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
