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

2017-09-21 Thread Frank Pavageau
2017-09-21 9:46 GMT+02:00 Mikael Petterson : > So no input on this one? > Yes, Andy answered on the list itself : https://dev.eclipse.org/mhonarc/lists/aspectj-users/msg15087.html Regards, Frank ___ aspectj-users mailing

Re: [aspectj-users] AspectJ is not intercepting `collect` call

2015-09-09 Thread Frank Pavageau
Hi. 2015-09-09 12:04 GMT+02:00 xeonmailinglist : > [2] My mapreduce aspects > > > package org.apache.hadoop.mapred.aspects; > > import org.aspectj.lang.JoinPoint; > import org.aspectj.lang.annotation.Aspect; > import org.aspectj.lang.annotation.Before; > > @Aspect >

Re: [aspectj-users] How to weave the method calls inside an war file?

2015-09-08 Thread Frank Pavageau
First of all, wars are isolated from each other by the server (using classloaders), so one application cannot change the way another one behaves. Anyway, the weaving needs to happen before the code actually starts running, either at compile time or when the classes are loaded (load-time weaving),

Re: [aspectj-users] Problem in my first aspectJ

2015-09-07 Thread Frank Pavageau
You're trying to use the AspectJ integration in Spring -- usually called Spring AOP -- without actually using Spring in your program, which is just a class with a main. You should either use AspectJ directly (by compiling with ajc) or create a full-blown Spring application where the advised class

Re: [aspectj-users] Improving the pointcut matching?

2015-08-06 Thread Frank Pavageau
you. cheers, Andy On Aug 5, 2015, at 2:40 PM, Frank Pavageau frank.pavag...@gmail.com wrote: Hi. I was debugging an application using Spring AOP to find out why a class was proxied despite not actually matching the pointcut, and found out that KindedPointcut.fastMatch() would only

Re: [aspectj-users] Stackmap frame errors when building the aspectj project with Java 1.7

2014-10-14 Thread Frank Pavageau
2014-10-14 21:28 GMT+02:00 Andy Clement andrew.clem...@gmail.com: I’d recommend updating to a more recent AspectJ. Older AspectJs did have issues with making mistakes generating stack map frames. The option to use split verifier was only possible with JDK1.6 I think, with 1.7 they removed

Re: [aspectj-users] Compiling java-7 code with jdk-8

