-
Notifications
You must be signed in to change notification settings - Fork 41.2k
Consider enabling major optimization in AspectJ 1.9.8 #29754
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
As far as I understand, this optimization has not been enabled by default. This requires setting the |
At the core framework level, we don't really deal with setting system properties indeed. We don't even have a proper place to initialize such a system property, just possibly in a Servlet initializer. From that perspective, enabling this optimization by default seems more sensible at the Spring Boot level? |
The community will largely ignore even the existence of this option. Since this sounds like a free performance win with no downsides I'd vote for enabling it by default. Though maybe this is spring boot job? |
I'm not so sure this has no downside at all - the AspectJ team would have enabled it by default if it was that clear cut. I'm moving this issue for consideration to Spring Boot as we can't act on it in Spring Framework anyway. |
I don't think we should do this. From the end of @aclement's comment that @bclozel linked to above:
FWIW, I'm not sure that we're in a position to set an AspectJ system property either as it may conflict with something else running in the same JVM, particularly in a war deployment to a standalone container. |
I was hoping I'd get some feedback relatively quickly and we could look to turn these on even in 1.9.9 - I agree probably not up to Spring to do it. I suppose running all the Spring tests with the options turned on could be something to check (I haven't tried that) but that is basic testing that verifies nothing breaks, it wouldn't be revealing issues like memory bloat over time due to never clearing/caches or the shared static state causing problems. But I know, I probably won't see the real error reports until it is turned on by default. (Feel free to cc: me on any feedback you get for anyone using these under Spring) Maybe I could do a Spring blog to spread the word and try to drive feedback. |
@aclement making an announcement/linking the blog on the java subreddit could gather some feedback too |
FYI I've run the entire Spring Framework test suite and got no failure, but cannot vouch for any performance issue with tests. @LifeIsStrange do you have an application where this new feature could have an impact? If so, we'd be interested in your findings. |
No unfortunately I have no web application at hand to test |
I'm going to close this one since I don't think Spring Boot should be changing the default. I think the best plan is to try and have AspectJ users test their applications with the property set and for the default to be switched in due course. |
@aclement Out of curiosity, has this optimization been turned on by default since then? |
eclipse-aspectj/aspectj#9
Therefore, if that performance profile is common, then enabling this optimization with a flag on the next AspectJ release has the potential:
While this PR seems extremely interesting, it lacks extensive testing so it would be a nice, high impact, low hanging fruit for the Spring team, to test it, to measure the effects on metrics (startup time, throughput, resource use (io, cpu) and memory use. And finally to enable it by default after some testing :)
The text was updated successfully, but these errors were encountered: