-
Notifications
You must be signed in to change notification settings - Fork 38.9k
Closed
Labels
in: webIssues in web modules (web, webmvc, webflux, websocket)Issues in web modules (web, webmvc, webflux, websocket)status: backportedAn issue that has been backported to maintenance branchesAn issue that has been backported to maintenance branchestype: enhancementA general enhancementA general enhancement
Milestone
Description
We inspect controller methods for method validation once on startup, and it results in the shouldValidate~ flags that protect method validation at runtime.
Validation groups however are determined by delegating to MethodValidationAdapter, which is only available in RequestMappingHandlerAdapter, so it only becomes available to each HandlerMethod at runtime, and as a consequence, it's invoked per request.
We should be able to optimize this determination to be made once on startup. In the very least, the shouldValidate~ flags should be used to avoid the determination of validation groups if validation is not even needed in the first place.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
in: webIssues in web modules (web, webmvc, webflux, websocket)Issues in web modules (web, webmvc, webflux, websocket)status: backportedAn issue that has been backported to maintenance branchesAn issue that has been backported to maintenance branchestype: enhancementA general enhancementA general enhancement