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

Binary weaving option to avoid writing unwoven classes to target directory #60

Open
kriegaex opened this issue May 26, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@kriegaex
Copy link
Contributor

kriegaex commented May 26, 2021

As a developer using post-compile weaving (a.k.a. binary weaving), I want to optionally only write aspect-woven classes to the output directory, not unmodified ones.

Use cases:

  • Modifying a (small) subset of third-party library classes, I simply want to see in the output directory, which classes were actually affected (hence changed) by aspect weaving, e.g. if I use ITD on classes implementing interfaces, call() pointcuts or whatever. This is hard to identify without activating verbose weaver logging and then sifting through the build log. This option would also give me the option to build a slim JAR and prepend it to the original on the classpath or put it on the boot classpath in order to shadow the original classes. In the case of debugging aspects, I could always have the original JAR on the classpath and use the woven delta on demand in situations where it is easier to change the class path than to activate LTW.
  • A similar scenario is to weave a subset of JDK classes, also prepending the delta to the boot classpath (JDK 8-) or using --patch-module (JDK 9+), replacing JDK classes in a minimally invasive way instead of having to build a full tools.jar (JDK 8-) or equivalent on JDK 9+.

I have met this question/problem more than once on StackOverflow and I think also on the AspectJ users mailing list. Speaking for myself, I also would like to have this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant