Re: [aspectj-users] Compile error with aspectj

2022-01-14 Thread Andy Clement
Hey. Nothing obvious leaps out to me but it would be easier to look at in a sample project (I'm interested in the build configuration for example). That kind of problem seems pretty fundamental which suggests a config thing - or maybe a modules thing, are you attempting to build using Java9+ module

[aspectj-users] AspectJ 1.9.7 released

2021-06-28 Thread Andy Clement
Hi everyone, I'm pleased to announce AspectJ 1.9.7 is released. To read more about the enhancements (like Java 15 and 16 support), take a look at the readme here . The most serious c

Re: [aspectj-users] Openjdk11 and Security Manager

2021-06-09 Thread Andy Clement
ork, many of these >> security holes are getting closed off. >> >> You will also see more of these issues in the next LTS release (15 I >> think is the number). >> >> >> >> >> >> Tim >> >> >> >> *From:* aspectj-us

Re: [aspectj-users] Openjdk11 and Security Manager

2021-06-09 Thread Andy Clement
Hey, I'm not an expert on Java Security unfortunately (you might find a few of those folks if you ask this on Stack overflow?). With your reference to it working for one classloader and not another, how feasible is it to set the context classloader to the one you find that works? Or will that bre

Re: [aspectj-users] AspectJ + AJDT + AspectJ Maven development versions for Java 16 available

2021-04-29 Thread Andy Clement
o such a crucial and awesome technology as AspectJ. >> Further, given >> > Spring's substantial adoption of Kotlin, why more effort hasn't gone >> into a >> > sister/twin effort for AOP in Kotlin (what I call "AspectK"). >> > >> > Wh

Re: [aspectj-users] AspectJ + AJDT + AspectJ Maven development versions for Java 16 available

2021-04-28 Thread Andy Clement
ity! > > > > You might know me as a fellow user who over the years asked or answered > > questions, raised bugs or commented here. I also answer questions about > > AspectJ and Spring AOP on StackOverflow, in order to unburden Andy > > Clement as a maintainer from user support

Re: [aspectj-users] Is AspectJ compatible with Java 15?

2021-02-05 Thread Andy Clement
yeah, Java has started moving a little too quickly for my liking :) It is quite complex folding in all the JDT changes each time (that process could be improved, practically automated if the diffs were a bit neater I think). I'm almost tempted to just update for LTS releases, possibly intermediate

Re: [aspectj-users] Java 9+ modules questions

2021-01-04 Thread Andy Clement
I think you've found all there is. No-one is banging on the door for it to improve - I don't actually see much use of the module system out there in the wild so nothing has moved forward. cheers, Andy On Thu, 17 Dec 2020 at 22:42, Alexander Kriegisch wrote: > Okay I found these tests: > https:/

Re: [aspectj-users] Enum Value matching facility

2020-10-21 Thread Andy Clement
Hey, It is quite an old issue. I thought I'd done something around enum matching but I can't find it - I think maybe it was just in the context of enums used in annotation values. Re-reading the issue now I don't see exactly what it is asking for "Enum code requires Enum value JoinPoints." - if it

Re: [aspectj-users] high JVM consumption on springboot-aspectj LTW

2020-09-25 Thread Andy Clement
There is a patch (and github fork) here https://bugs.eclipse.org/bugs/show_bug.cgi?id=565450 that someone made that is supposed to help I think - it isn't integrated because I haven't had time to try it out and review it. If you feel like building an AspectJ to try it out, that might be more eviden

Re: [aspectj-users] Proceeding with all arguments in native syntax

2020-09-05 Thread Andy Clement
of elegant, probably > manageable from the perspective of pointcut parsing because there is no > really new syntax, and the functionality to proceed with an Object[] is > already in the code base, which is why it works in @AspectJ syntax. > > -- > Alexander Kriegisch > https://scrum-master

Re: [aspectj-users] Proceeding with all arguments in native syntax

2020-09-04 Thread Andy Clement
I feel like there are some bugs that talk around this topic, but I can't quite find the one I'm thinking of. I found https://bugs.eclipse.org/bugs/show_bug.cgi?id=233718 and it was interesting to read what I was writing 12 years ago :) I feel like i prototyped an improved arg matching system but I

Re: [aspectj-users] AspectJ at Github

2020-08-14 Thread Andy Clement
I, all links pointing at the > old name will be forwarded to the new name/location. > > Lars > > Am 2020-08-14 23:36, schrieb Andy Clement: > > That reason would be lost in the mists of time. There is the related > aspectj-shadows project that feeds into this one that is cal

Re: [aspectj-users] AspectJ at Github

