yykaue opened a new pull request, #6932:
URL: https://github.com/apache/shenyu/pull/6932

   Fixes #6750.
   
   `RequestConfigHelper` previously dereferenced `requestTemplate` and `url` 
without validating their presence. Invalid MCP tool configurations therefore 
caused opaque `NullPointerException`s during tool invocation.
   
   This PR:
   
   - Validates that `requestTemplate` is present before reading request 
configuration.
   - Validates that the required `url` field is present and non-null.
   - Throws descriptive `IllegalArgumentException`s for invalid configurations.
   - Preserves the existing default `GET` method when `method` is omitted.
   - Applies the same request-template validation when reading `argsToJsonBody`.
   - Strengthens regression tests to verify the exception types and messages.
   
   ## Verification
   
   - `RequestConfigHelperTest`: 15 tests passed.
   - MCP Server module: 78 tests passed.
   - Checkstyle passed with 0 violations.
   - `git diff --check` passed.
   
   @Aias00 Could you please review this PR?


-- 
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]

Reply via email to