-
Notifications
You must be signed in to change notification settings - Fork 38.5k
Annotated method argument matching performance issue [SPR-15060] #19626
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
Comments
Gary Russell commented After further debugging, the issue is we never get a hit on the cache because |
Juergen Hoeller commented Gary Russell, could it be that you're not caching the Of course, we shouldn't have such a regression just because of new That said, I nevertheless highly recommend |
Juergen Hoeller commented Adding a full As per my comment above, all those problems disappear - even cutting down the invocation overhead by a factor of six - when cached |
Artem Bilan commented Juergen, Thank you for digging this and for the update. But let me share my current concerns if that helps. We don't create So, I'm not sure that our problem is around |
Juergen Hoeller commented I'm pretty sure that the problem is different It's worth debugging this in Spring Integration, finding out about potential repeated |
Artem Bilan commented Juergen, does it say anything to you?
That is where I see |
Gary Russell commented Juergen Hoeller thanks for looking at this. FYI We have a planned activity to move from SpEL to |
Juergen Hoeller commented Ok, that clarifies it indeed: You're going through SpEL's generic resolution algorithm there which indeed recreates As a side note, I have no idea why |
Juergen Hoeller commented We check for annotation identity, then same annotation proxy class, then reflective |
Gary Russell commented Thanks Juergen Hoeller I have confirmed that we are back to 4.3.3 level performance. |
Mike Noordermeer commented It seems that this bug causes a massive memory leak for us, with 4.3.5. The convertercache contains millions of elements, taking up 500+MB heap space. Not 100% sure it is this bug, but I will try with 4.3.6 to see if that fixes the issue. |
Mike Noordermeer commented I can confirm upgrading to Spring 4.3.6 fixes the problem. For us the problem was not in Spring Integration, but in a
This causes a new cache entry for each method execution / parameter. Maybe this is something that needs to be looked into, if the parameter annotations are expected to be cached. |
Gary Russell opened SPR-15060 and commented
Possibly related to #19496
Annotated: 3521 not: 36 second annotated: 11202
Yourkit pointed me to
ConcurrentReferenceHashMap
and we're getting cache misses and adding new entries for each invocation.Affects: 4.3.5
Reference URL: http://stackoverflow.com/questions/41346616/spring-boot-starter-integration-1-4-3-performance-degradation
Attachments:
Issue Links:
@ModelAttribute
("is duplicated by")@AliasFor
Referenced from: commits e38c020, 794580f
3 votes, 9 watchers
The text was updated successfully, but these errors were encountered: