Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimize lookup of field errors in AbstractBindingResult [SPR-11304] #15928

Closed
spring-projects-issues opened this issue Jan 13, 2014 · 1 comment
Assignees
Labels
in: core Issues in core modules (aop, beans, core, context, expression) status: backported An issue that has been backported to maintenance branches type: enhancement A general enhancement
Milestone

Comments

@spring-projects-issues
Copy link
Collaborator

spring-projects-issues commented Jan 13, 2014

Daniel Mikusa opened SPR-11304 and commented

There is a performance issue when Spring MVC validates a large object graph using JSR 303 Bean Validation API & Hibernated Validator.

Here is the object structure for the sample project in spring-framework-issues...

- Address
  - propA (string)
  - propB (string)
  - propC (List) // has around 100 elements
       - Object1
           - propA (string)
           - propB (List)  // has around 30 elements
               - Object 2
                    - propA
                    - propB
                    - propC

Worst case it takes about 2.5 seconds to process a request that fails validation. Without validation, processing is very fast.


Affects: 3.2.6, 4.0 GA

Issue Links:

Backported to: 3.2.7

@spring-projects-issues
Copy link
Collaborator Author

Rossen Stoyanchev commented

I've made a small optimization in AbstractErrors that improves performance by ~ 30%. The overall request time is still not ideal but the number of errors (~12K) is unusually large. Given some additional details on the specific scenario that leads to this, we could make further optimzations.

@spring-projects-issues spring-projects-issues added status: backported An issue that has been backported to maintenance branches type: enhancement A general enhancement in: core Issues in core modules (aop, beans, core, context, expression) labels Jan 11, 2019
@spring-projects-issues spring-projects-issues added this to the 4.0.1 milestone Jan 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) status: backported An issue that has been backported to maintenance branches type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants