Skip to content

Conversation

@tzolov
Copy link
Collaborator

@tzolov tzolov commented Sep 22, 2025

…error handling

Those changes affect the Prompt and Resources Method callback implementations only

  • Add abstract methods validateParamType and assignExchangeType for better parameter handling
  • Implement strict type validation for exchange parameters (Sync vs Async vs Transport Context)
  • Replace custom exceptions (McpPromptMethodException, McpResourceMethodException) with standardized McpError
  • Add comprehensive parameter type validation with detailed error messages
  • Enhance exchange type assignment logic with proper type checking
  • Update all concrete implementations (Sync, Async, Stateless variants) for both prompt and resource callbacks
  • Add test coverage for new validation logic and error scenarios

…error handling

Those changes affect the Prompt and Resources Method callback implementations only

- Add abstract methods `validateParamType` and `assignExchangeType` for better parameter handling
- Implement strict type validation for exchange parameters (Sync vs Async vs Transport Context)
- Replace custom exceptions (`McpPromptMethodException`, `McpResourceMethodException`) with standardized `McpError`
- Add comprehensive parameter type validation with detailed error messages
- Enhance exchange type assignment logic with proper type checking
- Update all concrete implementations (Sync, Async, Stateless variants) for both prompt and resource callbacks
- Add test coverage for new validation logic and error scenarios

Signed-off-by: Christian Tzolov <[email protected]>
@tzolov tzolov merged commit 0508e4c into spring-ai-community:main Sep 22, 2025
1 check passed
tzolov added a commit that referenced this pull request Sep 22, 2025
…error handling (#59)

Those changes affect the Prompt and Resources Method callback implementations only

- Add abstract methods `validateParamType` and `assignExchangeType` for better parameter handling
- Implement strict type validation for exchange parameters (Sync vs Async vs Transport Context)
- Replace custom exceptions (`McpPromptMethodException`, `McpResourceMethodException`) with standardized `McpError`
- Add comprehensive parameter type validation with detailed error messages
- Enhance exchange type assignment logic with proper type checking
- Update all concrete implementations (Sync, Async, Stateless variants) for both prompt and resource callbacks
- Add test coverage for new validation logic and error scenarios

Signed-off-by: Christian Tzolov <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant