Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [ajdt-dev] strange exception problem

Hi Andy,

good bit of digging there.  that is quite a complex area of the code
*sigh* - it does seem the fix for that could be affecting you. Please
open a new bug and i'll try and create a testcase around your
description when I get a moment, unless you beat me to it.

Here we are:

https://bugs.eclipse.org/bugs/show_bug.cgi?id=230134

I attached the code for my three aspect hierarchy to the bug, maybe it helps.

Thanks for taking a look!

Cheers,
-Martin




cheers,
Andy.



2008/5/4 Martin Lippert <lippert@xxxxxxx>:
Hi Andy,

 I think I have found the problem, at least to some degree. I tried to debug
through the code for my setting and tried to find out what happened. As I am
not extremely familiar with the code base of the weaver in this depth I hope
my explanations and results are understandable and not complete crap...

 I think the problem is somehow introduced by the fix for this bug:

 https://bugs.eclipse.org/bugs/show_bug.cgi?id=223094

 When my aspect is registered to the weaver (addLibraryAspect) the method
"addLibraryAspect" calls itself second times for the both super types of my
aspect (HelloWorldTracing -> SimpleTracing -> Tracing).

 Everything seems to be fine (the crosscutting members list for the
HelloWorldTracing aspect contains the type munger for the cflow field
addition) until the third call to "addLibraryAspect".

 That calls "addOrReplaceDescandantsOf" for its direct descandant
(SimpleTracing) which then calls "addOrReplaceDescandantsOf" the next
descandant (HelloWorldTracing). After this call the type munger for the
cflow field is no longer inside the crosscutting members list and therefore
the cflow field is not added later on during weaving, I think.

 So far my analysis... Does this makes sense?

 Thanks for your help!
 -Martin








 Andy Clement wrote:

I had a quick look through from December until April 3rd


https://bugs.eclipse.org/bugs/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=AspectJ&long_desc_type=allwordssubstr&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&status_whiteboard_type=allwordssubstr&status_whiteboard=&keywords_type=allwords&keywords=&bug_status=RESOLVED&bug_status=VERIFIED&bug_status=CLOSED&emailtype1=substring&email1=&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=2007-12-01&chfieldto=2008-04-03&chfieldvalue=&cmdtype=doit&order=Reuse+same+sort+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0=
and can't immediately see anything that would introduce a regression
for you.  if you can show me a testcase, of course I'll take a look,

cheers,
Andy.

ps. if you get a chance, I'd be interested in getting you to try out
the weaver in https://bugs.eclipse.org/bugs/show_bug.cgi?id=210470 -
since it is meant to be much better behaved in terms of allowing
itself to be gc'd when the related classloader is orphaned.

2008/5/2 Andy Clement <andrew.clement@xxxxxxxxx>:

I can't think of a change, but there might be one.  You could check
 bugzilla for fixes committed between the dates of old and new (AspectJ
 build dates, not AJDT ones).

 Does it work if you let the aspects get woven?



 Andy.

 2008/5/2 Martin Lippert <lippert@xxxxxxx>:
 > Hi Andy,
 >
 >
 >
 > > I think it needs to weave the aspect where the cflow pointcut
occurs -
 > > but I'd need to double check.
 > >
 > > I don't believe the behaviour has changed, the only thing I added
 > > recently was an error message saying "you need to weave the aspect"
 > > which comes out with the cryptic cflowcounter message.  if you
aren't
 > > seeing that message then maybe your problem really is different.
 > >
 >
 >  Hm, this seems to be very interesting. I have a hierarchy of three
aspects
 > where the cflow pointcut is defined in the base class of this
hierarchy and
 > I decompiled all three classfiles after weaving. Noone contains a
field
 > definition for the cflow. Seems to me that my case might be indeed a
 > different one. Could any other change to the weaver code possibly