2014-05-14 Thread Frank Pavageau
Hi Jonas. 2014-05-14 12:48 GMT+02:00 Jonas Trollvik jon...@gmail.com: With aspectjrt versions of 1.8.0 I get a lot of error messages like the following: [ERROR] The type new ComparatorFileEntry(){} must implement the inherited abstract method ComparatorFileEntry.thenComparing(Function?

Re: [aspectj-users] Compiling java-7 code with jdk-8

2014-05-14 Thread Frank Pavageau
2014-05-14 13:34 GMT+02:00 Jonas Trollvik jon...@gmail.com: Sorry, I just saw that the development build was very old (Didnt spot the 2013 in there) Will report back when I get a newer one. I built a local version of AspectJ to proceed with my JDK 8 / AspectJ 1.8 testing and can confirm it

Re: [aspectj-users] Compiling java-7 code with jdk-8

2014-05-14 Thread Frank Pavageau
2014-05-14 16:50 GMT+02:00 Jonas Trollvik jon...@gmail.com: However the message is still not gone. That's when building with JDK 8 and source=target=1.7, right? [ERROR] The type ModelRequestParameters must implement the inherited abstract method MapString,Object.replaceAll(BiFunction?

Re: [aspectj-users] Compiling java-7 code with jdk-8

2014-05-14 Thread Frank Pavageau
2014-05-14 16:47 GMT+02:00 Andy Clement andrew.clem...@gmail.com: The build process really ought to be cleaned, though... Couldn't agree more - and the whole build should be automated with snapshot uploads like it used to be. If anyone wants to help with cleaning up the build or

Re: [aspectj-users] Compiling java-7 code with jdk-8

2014-05-14 Thread Frank Pavageau
2014-05-14 17:56 GMT+02:00 Jonas Trollvik jon...@gmail.com: However the message is still not gone. That's when building with JDK 8 and source=target=1.7, right? Correct It compiles fine when using -1.8 instead of -1.7. I already reported

Re: [aspectj-users] identifying class not included in pointcut

2014-03-27 Thread Frank Pavageau
It's difficult to know that you're going through an unmodified method without modifying the method. I guess you could maintain a (thread-local) stack of the methods called (by using a call(* *(..)) pointcut) and verifying in the weaved methods (using a execution(* *(..)) pointcut) that it matches

Re: [aspectj-users] There is an AspectJ 1.8.0.RC1 available !

2014-03-19 Thread Frank Pavageau
Great! Thank you Andy. It has apparently fixed https://bugs.eclipse.org/bugs/show_bug.cgi?id=416146. I'd really welcome a deployment in Maven Central so I can resume my CI builds using JDK 8 and AspectJ 1.8, and report any additional problems I find. Frank 2014-03-19 6:57 GMT+01:00 Andy

Re: [aspectj-users] Error in advising test class being executed via JUnit test suite

2013-10-12 Thread Frank Pavageau
Hi. This happens with the HotSpot JVM from JDK 7 when it uses its new stack verifier. You can disable it with the -XX:-UseSplitVerifier JVM parameter. Frank Le 12 oct. 2013 00:36, Arata Yamamoto art...@gmail.com a écrit : Dear group, I would like to ask whether someone knows the work around

Re: [aspectj-users] Handle Unable to pack method, jump in aspectj

2013-09-13 Thread Frank Pavageau
2013/9/13 Krishna Jasty krishna.ja...@tcs.com I will work on the method, which is bigger in size and causing this error. I can try to split the single big method into several small pieces. Meanwhile these exceptions are very common in my application though the aspectj instrumentation is very

Re: [aspectj-users] Handle Unable to pack method, jump in aspectj

2013-09-13 Thread Frank Pavageau
2013/9/13 Krishna Jasty krishna.ja...@tcs.com Thanks Frank for the update, //The byte code instructions are defined by the JVM specifications, it's not something AspectJ can change. See *

Re: [aspectj-users] How to introduce a really final member via ITD

2013-05-30 Thread Frank Pavageau
2013/5/30 Ivan Topolnjak ivant...@gmail.com I'm trying to find a way to introduce a member in another type via ITD but making sure it is safe published. According to the Java Memory Model, all final fields are guaranteed to be safe published after the constructor execution ends and everything

Re: [aspectj-users] Runtime Exceptions in After Throws

2012-12-06 Thread Frank Pavageau
2012/12/6 James Cook james.c...@plumbee.com after() throwing(MyRuntimeException ex) : call (* *(..)) [...] Is this down to how AspectJ inspects for which methods are eligible? In other words is this expected behaviour for RuntimeException child classes? Currently using 1.6.12 with Java

Re: [aspectj-users] matching all functions declared in a certain interface

2012-01-16 Thread Frank Pavageau
Hi. That's execution (void Interface1+.*(..)) (or execution (* Interface1+.*(..))). Your pointcut is missing the method. Frank On Sun, Jan 15, 2012 at 9:14 AM, Dénes Németh mr.nemeth.de...@gmail.com wrote: Hi How is it possible to match all functions declared in a certain interface without

Re: [aspectj-users] matching all functions declared in a certain interface

2012-01-16 Thread Frank Pavageau
declared in the Interfac1 interface. Best wishes, Denes 2012/1/16 Frank Pavageau frank.pavag...@gmail.com: Hi. That's execution (void Interface1+.*(..)) (or execution (* Interface1+.*(..))). Your pointcut is missing the method. Frank On Sun, Jan 15, 2012 at 9:14 AM, Dénes Németh

Re: [aspectj-users] static pointcut for super

2011-12-02 Thread Frank Pavageau
Hi Steve. On Fri, Dec 2, 2011 at 3:50 AM, Steve Ash stevem...@gmail.com wrote: I would like to create an aspect to declare an error if a particular method is called on the super from a subtype.  Something like: public class SuperClass {    public final void dontCallThisFromBase() { } }

Re: [aspectj-users] Catch-all pointcut

2011-04-11 Thread Frank Pavageau
On Mon, Apr 11, 2011 at 11:23 AM, Tiago Espinha ti...@apache.org wrote: Assume I have two jars: - RunnableFile.jar - Library.jar The RunnableFile.jar is a runnable jar, contains a main method in one of its classes but it depends on Library.jar . This means that whenever I run the

Re: [aspectj-users] New feature of Aspectj 1.6.11

2010-12-14 Thread Frank Pavageau
Jean-Louis, why would adding / replacing @Foo remove @Bar at the same time, without an explicit -...@bar? I definitely want to have several annotations on the same field / method / whatever at the same time and only modify some of them :-) Frank On Tue, Dec 14, 2010 at 8:10 AM,

Re: [aspectj-users] aspectj joinpoint *for* Annotation ?

2010-11-23 Thread Frank Pavageau
Note that you can't modify an existing annotation, which would be quite useful in that context : changing the cache strategy between read-write and read-only for example (even if you have the source, different usage patterns can use different strategies on the same entities), or the fetching

Re: [aspectj-users] Strange error after upgrade to AspectJ 1.6.8

2010-07-20 Thread Frank Pavageau
Hi Andy, Hermann. It reminds me of my own https://bugs.eclipse.org/bugs/show_bug.cgi?id=303924 which was fixed with 1.6.9: ITD, reweaving (since compile and load-time weaving were mentionned) IncompatibleClassChangeError. Frank On Wed, Jul 21, 2010 at 12:35 AM, Andy Clement

Re: [aspectj-users] Re: another newbie question: avoid constructor calls .. !initialize ?

2010-07-14 Thread Frank Pavageau
It can be configured, as with most inspections in IntelliJ. When the cursor is on the keyword underlined in red (unsupported in Spring AOP), use Alt-Enter to access the inspection's setting (Spring AOP Errors) and either disable it or change its severity. Frank On Wed, Jul 14, 2010 at 8:02 AM,

[aspectj-users] Strange classloader interaction when weaving with aspectj-maven-plugin

2010-02-24 Thread Frank Pavageau
Hi. I have a weaving problem when using AspectJ 1.6.7 or 1.6.8 which doesn't happen with 1.6.6, but cannot extract a test case for. If someone has any suggestion for tracing the problem, maybe I'll be able to report the bug properly. I have a multi-module maven project : - in module1, I have an