Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-users] NoAspectBoundException with load time weaving

I have already figured out this problem but as I did not get any hits that
matched my dumb error I'm adding this for documentation purposes. This way
when I make the same mistake again I'll be able to search for and find this
posting. I hope this is OK.

My aop.xml was something like this,
   <weaver options="">
        <include within="com.mycorp.myproduct..*"/>
   </weaver>
but my aspect was like this,
   pointcut newInstance() : execution(*.new()); 
and I kept getting NoAspectBoundException


When I made the two "scopes" more closely match it started working fine,
i.e.,
   <weaver options="">
        <include within="com.mycorp.myproduct..*"/>
   </weaver>
and,
   pointcut newInstance() : execution(com.mycorp.myproduct.*.new()); 


This is probably documented somewhere but I have to admit I do struggle to
follow the docs at times.

-- 
View this message in context: http://www.nabble.com/NoAspectBoundException-with-load-time-weaving-tp14766033p14766033.html
Sent from the AspectJ - users mailing list archive at Nabble.com.



Back to the top