created
 > this problem? I am so puzzled because an older build worked fine...
 >
 >
 >
 >  -Martin
 >
 >
 >
 > >
 > > Andy
 > >
 > > 2008/5/2 Martin Lippert <lippert@xxxxxxx>:
 > >
 > > > Hi Andy,
 > > >
 > > >
 > > >
 > > >
 > > > > I've seen that if you exclude the aspect from being woven in
the XML
 > > > > configuration for ltw - we must be able to weave the aspect if
you are
 > > > > using cflow since it will have that field added to it.   See
bugs like
 > > > > https://bugs.eclipse.org/bugs/show_bug.cgi?id=166647
 > > > >
 > > > > Are you including the aspect in what can be woven?
 > > > >
 > > > >
 > > >  Thanks for the quick pointer to the bug. My issue seems to be
closely
 > > > related but also slightly different... ;-)
 > > >
 > > >  In my case I have an abstract aspect containing the cflow
pointcut and
 > a
 > > > concrete aspect inheriting from that aspect (so no aop.xml-based
 > concretized
 > > > aspect). And in my setting the abstract aspect seems to be
excluded from
 > > > weaving. Could that cause the problem? And has this behavior
changed
 > really
 > > > between the builds I mentioned? I just wanna be sure where the
problem
 > is to
 > > > find a good solution for my case... :-)
 > > >
 > > >  Thanks a lot for your help!
 > > >  -Martin
 > > >
 > > >
 > > >
 > > >
 > > >
 > > >
 > > >
 > > >
 > > >
 > > >
 > > > > Andy.
 > > > >
 > > > > 2008/5/2 Martin Lippert <lippert@xxxxxxx>:
 > > > >
 > > > >
 > > > > > Hi!
 > > > > >
 > > > > >  When using load-time weaving with AJDT 1.5.2 I get this
exception:
 > > > > >
 > > > > >  java.lang.NoSuchFieldError: ajc$cflowCounter$0
 > > > > >  (invoking a woven class)
 > > > > >
 > > > > >  I tried to track this down. Seems like this problem was
introduced
 > by
 > > > > >
 > > > >
 > > > build
 > > >
 > > > >
 > > > > > 1.5.2.200804031532 of AJDT. It worked well with the previous
build
 > > > > > 1.5.2.200801291327.
 > > > > >
 > > > > >  Any idea what is going on?
 > > > > >
 > > > > >  Thanks in advance!
 > > > > >  -Martin
 > > > > >
 > > > > >  _______________________________________________
 > > > > >  ajdt-dev mailing list
 > > > > >  ajdt-dev@xxxxxxxxxxx
 > > > > >  https://dev.eclipse.org/mailman/listinfo/ajdt-dev
 > > > > >
 > > > > >
 > > > > >
 > > > > _______________________________________________
 > > > > ajdt-dev mailing list
 > > > > ajdt-dev@xxxxxxxxxxx
 > > > > https://dev.eclipse.org/mailman/listinfo/ajdt-dev
 > > > >
 > > > >
 > > > >
 > > > >
 > > > >
 > > >  _______________________________________________
 > > >  ajdt-dev mailing list
 > > >  ajdt-dev@xxxxxxxxxxx
 > > >  https://dev.eclipse.org/mailman/listinfo/ajdt-dev
 > > >
 > > >
 > > _______________________________________________
 > > ajdt-dev mailing list
 > > ajdt-dev@xxxxxxxxxxx
 > > https://dev.eclipse.org/mailman/listinfo/ajdt-dev
 > >
 > >
 > >
 >
 >  _______________________________________________
 >  ajdt-dev mailing list
 >  ajdt-dev@xxxxxxxxxxx
 >  https://dev.eclipse.org/mailman/listinfo/ajdt-dev
 >


_______________________________________________
ajdt-dev mailing list
ajdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/ajdt-dev




 _______________________________________________
 ajdt-dev mailing list
 ajdt-dev@xxxxxxxxxxx
 https://dev.eclipse.org/mailman/listinfo/ajdt-dev

_______________________________________________
ajdt-dev mailing list
ajdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/ajdt-dev





Back to the top