Hi, <dump is not working for me at all. I am using 1.6.0.
Is there some special setup necessary to get dump to work? Bob -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andy Clement Sent: Monday, June 30, 2008 5:53 PM To: [email protected] Subject: Re: [aspectj-users] Exception in thread"main"java.lang.NoClassDefFoundError Hi, I've never seen a case of that before - and I've seen some pretty wierd stuff :) > Exception in thread "main" java.lang.NoClassDefFoundError > at $AllProbeAspect.aspectOf(Unknown Source) You could turn on weaveinfo messages and see if anywhere unexpected is getting woven by your aspects, I think that is <weaver options="-showWeaveInfo" Or it would be interesting to turn on dump diagnostics for the weaver pre- and post- weave and then see how that method had been affected during the weave and is it bad code. (It seems like the code is OK because there is no verifyerror.) To turn on that debugging, add this option to weaver options: <dump within="com.verisign.common.properties..*" beforeandafter="true"/> navigating from the PropertyManager.getInstance() method using a decompiler or javap on the woven code and seeing where it leads. My suspicion right now is that something is being woven that you weren't expecting and it is having a nasty side effect. If you want me to take a look at the bytecode, I'm happy to - use my regular gmail ID if you don't want to share it with the list. cheers, Andy. 2008/6/30 Buck, Robert <[EMAIL PROTECTED]>: > Hi Andy, > > Okay, so I reverted back to double-dots. The doc was not very clear, > which is why I tried single-dots. But still, I get the same error: > > Exception in thread "main" java.lang.NoClassDefFoundError > at $AllProbeAspect.aspectOf(Unknown Source) > at > com.verisign.common.properties.PropertyManager.getInstance(PropertyMan > ag > er.java:81) > at com.verisign.jtaps.test.Test.calc(Test.java:19) > at com.verisign.jtaps.test.Test.main(Test.java:29) > > Notice that there is no class name specified; when I trap all > exceptions in the debugger, what I see is a null error message, and > the causation member self-references the lexically enclosing exception > instance, as if somewhere someone did something evil like: > > NoClassDefFoundError error = new NoClassDefFoundError(); > error.initCause(error); throw error; > > The information I Google'd did not turn up any hints that worked. > > What sort of approach might I use to dianose and resolve this issue? > > Thanks in advance, > > Bob > > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Andy Clement > Sent: Monday, June 30, 2008 5:14 PM > To: [email protected] > Subject: Re: [aspectj-users] Exception in thread > "main"java.lang.NoClassDefFoundError > > In AspectJ syntax, the expression > > pkg.* > > means any type in package 'pkg'. If your type is in pkg.subpkg then > it will not match that expression. Two dots are needed to include > types in the package or any sub-package. > > pkg..* > > Going by the aop.xml in your previous email, you are using > org.apache.log4j.* and that doesn't match > org.apache.log4j.spi.RootLogger, so it is not excluded from the > weaving process. > > The doc is here: > http://www.eclipse.org/aspectj/doc/released/devguide/ltw-configuration > .h > tml > but i'll say that if you aren't familiar with the double dot notation, > it isn't explicitly indicated there as what you need to use, and the > example on that page is a bit unclear. we could do with improving > that doc. > > cheers, > Andy. > > 2008/6/30 Buck, Robert <[EMAIL PROTECTED]>: >> Hello, >> >> I have been grappling with an issue for a couple weeks now. No >> information in the documentation, on the web via google, seems to >> point me in the right direction. I looked through the aspectj >> database, and nothing there to help either. >> >> I put together a simple hello world application to diagnose an issue >> I > >> see when using aspectj in a larger scale application. Here is my > question... >> >> Why, when I specifically tell aspectj not to weave log4j, does it try > to? >> (assuming the stack trace below hints this, because the standalone >> application works properly). >> >> Or, is there a bug in the aspectj agent that would cause this? >> >> Or, is there a bug in aspectj with respect to static initializer > blocks? >> >> Exception in thread "main" java.lang.NoClassDefFoundError at >> org.apache.log4j.spi.RootLogger.<init>(RootLogger.java:46) >> at org.apache.log4j.LogManager.<clinit>(LogManager.java:80) >> at org.apache.log4j.Logger.getLogger(Logger.java:118) >> at >> com.verisign.common.properties.PropertyManager.<clinit>(PropertyManag >> e >> r.java:47) at com.verisign.jtaps.test.Test.calc(Test.java:19) >> at com.verisign.jtaps.test.Test.main(Test.java:29) >> Thanks >> >> Bob >> _______________________________________________ >> aspectj-users mailing list >> [email protected] >> https://dev.eclipse.org/mailman/listinfo/aspectj-users >> >> > _______________________________________________ > aspectj-users mailing list > [email protected] > https://dev.eclipse.org/mailman/listinfo/aspectj-users > _______________________________________________ > aspectj-users mailing list > [email protected] > https://dev.eclipse.org/mailman/listinfo/aspectj-users > _______________________________________________ aspectj-users mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/aspectj-users _______________________________________________ aspectj-users mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/aspectj-users