2020-08-14 Thread Andy Clement
uld produce nicer and more concise names and URLs. > > Greetings > Lars Grefer > > > Am 2020-07-31 17:23, schrieb Andy Clement: > > Up until yesterday what was on Github was a mirror for AspectJ. This meant > you couldn't raise issues against it (you had to go back to

Re: [aspectj-users] AspectJ at Github

2020-08-14 Thread Andy Clement
er/bugzilla2github.py > [4] https://stackoverflow.com/q/7281304/1082681 > > -- > Alexander Kriegisch > https://scrum-master.de > > > Andy Clement schrieb am 02.08.2020 07:09 (GMT +07:00): > > > > > > I didn't dive into the details with the webmaster (

Re: [aspectj-users] AspectJ at Github

2020-08-01 Thread Andy Clement
In any case Bugzilla > could stay active in a read-only mode. > > Having said that and reading it again, it sounds way more difficult than > just migrating the Git repo. > > Best regards > -- > Alexander Kriegisch > https://scrum-master.de > > > Andy Clement sch

[aspectj-users] AspectJ at Github

2020-07-31 Thread Andy Clement
Up until yesterday what was on Github was a mirror for AspectJ. This meant you couldn't raise issues against it (you had to go back to bugzilla), also any PRs that were submitted were very difficult to handle because project committers couldn't process them easily. Today, the copy of aspectj at ht

Re: [aspectj-users] AspectJ 1.9.6 (Java14) released

2020-07-24 Thread Andy Clement
connection with AspectJ LTW. This could be a great step ahead for > Spring AOP with regard to making it more lightweight. > > Regards > -- > Alexander Kriegisch > https://scrum-master.de > > > Andy Clement schrieb am 23.07.2020 03:01 (GMT +07:00): > > > &

[aspectj-users] AspectJ 1.9.6 (Java14) released

2020-07-22 Thread Andy Clement
Slightly later than I intended, AspectJ 1.9.6 is now available! It includes support for Java14. There is a small example using the new Record syntax in the readme: https://www.eclipse.org/aspectj/doc/released/README-196.html One of the key issues fixed here was an intermittent verify error during

Re: [aspectj-users] Can I force around advice (especially for constructors) to be inlined?

2020-05-29 Thread Andy Clement
ts later. > > -- > Alexander Kriegisch > https://scrum-master.de > > > Andy Clement schrieb am 29.05.2020 02:54 (GMT +07:00): > > This was a deliberate decision back in the day, not to inline. By keeping > them separate you could iterate on the aspect (change the advi

Re: [aspectj-users] Can I force around advice (especially for constructors) to be inlined?

2020-05-28 Thread Andy Clement
This was a deliberate decision back in the day, not to inline. By keeping them separate you could iterate on the aspect (change the advice) without needing to rebuild the whole system. It also, initially, was necessary to enable debugging to work properly because the mapping attributes weren't pos

Re: [aspectj-users] Support for java 14

2020-04-21 Thread Andy Clement
ution(String Person.toString()) Person[firstName=A, lastName=B, age=99] execution(String Person.firstName()) A cheers, Andy On Tue, 14 Apr 2020 at 17:07, Andy Clement wrote: > Damn, someone noticed 14 was out :) I hope to get to it in April. Out of > interest are there any particular f

Re: [aspectj-users] Support for java 14

2020-04-14 Thread Andy Clement
Damn, someone noticed 14 was out :) I hope to get to it in April. Out of interest are there any particular features you need from that version of Java? cheers, Andy On Tue, 14 Apr 2020 at 06:39, Ihor Mochurad wrote: > I would like to know the answer to this question as well as my > organizatio

Re: [aspectj-users] LTW and JRE classes

2020-04-06 Thread Andy Clement
Actually there does not seem to be any specific debug > > logging for names of attached classloaders at all, I only indirectly > > see things like "[AppClassLoader@18b4aac2] debug not weaving > > 'a.b..C'". > > > > > > Andy Clement: > > >

Re: [aspectj-users] Failing unit test that worked with java 1.8 is failing with java 11 using aspectj

