Description
Is your feature request related to a problem? Please describe.
The current implementation of parameter validation logic for gRPC and HTTP requests is fragmented, with each request processing method implementing its own logic. This approach lacks unity and is difficult to manage. Additionally, modifying the code to reflect changes in parameter validation standards can prove challenging.
Describe the solution you'd like
To simplify parameter validation logic, a request parameter validation layer can be added. This layer can intercept requests using interceptors or filters, extract relevant parameters based on request type, and then use a unified parameter validation method to validate parameters.Different extract methods can be added by spi.
Describe alternatives you've considered
To simplify parameter validation logic, a request parameter validation layer can be added. This layer can intercept requests using interceptors or filters, extract relevant parameters based on request type, and then use a unified parameter validation method to validate parameters.Different extract methods can be added by spi.Users can choose to enable or disable parameter validation through VM parameters.
TODO List
- Refactor and abstract config request basic info into
AbstractConfigRequest
- Implement the parameter validation utility class
- Implement grpc server interceptor and gprc param extractors
- Implement http filters and http param extractors