Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] AspectJ 1.9.21.2 maintenance release

As always! Thank you! :-)

As a short heads up, I have some issues with that version and the version before within the IDE. I just filed a bug with IntellilJ about that.



Best regards

Mario


Am 13.03.2024 um 10:50 schrieb Alexander Kriegisch via aspectj-users <aspectj-users@xxxxxxxxxxx>:

Dear AspectJ users,

we are pleased to announce the AspectJ maintenance release 1.9.21.2 supporting Java 21. Please note that since 1.9.19, the minor-minor version indicates the corresponding latest Java release (byte code version) supported by the AspectJ compiler and weaver. I.e., 1.9.21.2 → Java 21.

 

Improvements

Previously, when targeting the same join point from multiple around advices in annotation-style @AspectJ syntax, there were limitations in functionality in concurrent (multi-threaded) situations, if the around advice code was not inlined. This was improved in AspectJ 1.9.9 (see also issue #128), but the improvement only applied to child threads directly created during aspect execution and would fail for pre-existing, long-lived threads, e.g. thread pools used by executor services. Furthermore, the improvement could lead to memory leaks, not cleaning up thread-local references to posssibly expensive objects. In such situations, users had to switch to native-syntax aspects which never had that problem to begin with due to their different internal structure.
 
Now, issue #141 has been resolved, closing the gap and, as well as possible given their different internal structure, bringing @AspectJ aspects up to par with native-syntax aspects in concurrent situations, while simultaneously also addressing the memory leak issue #288. This is a substantial improvement, and annotation-style syntax users are strongly engouraged to upgrade. Thanks to user pagrawalgit for raising the memory leak issue and triggering me to think about the concurrency issue more broadly and finally solve both in one shot.

Other changes and bugfixes

The fix for issue #277 in AspectJ 1.9.21.1 introduced a regression bug in the optional weaving cache now fixed in issue #285. Thanks to user Kimming Lau for raising and re-testing both issues.

Other notes about 1.9.21.x

  • Since 1.9.21, the AspectJ compiler AJC (contained in the aspectjtools library) no longer works on JDKs 11 to 16. The minimum compile-time requirement is now JDK 17 due to upstream changes in the Eclipse Java Compiler (subset of JDT Core), which AspectJ is a fork of. You can still compile to legacy target versions as low as Java 1.3 when compiling plain Java code or using plain Java ITD constructs which do not require the AspectJ runtime aspectjrt, but the compiler itself needs JDK 17+. Just like in previous AspectJ versions, both the runtime aspectjrt and the load-time weaver aspectjweaver still only require JRE 8+.
  • History: Since 1.9.7, the AspectJ compiler AJC needed JDK 11+, before then JDK 8+.

Resources

  • For more detailed release information, please read the release notes.
  • The current artifacts (runtime, weaver, compiler, matcher) are available on Maven Central.
  • The AspectJ installer can be found on GitHub.
  • There is also an AJDT update site for Eclipse 4.30 (2023-12). Unfortunately, updates sites for previous Eclipse versions , e.g. 4.26 (2022-12) and 4.23 (2022-03) are no longer compatible with AspectJ 1.9.21, because the latter dependes on upstream Eclipse changes. So if you want to use ADJT builds with Eclipse IDE, you need to upgrade to 2023-12. Otherwise, you can only use AspectJ 1.9.21 via Maven build, not via direct IDE. On top of that, you also need an extra update site for Eclipse 2023-12 itself. The IDE guide explains, why this is necessary.
  • On GitHub, there also is a short guide describing options for setting up a development environment.
  • See here for more information about how to upgrade to the latest AspectJ version when using dev.aspectj:aspectj-maven-plugin:1.14.

Enjoy AspectJ!

The AspectJ team

_______________________________________________
aspectj-users mailing list
aspectj-users@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/aspectj-users


Back to the top