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

Remove synchronization around filteredPropertyDescriptorsCache in case of non-existing entry [SPR-12106] #16722

Closed
spring-projects-issues opened this issue Aug 20, 2014 · 2 comments
Assignees
Labels
in: core type: enhancement
Milestone

Comments

@spring-projects-issues
Copy link
Collaborator

@spring-projects-issues spring-projects-issues commented Aug 20, 2014

Craig opened SPR-12106 and commented

AbstractAutowireCapableBeanFactory.filterPropertyDescriptorsForDependencyCheck synchronizes on filteredPropertyDescriptorsCache.

filteredPropertyDescriptorsCache is a ConcurrentHashMap, so such synchronization is not necessary.

Removing the lock would improve concurrency.


Affects: 4.1 RC2

Issue Links:

  • #16494 Performance regression for custom autowireBean calls with many properties
  • #13456 Unnecessarily conservative locking in registerDependentBean is a bottleneck

Referenced from: commits 8eac870

@spring-projects-issues
Copy link
Collaborator Author

@spring-projects-issues spring-projects-issues commented Aug 20, 2014

Craig commented

#630

@spring-projects-issues
Copy link
Collaborator Author

@spring-projects-issues spring-projects-issues commented Aug 21, 2014

Juergen Hoeller commented

That synchronized block was only hit in case of a non-existing entry... But good point, even then it's not strictly necessary since the PropertyDescriptor array doesn't need to be unique. Revised for 4.1 GA now.

Juergen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core type: enhancement
Projects
None yet
Development

No branches or pull requests

2 participants