yykaue opened a new pull request, #6933: URL: https://github.com/apache/shenyu/pull/6933
## Description Fixes #6719. `GlobalErrorHandler` previously cast `HttpStatusCode` directly to `HttpStatus`, causing a `ClassCastException` when handling non-standard status codes. This PR: - Removes the unsafe `HttpStatusCode` to `HttpStatus` cast. - Preserves the explicit reason when provided. - Uses the standard reason phrase for known HTTP status codes. - Falls back to the numeric status code for non-standard codes without a reason. - Adds regression tests for non-standard status codes with and without a reason. ## Tests - `GlobalErrorHandlerTest`: 3 tests passed. - `shenyu-web`: 83 tests passed. - Checkstyle passed with 0 violations. @Aias00 Please review this PR when you have time. -- 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]