2020-03-30 Thread Andy Clement
Hey, Yes, both those bugs are fixed. They both relate to fields created by AspectJ infrastructure. The difference with this one is that it is a field whose access is dictated by the JVM/Javac. It may not be quite as trivial because removing 'final' from the serialVersionUID (I presume you are ask

Re: [aspectj-users] LTW and JRE classes

2020-03-30 Thread Andy Clement
> https://github.com/eclipse/org.aspectj/tree/master/tests/features160/weavingJavaxPackage > > I really need some help to get started here. > -- > Alexander Kriegisch > https://scrum-master.de > > > Andy Clement schrieb am 28.03.2020 00:51 (GMT +07:00): > > > >

Re: [aspectj-users] LTW and JRE classes

2020-03-27 Thread Andy Clement
I feel like they used to work but there were gotchas. For example the JVM loads up some types before the LTW infrastructure can even get involved and those can't be woven. I don't actually recall if we have testcases for this but I wouldn't be surprised if they weren't there. I guess you have trie

Re: [aspectj-users] AspectJ 1.9.5 (Java13) released

2020-02-05 Thread Andy Clement
Hi, The latest update site contents here: http://download.eclipse.org/tools/ajdt/410/dev/update Now include AspectJ 1.9.6 build snapshot today (so all the 1.9.5 changes). I know the version tag on the OSGi bundles mention 1.9.2 but trying to change that to 1.9.6 I just broke everything so I rever

Re: [aspectj-users] @DeclareParents with 'defaultImpl' not working when used in an aspect library

2020-01-02 Thread Andy Clement
I'll have a look when I get a chance. cheers! Andy On Mon, 30 Dec 2019 at 18:37, Alexander Kriegisch wrote: > Hi Andy! > > Please check out https://stackoverflow.com/a/59538952/1082681 (there is > also a GitHub link) and tell me if it makes sense to file a bug ticket > or you won't fix it anywa

[aspectj-users] AspectJ 1.9.5 (Java13) released

2019-11-28 Thread Andy Clement
AspectJ 1.9.5 is now available. It includes support for Java13. There is a small example using the new text blocks in the readme: https://www.eclipse.org/aspectj/doc/released/README-195.html Perhaps the most important fix in here relates to applying multiple annotation style around advices on the

Re: [aspectj-users] Where is AJDT release build for eclipse 2019-06/4.12?

2019-09-16 Thread Andy Clement
Hmmm, right now they tend to be done as requested as I can't quite keep up :) But it may just be the metadata in the marketplace entry - have you tried just using the AJDT build from the dev update site? http://download.eclipse.org/tools/ajdt/410/dev/update ? (I know it says 410 but I think its wh

Re: [aspectj-users] AJDT does not include aop.xml into output JAR

2019-06-19 Thread Andy Clement
I couldn't honestly tell you if that used to work. Feel free to raise a bug, but I can't tell you it'd be at the top of my list ;) PRs welcome! Andy On Mon, 17 Jun 2019 at 20:05, Alexander Kriegisch wrote: > I just opened one of my old LTW projects in Eclipse with current AJDT. I > have src/MET

Re: [aspectj-users] Upgrade AspectJ Maven plugin to Java 11 (AspectJ 1.9.4)

2019-06-04 Thread Andy Clement
Thanks for mentioning that, I keep forgetting it. Wish I had the cycles to sort that out, but I just can't seem to manage it. I am happy to support anyone who does though! cheers, Andy On Fri, 31 May 2019 at 21:44, Alexander Kriegisch wrote: > I know that this mailing list is not for the AJM pl

Re: [aspectj-users] 1.9.4 released

2019-05-31 Thread Andy Clement
Hmm, I feel like it might be saying that but it isn't true, since I tested the IDE fixes 1.9.4 includes. So maybe the version stamp didn't get updated correctly for the artifact (to 1.9.4 from 1.9.2). I'll fix that up next time I do an update. Unless someone tells me the IDE fixes aren't in fact i

Re: [aspectj-users] Formal support for Kotlin?

2019-05-15 Thread Andy Clement
Yeah, feel free to create one, we should have a place to collect comments/feedback. cheers, Andy On Tue, 14 May 2019 at 14:32, Matthew Adams wrote: > Understood, Andy. Should I create an issue so that we can track this? > > On May 14, 2019, at 10:14 AM, Andy Clement > wrote:

Re: [aspectj-users] Formal support for Kotlin?

2019-05-14 Thread Andy Clement
I would probably need to see a lot of demand before exploring an ajc like experience for Kotlin. It would be a very large amount of effort and binary weaving of the class files can get you a long way. If I had cycles to work on the compile time experience I'd probably prefer to put that into improv

Re: [aspectj-users] JDK 12 support?

2019-03-04 Thread Andy Clement
I am hoping to get a 1.9.3 out very shortly, but that won't be Java12 compatible. If JDT is up to date I can get something out pretty quickly for Java12 I imagine. Changing the syntax is always a little annoying as I have to remerge and regenerate the parser, and the new syntax around switch expres

Re: [aspectj-users] ITD for type patterns, not just exact types

2019-01-25 Thread Andy Clement
On one hand it is resources, but I also think if you asked me to implement ITDs today from scratch I wouldn’t do it in the same way anymore. Adding new features that also extend use of that model I don’t like don’t get me excited (especially when they result in me hacking JDT with more dirty change

Re: [aspectj-users] Warning when using lombok's with aspectj

2019-01-25 Thread Andy Clement
I haven't done much investigation work into the combination. If you do it in two steps you'd be fine (Lombok then binary weave) but that won't work if you are doing static introductions from aspects that you need around for your code to compile in the first place. If you tweaked Lombok to additiona

Re: [aspectj-users] Generate ajdoc for site

2018-12-14 Thread Andy Clement
> *${java.version} * > > ** > > ** > > * * > > * * > > * aspectj-report * > > * * > > * * > > ** > * * > ** > > br, > > //mike > > > > > -- >

Re: [aspectj-users] Generate ajdoc for site

2018-11-28 Thread Andy Clement
ajdoc is the one area of AspectJ I don't really know much about, other than trying to keep it limping along as Java versions update. Have you tried running ajdoc on the command line, does it do the right thing? If so then we know ajdoc is at least ok and we just have to work out the right XML inca

Re: [aspectj-users] Pointcut parser skips superfluous closing parenthesis and everything that follows

2018-11-28 Thread Andy Clement
You know I feel like I've seen that before, and done the same debugging you did. It may even be an open issue on Spring AOP. I don't mind a ticket to make us a little more strict there. cheers, Andy. On Sun, 25 Nov 2018 at 01:53, Alexander Kriegisch wrote: > Hi Andy. > > I found something on SO

Re: [aspectj-users] Tips about AspectJ and Java Module System to improve modularity

2018-11-01 Thread Andy Clement
Hey! Honestly the big hurdle with AspectJ 1.9.0 was just to support the module system, i.e. how they had repackaged the JDK. There are many things we could do, but haven't found the bandwidth yet. The faster release cadence for the JDK means we seem to be spending more time just keeping up (see th

Re: [aspectj-users] [WARNING] can not build thisJoinPoint lazily for this advice since it has no suitable guard

2018-10-26 Thread Andy Clement
You could use an lint option to turn that off. See https://www.baeldung.com/aspectj where he uses: ignore Andy On Fri, 26 Oct 2018 at 01:08, Mikael Petterson wrote: > Hi Andy! > > I managed to solve the test compilation problem for my aspect using > stackoverflow 😊 > > Now when I comp

Re: [aspectj-users] Aspect enabled

2018-10-23 Thread Andy Clement
Hi Mikael, In order to support the woven advice at runtime, there are a few types you need to have around. For this reason when you run your woven app you should also include the small aspectjrt.jar (aspectj runtime). It defines some common types like exception types that AspectJ might throw. If

Re: [aspectj-users] Java 11 Compatibility check: AspectJ

2018-10-15 Thread Andy Clement
k I'm good to cut this RC3, if that goes ok then final in a few days. Andy On Mon, 15 Oct 2018 at 03:47, Lubo Pecho wrote: > Hello, when do you expect to release final version of 1.9.2. Or have I > missed something? > > On Tue, Oct 2, 2018 at 6:44 AM Andy Clement > wrote:

Re: [aspectj-users] Java 11 Compatibility check: AspectJ

2018-10-01 Thread Andy Clement
fixes related to the new nest based access control attributes in JDK11 ( http://openjdk.java.net/jeps/181 <http://openjdk.java.net/jeps/181> ). cheers, Andy > On Oct 1, 2018, at 9:48 AM, Andy Clement wrote: > > Hey, > > I was tied up at Spring One last week, not to mention

Re: [aspectj-users] Java 11 Compatibility check: AspectJ

2018-10-01 Thread Andy Clement
Hey, I was tied up at Spring One last week, not to mention my laptop broke. I’m now back in the office and I hope to further polish up 1.9.2 this week. I will get the RC into maven central first so those that want to consume it can kick the tires on it that way. Yes, the ClassNotFoundException

Re: [aspectj-users] Java 11 Compatibility check: AspectJ

2018-09-13 Thread Andy Clement
Hey Michael, I will try to get some kind of build together before end of next week when I head to Spring One. If that goes well an initial release could be end of the month. It should just be an update to the latest Eclipse JDT that supports it - this is quite a mechanical process. If there aren't

Re: [aspectj-users] Debug aspect

2018-08-21 Thread Andy Clement
Looking at your zip the AccessingDeprecatedMethodTest.class isn’t woven with the aspect, were you expecting that particular class to be woven? The message ‘woven class’ means “this class has been through the weaver”, not that it has been modified. Using something like the showWeaveInfo option wi

Re: [aspectj-users] Can't compile in IntelliJ with OpenJDK 9

2018-08-20 Thread Andy Clement
I expect this is an issue about finding the jar containing Object. It is located a little differently on Java9 but given that your Ant builds works fine with OpenJDK9 (I presume the same 9.0.7.1), hmm. I might be able to add some diagnostics to a AJ9 build that would tell us where it is having trou

Re: [aspectj-users] Java 11 Compatibility check: AspectJ

2018-08-20 Thread Andy Clement
1. Library Name: AspectJ 2. Latest version: 1.9.1 3. Latest version Is the library compatible with Java 11 Compatible? (Y/N) 4. Is the library supported with Java 11? (Y/N) 5. (If “N” in compatibility or support) What is the versions that would be compatible and Supported? 6. Date of suppo

Re: [aspectj-users] AspectJ Compiler 1.8.10 errors out on wrong classpath

2018-08-20 Thread Andy Clement
Sorry for the late reply, I was on vacation. > b) Why was this behavior changed and when? Recently class path handling needed a lot of work in AspectJ because of module support (so supporting Java9). We had to start embracing more of the JDT processing of class path entries rather than doing our

Re: [aspectj-users] Incorrect Code Generation on 1.9.1

2018-07-31 Thread Andy Clement
Did you mean to apply your within condition to all of those call pointcuts? Right now your pointcut reads: within && call || call || call || call || call || call and because && is higher precedence than || then your within() restriction only applies to the first call. It says "I'm interested i

Re: [aspectj-users] weave all methods in rt.jar

2018-07-30 Thread Andy Clement
I think you have to take a little care when weaving rt.jar - for example if your advice uses types you will be weaving then you will end up in a loop (the advice gets called, calls back into the type you advised, which in turns calls back into the advice, etc, etc). It might be the java/lang/Object

Re: [aspectj-users] Plans to support Java 11

2018-07-26 Thread Andy Clement
Hey, Yep, 1.9.1 supports Java 10, we'll need an upgrade for Java11. When I do the next Eclipse JDT compiler upgrade I think I'll be picking that up, in the not too distant future (likely few weeks as we are getting due a 1.9.2 that includes some other fixes too). cheers, Andy On Thu, 26 Jul 2018

Re: [aspectj-users] Are there conflicts using LTW and CTW in the same application?

2018-06-14 Thread Andy Clement
see if I can exclude it by type instead of by > class name. I'm guessing I could simply exclude it by the @Aspect > annotation? > > > > Do I need to file a bug for this? > > Thanks, > > Eric > > > On Wed, Jun 13, 2018 at 4:08 PM, Andy Clement > w

Re: [aspectj-users] Are there conflicts using LTW and CTW in the same application?

2018-06-13 Thread Andy Clement
) - everything fine. The minute I switched it to annotation style, exactly the same problem as you. Andy > On Jun 13, 2018, at 12:43 PM, Andy Clement wrote: > > Let me try to interpret this from what I remember: > > >> 2018-06-12 10:21:52,079 ERROR [stderr] [ModuleClassL

Re: [aspectj-users] Are there conflicts using LTW and CTW in the same application?

2018-06-13 Thread Andy Clement
Loader@2d758982] info > processing reweavable type > org.webapp.sso.keycloak.aspect.ClientErrorExceptionHandler: > org\webapp.sso\keycloak\aspect\ClientErrorExceptionHandler.java > 2018-06-12 10:21:52,093 ERROR [stderr] [ModuleClassLoader@2d758982] error > aspect 'org.webapp.sso

Re: [aspectj-users] Are there conflicts using LTW and CTW in the same application?

2018-06-11 Thread Andy Clement
By default if you weave aspects on top of aspects then we use a model where we revert to the original class file before the first set of aspects was applied and apply all of them (the original aspects plus the new ones) at the same time to ensure consistency. This behavior is configurable using the

Re: [aspectj-users] I can not get the correct line number

2018-06-06 Thread Andy Clement
The reason this occurs is because after() returning advice is implemented by forwarding all ‘return’ byte codes through to the end of a method where some generated code is created to call the advice, then the actual return occurs: 0: getstatic #24 // Field instance:L

Re: [aspectj-users] Met [org.aspectj.lang.NoAspectBoundException] while running a post-compile woven (bytecode woven) apache thrift library

2018-05-25 Thread Andy Clement
e (the auto raising of visibility is not unusual, we do it for other reasons at times). cheers, Andy > On May 24, 2018, at 10:14 AM, Andy Clement wrote: > > I think there is a visibility issue here - the creation of the aspect fails > because in trying to create it we use refl

Re: [aspectj-users] Met [org.aspectj.lang.NoAspectBoundException] while running a post-compile woven (bytecode woven) apache thrift library

2018-05-24 Thread Andy Clement
> that the inner class you want to instrument in the library is non-public. > To be exact, it is a private, non-static inner class. But what really > matters is that it is anything but public/protected, static or not is not > so important. > > To Andy Clement: Maybe this is a

[aspectj-users] AspectJ 1.9.1 released

2018-04-20 Thread Andy Clement
AspectJ 1.9.1 is released. We are still working out how best to support the new rapid release plan for Java, where many of the frequent releases are not long term support releases (Java10 ends public updates in Sep 2018). Just to try and stay up to date with Java functionality, AspectJ 1.9.1 a

Re: [aspectj-users] How to turn off Xlint messages in OSGi LTW

2018-04-18 Thread Andy Clement
press warn/lint messages? > > Cheers > > > On Wed, Apr 18, 2018 at 1:09 AM, Andy Clement <mailto:andrew.clem...@gmail.com>> wrote: > I thought there was something in for that but I can't find it! > > There is a property for pointing at a file URL that is

Re: [aspectj-users] How to turn off Xlint messages in OSGi LTW

2018-04-17 Thread Andy Clement
I thought there was something in for that but I can't find it! There is a property for pointing at a file URL that is your config file (aop.xml): org.aspectj.weaver.loadtime.configuration But I'm not 100% sure how the class loader model under OSGi interferes with the code that checks that prope

[aspectj-users] AspectJ 1.9.0 released

2018-04-02 Thread Andy Clement
AspectJ 1.9.0 is finally released, after multiple betas and release candidates. The README can be found here: https://eclipse.org/aspectj/doc/released/README-190.html - thanks to everyone in the community who provided feedback, sample c

Re: [aspectj-users] How to use ajdoc generate Android Project doc?

2018-03-14 Thread Andy Clement
I’ve not used ajdoc in ages - this might be a good question for stackoverflow? Andy > On Mar 14, 2018, at 8:58 AM, zn z wrote: > > Hello, guys. > > When I want to generate android library doc that depends on aspects, I get > error > > Anyone know to use ajdoc or javadoc to generate doc of an

Re: [aspectj-users] Compile-time signature

2018-03-12 Thread Andy Clement
it out, let me know how it goes. I’d be interested in the impact on startup time and on size of the built artifacts. cheers, Andy > On Feb 26, 2018, at 11:59 AM, Fabian Bergmark > wrote: > > Ok! Yes sure! > > On Feb 26, 2018 20:31, "Andy Clement" <mailto:a

Re: [aspectj-users] Compile-time signature

2018-02-26 Thread Andy Clement
, Andy > On Feb 26, 2018, at 4:41 AM, Fabian Bergmark > wrote: > > Any progress? > > Cheers, > Fabian > > 2018-01-10 19:48 GMT+01:00 Andy Clement : >> The proper optimization here is to use the LDC byte code that takes a >> constant class, rather than th

Re: [aspectj-users] Compile-time signature

2018-01-10 Thread Andy Clement
The proper optimization here is to use the LDC byte code that takes a constant class, rather than the string variant and then class loading. The original AspectJ used the string form because LDC didn't take a class originally. Over the years a few places have been updated but not everywhere ( this

Re: [aspectj-users] Java 8 type annotations

2018-01-03 Thread Andy Clement
There is no AspectJ support for matching on type annotations right now. You could use a declare @type and then match on annotations: aspect X { // If a member has @Anno, stick @Anno on the type declare @type: hasmethod(@Anno * *(..)): @Anno; // If the type has @anno, adv

Re: [aspectj-users] relocation of aspectj classes in a java agent

2018-01-03 Thread Andy Clement
That’s an interesting requirement. I don’t know of others doing that but it isn’t totally unreasonable. I’ve normally used jarjar to move packages, I wonder if there is a variant of that tool which also allows string replacement. It seems reasonably robust to modify Lorg/aspectj/lang prefixed s

Re: [aspectj-users] The constructor DeprecatedMethodLogger() is not visible when testing my aspect

2018-01-03 Thread Andy Clement
Typically you don’t instantiate aspects like that, their lifecycle is managed more internally to the aspect and can vary depending on the per-scope. (The default scope being singleton) If you want an instance of an aspect, you’d call: DeprecatedMethodLogger.aspectOf() and this will give you t

Re: [aspectj-users] Accidental Debug Print within the AspectJ 1.8.12 release?

2018-01-03 Thread Andy Clement
Good catch !! I had a dig around thinking they were something that crept in recently but it turns out they have been there a year or so (since last jdt upgrade). Usually tests pick those things up because we have tests that look for particular output and trip over extraneous output but it looks

Re: [aspectj-users] ajc 1.8.10 fails with JDK9

2018-01-03 Thread Andy Clement
yep. On 17 December 2017 at 09:26, Bogus Abuser wrote: > Btw, can I use AspectJ 1.9 with JDK 8? > > Thanks. > > On Fri, Dec 15, 2017 at 7:11 PM, Bogus Abuser > wrote: > >> I see, thank you! >> >> On Thu, Dec 14, 2017 at 9:22 PM, Andy Clement >> w

Re: [aspectj-users] ajc 1.8.10 fails with JDK9

2017-12-14 Thread Andy Clement
For compilation/weaving of stuff on JDK9 you should use the 1.9.0 RC2 that is out. This is what Spring Framework is using to compile its aspects code. 1.8 releases (1.8.13) can be used on JDK9 for simple situations like Spring AOP that is doing pointcut parsing/matching but isn't digging into type

Re: [aspectj-users] ajc issues with interfaces using generics

2017-11-02 Thread Andy Clement
PSHOT to > make it to release? > > On Wed, Nov 1, 2017 at 3:25 PM, Andy Clement > wrote: > >> It is fixed up. It was the order of processing as suspected, it can also >> vary on the same OS ( I can make it fail on my mac by passing A last ). >> >> Because orderin

Re: [aspectj-users] ajc issues with interfaces using generics

2017-11-01 Thread Andy Clement
a Mac > (using the Maven project) and I get the compilation error. > > On Wed, Nov 1, 2017 at 10:59 AM, Andy Clement <mailto:andrew.clem...@gmail.com>> wrote: > Thanks for the test project. It compiled fine for me on Mac but then I > thought I’d try windows and sur

Re: [aspectj-users] ajc issues with interfaces using generics

2017-11-01 Thread Andy Clement
if you are able to reproduce. Thanks! > > Jason > > On Tue, Oct 31, 2017 at 1:19 PM, Andy Clement <mailto:andrew.clem...@gmail.com>> wrote: > I recall in the early days of AspectJ 5 we had a mountain of issues like > this, but I thought they’d all been ironed out ! >

Re: [aspectj-users] ajc issues with interfaces using generics

2017-10-31 Thread Andy Clement
I recall in the early days of AspectJ 5 we had a mountain of issues like this, but I thought they’d all been ironed out ! Hmm, I guess there must be a little more to it, here are my source files that simulate what you wrote: --- import java.util.*; interface A { T setInputs(List inputs)

Re: [aspectj-users] How to ensure AspectJ aspects are LTW'ed by Wildfly's modules?

2017-10-26 Thread Andy Clement
in the cycle the > instrumentation is called when loading classes. Do you know if there are any > docs or whitepapers I can read up on how the classloader/instrumentation > cycle works? I couldn't find enough clarity on the Oracle site. > > Thanks, > > Eric > &

Re: [aspectj-users] How to ensure AspectJ aspects are LTW'ed by Wildfly's modules?

2017-10-26 Thread Andy Clement
used instead? On the > other hand, if the base java classloader is passed, why is the classloader > not able to find my test.aspectj.TestAspect class if it is in the jar that is > part of my -cp arguments? > > > Thanks, > > Eric > > On Mon, Oct 23, 2017 at 1:45 PM

Re: [aspectj-users] adding interface to classes in jars that already have interface implementation

2017-10-26 Thread Andy Clement
Hey, So sorry! I noticed I wrote this the other day but have left it in draft, finally sending now... What you are doing looks OK but as you surmise your new code will only work if the aspect has had a chance to apply. Let’s step through it. I’ll use real code: === 8< A.java == publ

Re: [aspectj-users] How to ensure AspectJ aspects are LTW'ed by Wildfly's modules?

2017-10-23 Thread Andy Clement
Yes, it is a bit specific to wildfly but I can talk to what AspectJ does. I will also call out to an old article I wrote on debugging LTW: http://andrewclement.blogspot.ca/2009/02/load-time-weaving-basics.html (might be u

[aspectj-users] AspectJ 1.8.12 and AspectJ 1.9.0.rc1 released

2017-10-21 Thread Andy Clement
Both AspectJ 1.8.12 and 1.9.0.rc1 have been released. 1.8.12 includes some slightly radical improvements that impact Spring AOP performance. The README has more details: https://www.eclipse.org/aspectj/doc/released/README-1812.html

Re: [aspectj-users] Aspectjweaver.jar outputting on stderr vs stdout

2017-10-21 Thread Andy Clement
PM, Eric B <mailto:ebenza...@gmail.com>> wrote: > Ok - thanks for the confirmation. I will have to let the team know that all > ERROR logs are not actual ERROR logs, but only INFO logs. > > Eric > > On Thu, Oct 6, 2016 at 3:26 PM, Andy Clement <mailto:andrew.clem...@

Re: [aspectj-users] Missing stackmap generation for woven code

2017-10-12 Thread Andy Clement
I can leverage it for my own use > case. > > Also, please let me know if the Error that I am seeing is a bug in AJ, or > expected behaviour. Do you need me to open a ticket for that? > > Thanks, > > Eric > > > On Tue, Oct 10, 2017 at 3:34 PM, Andy Clement > wrot

Re: [aspectj-users] Missing stackmap generation for woven code

2017-10-10 Thread Andy Clement
The very basic visitor AspectJ uses is here: https://github.com/eclipse/org.aspectj/blob/6d6738cfece6328027916681e67e54225531db38/weaver/src/org/aspectj/weaver/bcel/asm/StackMapAdder.java cheers, Andy On 10 October 2017 at 12:32, Andy Clement wrote: > Hey Eric, > > The error above is

Re: [aspectj-users] Missing stackmap generation for woven code

2017-10-10 Thread Andy Clement
Hey Eric, The error above is saying it can't find the asm rather than that there is an issue with missing stack maps. Although possibly the error is occurring because as a side effect of the missing stack maps, I'd need to check. > Are there libraries to manipulate/generate a stackmap? This is e

Re: [aspectj-users] How to get the enclosing class in a Pointcut

2017-09-26 Thread Andy Clement
or my Demo test. > > I execute it using a suite file that I have pointed out in Eclipse. > > Is there anything that is different if I execute from within Eclipse? > > br, > > //mikael > > > > > > > Från: Andy Clement <mailto:andrew.clem

Re: [aspectj-users] Plans for 1.9.0 release

2017-09-26 Thread Andy Clement
tatic final String[] COMPLIANCE_INPUTS = new String[] { "-1.3", > "-1.4", "-1.5", "-1.6", "-1.7", "-1.8", "1.9" }; > + static final String[] COMPLIANCE_INPUTS = new String[] { "-1.3", > "-1.4"

Re: [aspectj-users] Plans for 1.9.0 release

2017-09-25 Thread Andy Clement
Hey, 1.9.0.BETA-7 is actually there now (spring milestones maven repo), published last night.This includes: - update to latest JDT compiler - Compilation/weaving performance on Java 9 now similar to Java8. I am trying to get to an RC very soon but there are a few more things I must do before I co

Re: [aspectj-users] How to get the enclosing class in a Pointcut

2017-09-22 Thread Andy Clement
Hey, hope you get this email :) Here is a complete program: 8< 8< Demo.java = public class Demo { public static void main(String []argv) { new Demo().test(); } public void test() { Node node = new Node(); Handler handler = node.getObjectHandler(); //g

Re: [aspectj-users] How to get the enclosing class in a Pointcut

2017-09-19 Thread Andy Clement
Just want to 100% understand your requirement: > I want to find which classes and methods outside our application that calls > to our application classes with public methods that has annotation > @Deprecated. You want to find calls to your API *from* code marked @Deprecated or you want to fin

Re: [aspectj-users] AspectJ Future

2017-09-12 Thread Andy Clement
Hey, I have to admit I'm not trying it on a daily basis but I thought AJDT was OK - is the message you posted "Space to find context alternatives for annotations." an indication of the error you are seeing? Doesn't sound familiar to me. As soon as I clear some space on my TODO list I am tackling

Re: [aspectj-users] Errors while switching from load time weaving to compile time weaving using aspectj

2017-07-19 Thread Andy Clement
I’ll prefix this with I’m no maven expert :) You don’t seem to be specifying the version of the AspectJ compiler to use so I wonder if it is defaulting to a lower version. On here: http://www.mojohaus.org/aspectj-maven-plugin/usage.html

Re: [aspectj-users] Do cflow targets need to be woven?

2017-04-25 Thread Andy Clement
Yes, the cflow target is woven to indicate 'this cflow is being entered' then at the real target place to weave it is a very simple/quick check to see 'are we in the cflow?'. There would be a less optimal implementation that looks at the stack trace at the actual join point target but we've never i

Re: [aspectj-users] How to weave JDK classes with AspectJ

2017-03-22 Thread Andy Clement
eem hard to implement, > but I could be wrong. > -- > Alexander Kriegisch > https://scrum-master.de > > > Andy Clement schrieb am 22.03.2017 17:07: > > > I see it :) Thanks for pulling this resource together that I can point > > people at. > > > > >

Re: [aspectj-users] How to weave JDK classes with AspectJ

2017-03-22 Thread Andy Clement
I see it :) Thanks for pulling this resource together that I can point people at. cheers Andy > On Mar 22, 2017, at 8:17 AM, Alexander Kriegisch > wrote: > > Hi Andy. > > Especially for you I added this remark: > https://github.com/kriegaex/SO_AJ_MavenWeaveJDK#possible-improvements > > ;-)

  1   2   3   4   5   6   7   8   9   10   >